Skip to content
Free public beta until December 4, 2026: every course is open, no card needed. After that, the first chapter of each course stays free and full access is a one-time $39 ($19 for up to 100 founding members chosen for helpful feedback). Your progress is kept. How the beta works

buffer overflow

Writing past the end of an array or buffer, so the extra bytes land on whatever is stored next to it in memory. Not the same thing as integer overflow.

A buffer overflow is an out-of-bounds write beyond a buffer's end (or before its start); on the stack it overwrites neighbouring locals, saved registers, the saved frame pointer and the saved return address in the frame, and on the heap it overwrites adjacent blocks and allocator metadata.

Examples

  • char buf[8]; strcpy(buf, "overflowing"); writes 12 bytes into an 8-byte array.

Read the full section →