previous | start | next

Attack

1. The getbuf function calls getsx to read input into the char
    array, buf of size 12.

2. But getbuf ignores what is copied into the buf array and
   simply returns the integer 1.

3. By typing in more than 12 characters the buf array will
   overflow, with the extra input being copied into memory
   after the array storage.

Goal: By cleverly choosing the input characters to
enter, get new code to execute so that getbuf returns the integer value

         0xdeadbeef

instead of 1.



previous | start | next