Closed tangna closed 3 years ago
验证出问题的地方为verifier.verify(this.config.alipayPublicKey, serverSign, 'base64'); 我使用alipayPublicKey的值和相关数据在 支付宝开放平台开放助手 验签结果是成功的,请问下怎么解决?
代码示例大概如下:
const alipaySdk = new AlipaySdk({ appId: cfg['app_id'], privateKey: fs.readFileSync(theone.path('keys/alipay/private-key.pem'), 'ascii'), alipayRootCertPath: theone.path('keys/alipay/alipayRootCert.crt'), appCertPath: theone.path('keys/alipay/appCertPublicKey.crt'), alipayPublicCertPath: theone.path('keys/alipay/alipayCertPublicKey_RSA2.crt'), }) alipaySdk.checkResponseSign(originStr, 'alipay_trade_app_pay_response')
验证出问题的地方为verifier.verify(this.config.alipayPublicKey, serverSign, 'base64'); 我使用alipayPublicKey的值和相关数据在 支付宝开放平台开放助手 验签结果是成功的,请问下怎么解决?
代码示例大概如下:
const alipaySdk = new AlipaySdk({ appId: cfg['app_id'], privateKey: fs.readFileSync(theone.path('keys/alipay/private-key.pem'), 'ascii'), alipayRootCertPath: theone.path('keys/alipay/alipayRootCert.crt'), appCertPath: theone.path('keys/alipay/appCertPublicKey.crt'), alipayPublicCertPath: theone.path('keys/alipay/alipayCertPublicKey_RSA2.crt'), }) alipaySdk.checkResponseSign(originStr, 'alipay_trade_app_pay_response')