I'm trying to figure out how to use the CryptoJS library for AES but the documentation is somewhat scarce.
I've followed their example but I can't seem to decode something that I encoded in PyCrypto
I've formatted as follows:
key = '0f3f0fe38eb5f216cb4ef0649f81d761'
ciphertext = 'Y+gwBI6R37Ko1lQmwZ57gg==FqUSqQ=='
The ciphertext has two components
iv: Y+gwBI6R37Ko1lQmwZ57gg==
encoded message: FqUSqQ==
I tried running the code below but it didn't work. It logs "" in the console. It should be resolving to 'Test'
var decrypted =CryptoJS.AES.decrypt(ciphertext, key);
console.log( decrypted.toString(CryptoJS.enc.Utf8) );
Any pointers would great. Thanks