Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import sys
- import binascii
- from Crypto.Cipher import AES
- filename = sys.argv[1]
- with open(filename, 'rb') as f:
- encrypted = f.read()
- #md5sum('123') == 202cb962ac59075b964b07152d234b70
- key = binascii.unhexlify('202cb962ac59075b964b07152d234b70'*2)
- iv = '\x00'*16
- cipher = AES.new(key,AES.MODE_CBC, iv)
- decrypted = cipher.decrypt(encrypted)
- decrypted_filename = '%s.decoded' % filename
- with open(decrypted_filename, 'wb') as f:
- f.write(decrypted)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement