Added chall and some stuff

This commit is contained in:
2026-02-12 22:52:30 +01:00
parent fe21c6b790
commit 19fae10e5f
5 changed files with 428 additions and 7 deletions

View File

@@ -0,0 +1,21 @@
from aes import AES
from secret import flag
import os
cipher = AES(flag, rounds = 1)
p = []
c = []
for _ in range(2):
plaintext = os.urandom(16)
p.append(plaintext.hex())
ciphertext = cipher.encrypt_block(plaintext)
c.append(ciphertext.hex())
print('plaintexts = ', p)
print('ciphertexts = ', c)
# plaintexts = ['ae976f8d95e5bd2eaf40a0efcec97e0d', 'e99c923581939d80e1cf25ee19c891e4']
# ciphertexts = ['ce3776b4dc0551217e856bdfb25251b3', '70439bebea8c21e2b8eb7bad1723656b']