Files
UTEC-Lic_ME_2024_2025/RSX112/25-05-20/tp3ex2.py
T
Guillaume-Sanchez ff4bb12d22 initial commit
2026-05-26 13:56:03 +02:00

8 lines
277 B
Python

import os
from Crypto.Util.number import long_to_bytes
from Crypto.Util.strxor import strxor
FLAG = open("/home/nk/Documents/UTEC-Lic_ME_2024_2025/RSX112/RSX112-20-05-2025/flag.txt", "rb").read()
key = os.urandom(4) * 20
c = strxor(FLAG, key[:len(FLAG)])
print(c.hex())