description |
---|
10/07/2023 |
Here, we will be learning how to use pwntools
to aid in our exploit development for Return-Oriented-Programming (ROP) for attacking binaries.
When starting, we want to see at what exact point we are segfaulting.
- Where does the segfault occur?
- What is the value of our instruction pointer (
EIP
/RIP
)? - Did we overwrite
EIP
/RIP
?
dmesg
Viewing segfault with dmesg
./binary "$(python3 -c "import sys; sys.stdout.buffer.write(b'A'*100)")"
By changing the 100, we can change the amount of A's we are sending to the program as an argument to fuzz for the segfault or buffer overflow.
We will know that we are successful as soon as we see "Segmentation fault" being reflected to us in our output.
python3 -c "import sys; sys.stdout.buffer.write(b'A'*100)" | ./binary