TSW icon indicating copy to clipboard operation
TSW copied to clipboard

crypto.createCipher废弃接口替换

Open RobinzZH opened this issue 7 years ago • 0 comments

crypto.createCipher自node10.0开始已被废弃,需更改为createCipheriv

image

发现调用接口文件:/bin/tsw/util/auto-report/post.js

module.exports.encode = function(appid, appkey, data) {
    const input = Buffer.from(JSON.stringify(data), 'UTF-8');
    const buff = zlib.deflateSync(input);
    const des = crypto.createCipher('des', (appid + appkey));

ps: 对接接口crypto.createDecipher也需要替换

RobinzZH avatar Feb 21 '19 03:02 RobinzZH