0PricingLogin
Cyber Security Academy · Lesson

Stack Buffer Overflows

Understand stack layout, overflow EIP/RIP, write a working exploit for a vulnerable C binary.

What is a Buffer Overflow?

A buffer overflow occurs when more data is written to a buffer than it can hold. The excess data overwrites adjacent memory, potentially corrupting control structures and redirecting program execution.

Stack Memory Layout

The call stack holds: local variables (buffers), saved frame pointer (SFP), and the return address (RIP/EIP) — where execution continues after the function returns. Overflowing a local buffer can overwrite the return address.

All lessons in this course

  1. Stack Buffer Overflows
  2. Return-Oriented Programming (ROP)
  3. Format String Vulnerabilities
  4. Heap Exploitation: Use-After-Free and Heap Spraying
← Back to Cyber Security Academy