From 9eba04dce9573ac810b9b87cda9d46d9ba1a6140 Mon Sep 17 00:00:00 2001 From: Liu <101158568+feathers-l@users.noreply.github.com> Date: Thu, 17 Oct 2024 00:16:36 +0800 Subject: [PATCH] =?UTF-8?q?:art:=20=E3=80=90=E5=BE=AE=E4=BF=A1=E6=94=AF?= =?UTF-8?q?=E4=BB=98=E3=80=91=E5=88=9D=E5=A7=8B=E5=8C=96v3=E5=AE=A2?= =?UTF-8?q?=E6=88=B7=E7=AB=AF=E6=97=B6=EF=BC=8C=E6=9C=AA=E4=BD=BF=E7=94=A8?= =?UTF-8?q?p12=E8=AF=81=E4=B9=A6=E4=B8=94=E6=9C=AA=E8=AE=BE=E7=BD=AE?= =?UTF-8?q?=E8=AF=81=E4=B9=A6=E5=BA=8F=E5=88=97=E5=8F=B7=E5=80=BC=E6=89=8D?= =?UTF-8?q?=E5=B0=9D=E8=AF=95=E5=8A=A0=E8=BD=BD=E8=AF=81=E4=B9=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/github/binarywang/wxpay/config/WxPayConfig.java | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/weixin-java-pay/src/main/java/com/github/binarywang/wxpay/config/WxPayConfig.java b/weixin-java-pay/src/main/java/com/github/binarywang/wxpay/config/WxPayConfig.java index d53bdf05e..83a4b042c 100644 --- a/weixin-java-pay/src/main/java/com/github/binarywang/wxpay/config/WxPayConfig.java +++ b/weixin-java-pay/src/main/java/com/github/binarywang/wxpay/config/WxPayConfig.java @@ -281,15 +281,13 @@ public class WxPayConfig { merchantPrivateKey = PemUtils.loadPrivateKey(keyInputStream); } - if (certificate == null) { + if (certificate == null && StringUtils.isBlank(this.getCertSerialNo())) { InputStream certInputStream = this.loadConfigInputStream(this.getPrivateCertString(), this.getPrivateCertPath(), this.privateCertContent, "privateCertPath"); certificate = PemUtils.loadCertificate(certInputStream); - } - - if (StringUtils.isBlank(this.getCertSerialNo())) { this.certSerialNo = certificate.getSerialNumber().toString(16).toUpperCase(); } + //构造Http Proxy正向代理 WxPayHttpProxy wxPayHttpProxy = getWxPayHttpProxy();