Skip to content

Instantly share code, notes, and snippets.

@safebuffer
Created January 6, 2019 13:46
Show Gist options
  • Save safebuffer/a8b6dc813bd85dc0defc12b059228312 to your computer and use it in GitHub Desktop.
Save safebuffer/a8b6dc813bd85dc0defc12b059228312 to your computer and use it in GitHub Desktop.
disassemble shellcode with python
from capstone import *
shellcode_here = ""
def toop(code):
md = Cs(CS_ARCH_X86, CS_MODE_32)
for i in md.disasm(code, 0x1000):
print("0x%x:\t%s\t%s" %(i.address, i.mnemonic, i.op_str))
toop(shellcode_here)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment