Exploit a Buffer Overflow
Advanced · ~3 min · guided
0%
1
See the vulnerable code

This C function has a critical bug. Can you spot it?

void login(char *input) {
  char buf[64];
  strcpy(buf, input); // ← no bounds check!
}

strcpy copies data without checking length — what happens if input > 64 bytes?

2
Overflow the buffer
3
Redirect execution

// Simulated environment. Real attacks work exactly like this.

exploit-a-buffer-overflow.sh
▶ Step 1:See the vulnerable code
○ Step 2:Overflow the buffer
○ Step 3:Redirect execution