你是不是这样写的?使用key 对text进行AES解密,每次text和key是相同的,但是结果不同,一头雾水
// 问题: 使用key 对text进行AES解密,每次text和key是相同的,但是结果不同
const res = AES.decrypt(text, key)
解决办法:把key 用CryptoJS.enc.Utf8.parse 解析一下即可
// 把key 用CryptoJS.enc.Utf8.parse 解析一下即可
const res = AES.decrypt(text, CryptoJS.enc.Utf8.parse(key))
参考地址