more on buffer overflows
Click here to load reader
Post on 24-Feb-2016
Embed Size (px)
DESCRIPTIONMore on Buffer Overflows. Buffer Overflow. Recap: very simply, a buffer overflow is when a program overruns the boundary of a buffer’s allocated space and overwrites adjacent memory. char A; unsigned short B; s trcpy (A, “excessive”);. A simple vulnerability. - PowerPoint PPT Presentation
Computer Security: Principles and Practice, 1/e
More on Buffer Overflows
Buffer OverflowRecap: very simply, a buffer overflow is when a program overruns the boundary of a buffers allocated space and overwrites adjacent memory.char A;unsigned short B;strcpy(A, excessive);
A simple vulnerabilitySimple code vulnerabilities use functions that dont check whether a buffers bounds are overwritten.
More complexMore complex attacks take into account what other pieces of data are nearby on the stack:
And anotherEven without code being called inside the program, can still mess with the intent of the program. Note that non-execute bits wont help stop this one!
Even worseIts not hard to get function pointers overwritten, even with no execution allowed:
Fixing these issuesFixing is largely a matter of not using unsafe functions.
Caution:Care is still needed, however check this next one, which appears secure.What is the bug here?
But could this really happen?
And now a few HW hintsSorry, had to come in person!Arent you glad you came today? =)