I want to generate a 256bit password for my AES encryption. When I check the password after the encryption it is different from my initial password. What am I doing wrong? Or i
I found the solution. You can define your own key using var encrypted = CryptoJS.AES.encrypt("Message", key, { iv: iv });
So my source code is:
key=CryptoJS.enc.Hex.parse(Generate_key()); iv=CryptoJS.enc.Hex.parse(Generate_key()); var encrypted = CryptoJS.AES.encrypt("Message", key, { iv: iv });