hulksmash
2024-08-08 20:37:52
# TJ-CTF-2024
my friends password is keysmash…. :(… i got some of his old keysmashes tho…. he types kinda funny….
output.txt
keysmashes.txt
main.py
Here’s all the files:
keysmashes.txt
1 | fjdlska;sjfldka; |
output.txt
1 | ed05f1440f3ae5309a3125a91dfb0edef306e1a64d1c5f7d8cea88cdb7a0d7d66bb36860082a291138b48c5a6344c1ab |
main.py
1 | from Crypto.Cipher import AES |
Basically, this challenge revolves entirely around using the keysmashes.txt file to figure out the key. I’m honestly a bit surprised this wasn’t solved that much, but I guess a lot of people just missed the patterns. There are two patterns you need to see:
The letters of each line in keysmashes.txt alternate from one letter in “asdf” and one in “jkl;”.
2 of each byte of “asdfjkl;” is included in each line.
And… that’s it. Easy implementation from here on out:
1 | # f = open('keysmashes.txt', 'r').read().split('\n') |
tjctf{low_entropy_keysmashuiyf8sa8uDYF987&^*&^}