Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

小程序解密用户手机号码异常 #758

Closed
Flying17 opened this issue Sep 13, 2018 · 3 comments
Closed

小程序解密用户手机号码异常 #758

Flying17 opened this issue Sep 13, 2018 · 3 comments

Comments

@Flying17
Copy link

WxMaCryptUtils.decrypt(sessionKey, encryptedData, ivStr);
这个解密出来的是乱码,导致gson解析异常,报错如下:
java.lang.IllegalStateException: Expected BEGIN_OBJECT but was STRING at line 1 column 1 path $

@binarywang
Copy link
Owner

这是个常见问题,请参考:#359

@Flying17
Copy link
Author

thx,原来我解密之前再次login了,导致sessionkey失效了,但是这个sessionkey不是每次刷新都会变,导致我有时可以有时不可以,导致我排除了sessionkey的锅

@syzpig
Copy link

syzpig commented Apr 22, 2019

thx,原来我解密之前再次login了,导致sessionkey失效了,但是这个sessionkey不是每次刷新都会变,导致我有时可以有时不可以,导致我排除了sessionkey的锅

您好,你解密之前再次调用了login.?请问您不是先调用login,获取sessionKey,然后去解密的吗?我这也是偶尔解不出来

Repository owner locked as resolved and limited conversation to collaborators Nov 26, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants