简体   繁体   English

SourceTree 和 Stash:无法获取本地颁发者证书

[英]SourceTree and Stash: Unable to get local issuer certificate

We have Atlassian Stash installed on a Windows 2008R2 server, and for the most part everything is working nicely.我们在 Windows 2008R2 服务器上安装了 Atlassian Stash,大部分情况下一切运行良好。 We have an SSL certificate issued by our local on-premise CA and a DNS entry set up so we can go to https://stash/ and it works quite nicely, except in Firefox where it throws a warning (related?).我们有一个由本地本地 CA 颁发的 SSL 证书和一个 DNS 条目设置,因此我们可以访问https://stash/ ,它工作得非常好,除了在 Firefox 中它会引发警告(相关?)。

When using Atlassian's Sourcetree we can navigate and choose a repository, but when we try to clone it we get the following error:当使用 Atlassian 的 Sourcetree 时,我们可以导航并选择一个存储库,但是当我们尝试克隆它时,我们会收到以下错误:

fatal: unable to access https://user@url/scm/etc/etc.git : SSL certificate problem: unable to get local issuer certificate致命:无法访问https://user@url/scm/etc/etc.git :SSL证书问题:无法获取本地颁发者证书

I get the same error if I try if from the git bash as well.如果我也从 git bash 中尝试,我会得到同样的错误。 Based on this error, I've tried following the instructions on adding the SSL certificate to the Git as also found on their website , including what is in the comments, to no avail.基于此错误,我尝试按照在其网站上也找到的将 SSL 证书添加到 Git 的说明(包括评论中的内容)进行操作,但无济于事。 I have exported the cert through Firefox and through the MMC certificate snap-in, gotten the same results and put it in its own file, combined with the curl file, and no matter what keep getting this error.我已经通过 Firefox 和 MMC 证书管理单元导出了证书,得到了相同的结果并将其放入自己的文件中,与 curl 文件结合使用,无论如何都会出现此错误。 I have yet to try getting it to work with SSH keys yet since I was hoping to make this easier for my team.我还没有尝试让它与 SSH 密钥一起工作,因为我希望让我的团队更容易做到这一点。

I also tried using ssh myserver and accepting the connection, and I entered my password and restarted;我还尝试使用ssh myserver并接受连接,然后输入密码并重新启动; still the same error.仍然是同样的错误。

I do not want to simply ignore certificate validation either, since that seems a bit pointless, then.我也不想简单地忽略证书验证,因为那似乎有点毫无意义。

How can I get this working with our CA-issued cert?我怎样才能使用我们的 CA 颁发的证书?

I just disabled SSL certificate checks (which is fine for internal repos):我刚刚禁用了 SSL 证书检查(这对于内部回购很好):

Tools >
  Options >
    Git >
      Disable SSL certificate validation (ticked)

After working with a peer who had been out until today, the revelation is that I had been using ONLY the certificate for the server itself.在与直到今天一直在工作的同行合作后,我发现我一直只使用服务器本身的证书。 My [faulty] understanding of all the articles was that, similar to handling self-signed certs, you just tell Git to trust this cert.我对所有文章的 [错误] 理解是,类似于处理自签名证书,您只需告诉 Git 信任此证书。 This is not the case for us.这对我们来说不是这样。

Instead, it is the Root CA Cert from our domain that I should have been exporting and telling Git to trust.相反,我应该导出并告诉 Git 信任的是来自我们域的根 CA 证书。 I swear I tried that early last week when this all first started, but to my shame I must not have.我发誓我上周早些时候在这一切刚开始的时候就试过了,但让我感到羞耻的是我一定没有。

Let this be a warning for anyone else who find themselves in my position!让这成为任何发现自己处于我位置的人的警告!

Sourcetree > Preferences > Git Put the tick on "Disable SSL certificate validation": Sourcetree > Preferences > Git 勾选“禁用 SSL 证书验证”:

如何使用 Sourcetree 禁用 SSL

您需要为您的服务使用完整的链证书,这不仅意味着您的证书,还意味着证书文件中的中间证书和根证书

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 SSL:'无法获得本地颁发者证书' - SSL: 'unable to get local issuer certificate' GITLAB SSL 证书问题:无法获取本地颁发者证书 - GITLAB SSL certificate problem: unable to get local issuer certificate 更改证书外部CA后,“无法获得本地发行者证书” - “Unable to get local issuer certificate” after changing the certificate External CA Heroku:UNABLE_TO_GET_ISSUER_CERT_LOCALLY:无法获得本地颁发者证书 - Heroku: UNABLE_TO_GET_ISSUER_CERT_LOCALLY: unable to get local issuer certificate 无法使用自签名证书在 Windows 上使用 git 解决“无法获取本地颁发者证书” - Unable to resolve "unable to get local issuer certificate" using git on Windows with self-signed certificate 为什么 GIT 命令行突然停止工作并出现“SSL 证书问题:无法获得本地颁发者证书” - Why GIT command line stopped working suddenly with "SSL Certificate problem: unable to get local issuer certificate" SSL 证书问题:推送到远程存储库时无法获取本地颁发者证书 - SSL certificate problem: unable to get local issuer certificate when push to remote repository 将项目从 github 克隆到 RStudio 时出现错误消息“无法获取本地颁发者证书” - error message "unable to get local issuer certificate" when cloning a project from github to RStudio Visual Studio 2017 Enterprise + TFS 2018 + Git Clone = 无法获得本地颁发者证书 - Visual Studio 2017 Enterprise + TFS 2018 + Git Clone = Unable to get local issuer certificate Jenkins 管道脚本由于错误“SSL 证书问题:无法获取本地颁发者证书”而阻止 git pull (Bitbucket) - Jenkins pipeline script blocking git pull due to error "SSL certificate problem: unable to get local issuer certificate" (Bitbucket)
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM