【发布时间】:2017-05-29 01:11:59
【问题描述】:
我们在本地设置了新的 TFS 2017 服务器。我的系统管理员设置了 https 并生成了一个自签名证书。使用 Visual Studio 的内置 git 工具一切正常。当我尝试从 CLI 执行任何操作时,我收到以下错误:SSL certificate problem: unable to get local issuer certificate
我尝试过的:
在我的客户端计算机上的受信任的根证书颁发机构存储中安装了证书(它也安装在服务器上)。要安装它,我只需双击提供给我的 .pfx 文件,输入密码,然后选择 Trusted Root 存储。
经过一些故障排除后,我将本地证书导出为 Base-64 编码的 x.509 (.CER) 文件,并将其附加到
ca-bundle.crt仔细检查了我的 git 配置以确保 http.sslcainfo 指向正确的 ca-bundle.crt 文件。
使用 openssl 连接到我的服务器。这给了我两个错误消息:
verify error:num=20:unable to get local issuer certificate verify return:1 depth=0 OU = Created by Team Foundation Server, CN = my.company.com verify error:num=21:unable to verify the first certificate verify return:1 Certificate chain 0 s:/OU=Created by Team Foundation Server/CN=my.company.com i:/OU=Created by Team Foundation Server/CN=my.company.com尝试使用其他机器的 CLI 通过 https 进行连接,结果相同。
更新
【问题讨论】:
-
终于能够说服我的系统管理员尝试链接问题中的建议(使用 makecert 创建证书)并解决了我的问题