html52.com
我爱小程序-开发者交流社区

小程序开发设置里面的“EncodingAESKey(消息加密密钥)"随机生成的密钥有问题吗?

在小程序管理后台开发设置里面的“EncodingAESKey(消息加密密钥)"随机生成的密钥,在java里面new WXBizMsgCrypt()的时候会崩溃,base64解码失败

java.lang.IllegalArgumentException: Last encoded character (before the paddings if any) is a valid base 64 alphabet but not a possible value. Expected the discarded bits to be zero.

at org.apache.commons.codec.binary.Base64.validateCharacter(Base64.java:803)

at org.apache.commons.codec.binary.Base64.decode(Base64.java:482)

at org.apache.commons.codec.binary.BaseNCodec.decode(BaseNCodec.java:481)

at org.apache.commons.codec.binary.BaseNCodec.decode(BaseNCodec.java:465)

at org.apache.commons.codec.binary.Base64.decodeBase64(Base64.java:699)

at com.qq.weixin.mp.aes.WXBizMsgCrypt.<init>(WXBizMsgCrypt.java:64)

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

真正的个人免签约支付接口

云免签H5支付