gpt4 book ai didi

rest - 证书颁发机构无效或不正确

转载 作者:行者123 更新时间:2023-12-03 17:20:39 25 4
gpt4 key购买 nike

以前从 asp 调用了许多 Restful 服务 - 但这个让我难住了。
首先我的 func 看起来像

Set objHTTP = Server.CreateObject("MSXML2.ServerXMLHTTP") 
with objHTTP
.open "post", x_posturl, False
.setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
.send x_xmlstr
end with

返回的错误是

msxml3.dll error '80072f0d' The certificate authority is invalid or incorrect



所以,用谷歌搜索了一下,建议是添加行
.setOption 2, 13056

这给出了错误

msxml3.dll error '80072f0c' A certificate is required to complete client authentication



然后我联系了服务供应商,他们建议

Click on the certificate error next to the address bar, view the certificate, select Details, select Copy to File, and download it to a file. Install that into your trusted certificates on your server to stop the error appearing when trying to submit data.



因此,尝试使用说明 here - 但仍然没有快乐,任何帮助表示赞赏

最佳答案

服务器似乎位于 x_posturl有一个配置错误的证书,或者您的客户端计算机不包含/不识别证书的根授权(很可能)。有几个选项可以修复:

  • 如果证书配置错误,请让他们修复他们的证书。
  • 如果他们的证书有效,但您的机器无法识别根授权,那么您需要在本地安装根授权证书。
  • 指导MSXML2.ServerXMLHTTP忽略证书错误,这似乎在这里回答:VBA ServerXMLHTTP https request with self signed certificate
  • 更改 x_posturlhttp:// 开始而不是 https:// — 如果提供者支持。不过,在生产场景中不建议这样做。

  • 能分享一下具体是什么 x_posturl是?我们应该能够通过查看 SSL 握手进行调试。

    关于rest - 证书颁发机构无效或不正确,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19539165/

    25 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com