Stack Buffer Overflow
How it works ?
char buffer[16];
printf("Enter a string: ");
scanf("%s", buffer); address | values
------------+-------------------------------------------------------------------
| +------------------------- buffer ---------------------------+
0xffffd280: | | 0x01 0x00 0x00 0x00 0x54 0xd3 0xff 0xff |
0xffffd288: | | 0x5c 0xd3 0xff 0xff 0xad 0x62 0x55 0x56 |
| +------------------------------------------------------------+
0xffffd290: | 0xb0 0xd2 0xff 0xff 0x00 0x00 0x00 0x00
0xffffd298: | 0x00 0x00 0x00 0x00 0x46 0xce 0xdd 0xf7
... | ...How to prevent ?
Last updated