| | |
| | | System.err.println("调起支付异常-------------->" + map1.get("err_code_des")); |
| | | return ResultUtil.error(map1.get("err_code_des")); |
| | | } |
| | | }else{//签名错误,请检查后再试1----1602881362 |
| | | }else{//签名错误,请检查后再试1----1716524249 |
| | | System.err.println("调起支付异常-------------->" + map1.get("return_msg") + appid + "----" + mchId); |
| | | return ResultUtil.error(map1.get("return_msg"), new JSONObject()); |
| | | } |
| | |
| | | Map<String, String> map1 = null; |
| | | String body1 = null; |
| | | try { |
| | | String certPath = "D:\\app\\cert\\weixin\\1602881362\\apiclient_cert.p12"; |
| | | String certPath = "D:\\app\\cert\\weixin\\1716524249\\apiclient_cert.p12"; |
| | | body1 = httpClientUtil.pushHttpsRequsetXml(url, xmlString.toString(), new HashMap<>(), mchId, certPath, "PKCS12"); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | |
| | | // 一个商户号只能初始化一个配置,否则会因为重复的下载任务报错 |
| | | Config config = new RSAAutoCertificateConfig.Builder() |
| | | .merchantId(mchId) |
| | | .privateKeyFromPath("D:\\app\\cert\\weixin\\1602881362\\apiclient_key.pem") |
| | | .merchantSerialNumber("4CEAF65279E636E313365ED0FB34A918F1BDAACD") |
| | | .apiV3Key("MIIEvQIBADANBgkqhkiG9w0BAQEFAASC") |
| | | .privateKeyFromPath("D:\\app\\cert\\weixin\\1716524249\\apiclient_key.pem") |
| | | .merchantSerialNumber("5410CEAE9C7E9CDFCB58B88E1C607D2841F62437") |
| | | .apiV3Key("FCB58B88E1C607D2841F62437QIGZOdM") |
| | | .build(); |
| | | // 构建service |
| | | JsapiService service = new JsapiService.Builder().config(config).build(); |
| | |
| | | xmlString.append("</xml>"); |
| | | |
| | | Map<String, String> map1 = null; |
| | | String certPath = "D:\\app\\cert\\weixin\\1602881362\\apiclient_cert.p12";//证书地址 |
| | | String certPath = "D:\\app\\cert\\weixin\\1716524249\\apiclient_cert.p12";//证书地址 |
| | | String body1 = httpClientUtil.pushHttpsRequsetXml(url, xmlString.toString(), new HashMap<>(), mchId, certPath, "PKCS12"); |
| | | //将结果xml解析成map |
| | | body1 = body1.replaceAll("<!\\[CDATA\\[",""); |
| | |
| | | xmlString.append("</xml>"); |
| | | |
| | | Map<String, String> map1 = null; |
| | | String certPath = "D:\\app\\cert\\weixin\\1602881362\\apiclient_cert.p12";//证书地址 |
| | | String certPath = "D:\\app\\cert\\weixin\\1716524249\\apiclient_cert.p12";//证书地址 |
| | | String body1 = httpClientUtil.pushHttpsRequsetXml(url, xmlString.toString(), new HashMap<>(), mchId, certPath, "PKCS12"); |
| | | //将结果xml解析成map |
| | | body1 = body1.replaceAll("<!\\[CDATA\\[",""); |