MalwareTech Malware Reversing Challenges — Ransomware

jelly_unencrypted =  bytearray(open("Jellyfish.jpg", "rb").read(0x20))jelly_encrypted = bytearray(open("Jellyfish.jpg_encrypted", "rb").read(0x20))

key = []
for i in range(0x20):
key.append(jelly_encrypted[i] ^ jelly_unencrypted[i])

file = open("flag.txt_encrypted", "rb")
buffer = bytearray(file.read())

flag = ""
for i in range(len(buffer)):
flag += chr(buffer[i] ^ key[i % 0x20])

print(flag)

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store