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
apiclient_cert.p12 可以用base64 编码存储加载吗,比较文件不好存储管理,
The text was updated successfully, but these errors were encountered:
你希望怎么存储,欢迎直接PR代码
Sorry, something went wrong.
🆕 #2586 【微信支付】支付证书支持base64编码配置
1fc0da0
使用以下代码获取p12证书的字节数组内容和Base64编码内容,供后来者参考
File file = new File("D://apiclient_cert.p12"); InputStream inputStream = new FileInputStream(file); // 获取p12证书文件内容的字节数组. byte[] keyContent = IOUtils.toByteArray(inputStream); // 获取p12证书base64编码 String keyString = Base64.getEncoder().encodeToString(keyContent); System.out.println(keyString); // 检验Base64解密后是否相同 byte[] configContent = Base64.getDecoder().decode(keyString); System.out.println(Arrays.equals(keyContent, configContent));
请参考commit记录,代码里已经支持
No branches or pull requests
apiclient_cert.p12 可以用base64 编码存储加载吗,比较文件不好存储管理,
The text was updated successfully, but these errors were encountered: