Open abhinandanpatilInd opened 6 years ago
Try encoding the decrypted result in UTF8: decrypted.toString(CryptoJS.enc.Utf8)
. It should give you the original string.
As for issue 1: You get different encrypted value each time because each time a new random initialization vector is generated.
I'm doing the Triple DES encryption with below details:
Code I used: var encrypted = CryptoJS.TripleDES.encrypt('141234FFFFFFFF', '579D2D852F2F3BABABBD71B7BD3B7D11'); console.log("DES3 encrypted text:"+encrypted); var decrypted = CryptoJS.TripleDES.decrypt(encrypted, '579D2D852F2F3BABABBD71B7BD3B7D11'); console.log("DES3 decrypted text:"+decrypted);
Issues I'm facing:
Any inputs on above are highly appreciated!!