帮助文档,新增证书设置方式教程

This commit is contained in:
egzosn
2019-01-15 09:54:28 +08:00
parent c48722febb
commit ffdc8f5b07
3 changed files with 7 additions and 0 deletions

View File

@@ -75,6 +75,8 @@ public class WxPayController {
//ssl 退款证书相关 不使用可注释
if(!"ssl 退款证书".equals(KEYSTORE)){
//TODO 这里也支持输入流的入参。
// httpConfigStorage.setKeystore(WxPayController.class.getResourceAsStream("/证书文件"));
httpConfigStorage.setKeystore(KEYSTORE);
httpConfigStorage.setStorePassword(STORE_PASSWORD);
httpConfigStorage.setPath(true);

View File

@@ -96,8 +96,11 @@ public enum PayType implements BasePayType {
wxPayConfigStorage.setMsgType(apyAccount.getMsgType());
wxPayConfigStorage.setInputCharset(apyAccount.getInputCharset());
wxPayConfigStorage.setTest(apyAccount.isTest());
//https证书设置 方式一
/* HttpConfigStorage httpConfigStorage = new HttpConfigStorage();
//TODO 这里也支持输入流的入参。
// httpConfigStorage.setKeystore(PayType.class.getResourceAsStream("/证书文件"));
httpConfigStorage.setKeystore("证书信息串");
httpConfigStorage.setStorePassword("证书密码");
//是否为证书地址

View File

@@ -37,6 +37,8 @@
//退款使用
/* 网络请求ssl证书 根据需求进行设置**/
//设置ssl证书路径
//TODO 这里也支持输入流的入参。
// httpConfigStorage.setKeystore(this.getClass()..getResourceAsStream("/证书文件"));
httpConfigStorage.setKeystorePath("证书绝对路径");
//设置ssl证书对应的密码
httpConfigStorage.setStorePassword("证书对应的密码");