Skip to content

Instantly share code, notes, and snippets.

@c0nrad
Created January 31, 2025 23:14
Show Gist options
  • Select an option

  • Save c0nrad/0aa75e758cb3c42c54f80997c2b37f0a to your computer and use it in GitHub Desktop.

Select an option

Save c0nrad/0aa75e758cb3c42c54f80997c2b37f0a to your computer and use it in GitHub Desktop.
import pwn
elf = pwn.ELF('./masking-tape')
b1 = elf.read(elf.symbols["enc1"], 0x1c)
b2 = elf.read(elf.symbols["enc2"], 0x1c)
ct = pwn.xor(b1, b2)
ct = [chr(((x >> 3) | (x << 5)) & 0xff) for x in ct]
print("".join(ct))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment