We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
public static WxaUserPhoneInfo decryptUserPhoneInfo(String session_key, String encryptedData, String iv) { try { Cipher cipher = Cipher.getInstance("AES/CBC/NoPadding"); Key sKeySpec = new SecretKeySpec(Base64.decodeBase64(session_key), "AES"); cipher.init(Cipher.DECRYPT_MODE, sKeySpec, new IvParameterSpec(Base64.decodeBase64(iv))); byte[] resultByte = cipher.doFinal(Base64.decodeBase64(encryptedData)); String data = new String(PKCS7Encoder.decode(resultByte), StandardCharsets.UTF_8); return JsonUtil.parseObject(data, WxaUserPhoneInfo.class); } catch (Exception e) { logger.error("", e); } return null; }
`package weixin.popular.bean.wxa;
public class WxaUserPhoneInfo {
private String phoneNumber;//用户绑定的手机号(国外手机号会有区号) private String purePhoneNumber;//没有区号的手机号 private String countryCode;//区号 private Watermark watermark; public String getPhoneNumber() { return phoneNumber; } public void setPhoneNumber(String phoneNumber) { this.phoneNumber = phoneNumber; } public String getPurePhoneNumber() { return purePhoneNumber; } public void setPurePhoneNumber(String purePhoneNumber) { this.purePhoneNumber = purePhoneNumber; } public String getCountryCode() { return countryCode; } public void setCountryCode(String countryCode) { this.countryCode = countryCode; } public Watermark getWatermark() { return watermark; } public void setWatermark(Watermark watermark) { this.watermark = watermark; }
} `
The text was updated successfully, but these errors were encountered:
Sorry, something went wrong.
No branches or pull requests
public static WxaUserPhoneInfo decryptUserPhoneInfo(String session_key, String encryptedData, String iv) { try { Cipher cipher = Cipher.getInstance("AES/CBC/NoPadding"); Key sKeySpec = new SecretKeySpec(Base64.decodeBase64(session_key), "AES"); cipher.init(Cipher.DECRYPT_MODE, sKeySpec, new IvParameterSpec(Base64.decodeBase64(iv))); byte[] resultByte = cipher.doFinal(Base64.decodeBase64(encryptedData)); String data = new String(PKCS7Encoder.decode(resultByte), StandardCharsets.UTF_8); return JsonUtil.parseObject(data, WxaUserPhoneInfo.class); } catch (Exception e) { logger.error("", e); } return null; }
`package weixin.popular.bean.wxa;
public class WxaUserPhoneInfo {
}
`
The text was updated successfully, but these errors were encountered: