Skip to content

Instantly share code, notes, and snippets.

@fgsahoward
Created June 11, 2018 17:27
Show Gist options
  • Save fgsahoward/bd46a3e1e53a9cfa47abda4bc283e403 to your computer and use it in GitHub Desktop.
Save fgsahoward/bd46a3e1e53a9cfa47abda4bc283e403 to your computer and use it in GitHub Desktop.
[howard@sterling bof]$ gdb -q med32
Reading symbols from med32...(no debugging symbols found)...done.
(gdb) b *main
Breakpoint 1 at 0x8048504
(gdb) r /bin/sh -p
Starting program: /home/howard/repos/bof/med32 /bin/sh -p
Breakpoint 1, 0x08048504 in main ()
(gdb) x/xw $esp
0xffffda1c: 0xf7e12196
(gdb)
0xffffda20: 0x00000003
(gdb)
0xffffda24: 0xffffdab4
(gdb)
0xffffda28: 0xffffdac4
(gdb)
0xffffda2c: 0x00000000
(gdb) x/xw 0xffffdab4
0xffffdab4: 0xffffdc29
(gdb)
0xffffdab8: 0xffffdc46
(gdb)
0xffffdabc: 0xffffdc4e
(gdb)
0xffffdac0: 0x00000000
(gdb) x/s 0xffffdc46
0xffffdc46: "/bin/sh"
(gdb)
0xffffdc4e: "-p"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment