修复:微信小程序端报错“sm4Key must not be null”

This commit is contained in:
pppscn 2022-10-27 20:38:28 +08:00
parent f99dc6bbba
commit 91d8910d21
1 changed files with 1 additions and 1 deletions

View File

@ -75,7 +75,7 @@ class AppMessageConverter : MessageConverter {
throw HttpException(500, "服务端未配置SM4密钥")
}
val sm4Key = ConvertTools.hexStringToByteArray(HttpServerUtils.clientSignKey.toString())
val sm4Key = ConvertTools.hexStringToByteArray(HttpServerUtils.serverSm4Key.toString())
val encryptCBC = ConvertTools.hexStringToByteArray(json)
val decryptCBC = SM4Crypt.decrypt(encryptCBC, sm4Key)
//json = String(Base64.decode(decryptCBC.toString()))