Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

微信支付:新申请的微信支付商户号出现「证书不存在」的报错,因为新申请的商户号需要使用公钥模式,能兼容下公钥模式吗 #428

Closed
Axinyu opened this issue Nov 6, 2024 · 7 comments

Comments

@Axinyu
Copy link

Axinyu commented Nov 6, 2024

1. 问题说明

新申请的微信支付商户号出现「证书不存在」的报错,因为新申请的商户号需要使用公钥模式,自动验签等不再支持平台证书;

2. 诉求:微信支付能兼容下公钥模式吗

3. 关于新商户调用接口验签方式变更通知

https://developers.weixin.qq.com/community/pay/doc/0002c6a7cf438818df52145b863c01

4. 相关代码截图

image
image

5. 报错信息

client.AutoVerifySign()方法自动验签会提示:

{
"code":"RESOURCE_NOT_EXISTS",
"message":"无可用的平台证书,请在商户平台-API安全申请使用微信支付公钥。可查看指引https://pay.weixin.qq.com/docs/merchant/products/platform-certificate/wxp-pub-key-guide.html"
}
@cattle2002
Copy link

我也是遇到了这个问题 官方的库真是一言难尽

@iGoogle-ink
Copy link
Member

@Axinyu @cattle2002 好的,但是我最近忙,需要时间研究,或者你们严研究好了提交个PR。

@iGoogle-ink
Copy link
Member

@Axinyu 能帮忙看看这个 PR 是否可以解决问题吗?#430

@Axinyu
Copy link
Author

Axinyu commented Nov 9, 2024

@Axinyu 能帮忙看看这个 PR 是否可以解决问题吗?#430

没问题,自签成功
image

@Axinyu
Copy link
Author

Axinyu commented Nov 9, 2024

@Axinyu 能帮忙看看这个 PR 是否可以解决问题吗?#430

然后需要加个error返回

@iGoogle-ink
Copy link
Member

iGoogle-ink commented Nov 12, 2024

@Axinyu 能帮忙看看这个 PR 是否可以解决问题吗?#430

然后需要加个error返回

好的,我补充一下,PR已经合并,你可以使用最新的 commit id 拉取测试一下,谢谢

@Axinyu
Copy link
Author

Axinyu commented Nov 14, 2024

自签成功,没有问题
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants