v3 转账到零钱 支付 nginx 过不去
//官方提供的初始化客户端方法 无法通过 nginx //privateKeyPath 私钥路径
String privateKey = new String(Files.readAllBytes(Paths.get(privateKeyPath)), "utf-8");
PrivateKey merchantPrivateKey = PemUtil.loadPrivateKey(privateKey);
//mchId 商户号
//wechatPayserialNo 证书序列号
//apiV3Key 支付密码
CertificatesManager instance = CertificatesManager.getInstance();
instance.putMerchant(mchId, new WechatPay2Credentials(mchId,
new PrivateKeySigner(wechatPayserialNo, merchantPrivateKey)),
apiV3Key.getBytes(StandardCharsets.UTF_8));
Verifier verifier = instance.getVerifier(mchId);
httpclient = WechatPayHttpClientBuilder.create()
.withMerchant(mchId, wechatPayserialNo, merchantPrivateKey)
.withValidator(new WechatPay2Validator(verifier))
.build();
此方法返回
400 Bad Request
400 Bad Request
nginx
阿帕奇默认创建客户端 可以通过请求 CloseableHttpClient httpClient = HttpClients.createDefault();
请问各路大神,导致这种情况的原因可能是什么?