Ask for the encryption and decryption code of nodejs Wechat

ask nodejs Wechat to encrypt the code. Wechat only provides CPP, php, Java, Python and C-sharp versions.


      // 1.Get signaturetimestampnonceechostr
      // 2.tokentimestampnonce
      let array = [config.wechat.token, ctx.query.timestamp, ctx.query.nonce]
      array.sort()
      // 3.sha1
      let resultCode = _util.hashCry(array.join(''))
exports.hashCry = str => {
  const hashCode = crypto.createHash('sha1') // 
  return hashCode.update(str, 'utf8').digest('hex')
}
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e48ab9-44511.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e48ab9-44511.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?