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PWWqsTf5xgIu5Ge0=";
上面两个字符串中result是可以解密的服务器返回的数据 ,key为aes_key,用aes EBC解密,得到的数据用gzip 解压,java 中能够解密成功。
解密出来正确格式是一个json 字符串。
但在js 中 使用 CryptoJs AES 解密出来的格式 ,转成Utf-8会报错,并且无法使用pako.gzip 解压如果拿到java中aes解密的byte数组能够正常用 ,js 经过Uint8Array 后能正常gzip解压,求大神指导!!
拥有18年软件开发和IT教学经验。曾任多家上市公司技术总监、架构师、项目经理、高级软件工程师等职务。 网络人气名人讲师,...