memory

    SystemSoftware - Buffer OverFlow #2

    SystemSoftware - Buffer OverFlow #2

    SystemSoftware - Buffer OverFlow #1 Buffer OverFlow 배열에 할당된 메모리 사이즈를 초과해서 사용하는경우 발생 보안 측면에서 가장 빈번하게 일어나는 이슈 중 하나 대표적인 상황 : input string의 길이를 체크하지 않을 때 가지고 있 hyeo-noo.tistory.com buffer overflow는 무슨 문제를 일으키는지 어셈블리어를 통해 좀 더 자세하게 알아보자 // echo 00000000004006cf : 4006cf: sub $0x18, %rsp 4006d3: mov %rsp, %rdi 4006d6: callq 400680 4006db: mov %rsp, %rdi 4006de: callq 400520 4006e3: add $0x18, %rsp 400..

    SystemSoftware - Buffer OverFlow #1

    SystemSoftware - Buffer OverFlow #1

    Buffer OverFlow 배열에 할당된 메모리 사이즈를 초과해서 사용하는경우 발생 보안 측면에서 가장 빈번하게 일어나는 이슈 중 하나 대표적인 상황 : input string의 길이를 체크하지 않을 때 가지고 있는 buffer보다 많은 양의 string이 들어오면 buffer overflow발생 아래 코드를 통해서 buffer overflow가 발생하면 어떤일이 생기는지 알아보자 typedef struct{ int a[2]; double d; } struct_t; double fun(int i){ volatile struct_t s; s.d = 3.14; s.a[i] = 1073741824; return s.d; } void print_fun(int to){ for(int i = 0; i