我使用OSX:10.12.4SSL:「無法獲取本地頒發者證書」
我本來能夠使用git,自制軟件和捲曲沒有任何問題。我不記得我做了什麼,但突然間,這些SSL錯誤開始出現在我的git命令中。
我得到unable to get local issuer certificate
運行任何git命令時出錯。另外,當使用brew install git
嘗試重新安裝git時出現錯誤。
釀造輸出的相關部分:
Downloading https://www.kernel.org/pub/software/scm/git/git-2.12.2.tar.xz
curl: (60) SSL certificate problem: unable to get local issuer certificate
More details here: https://curl.haxx.se/docs/sslcerts.html
我曾嘗試:
- 重啓
- 移動〜/圖書館/鑰匙扣文件夾複製到〜/桌面,然後重新啓動
- 在Safari瀏覽器上導航到https://www.kernel.org/pub/software/scm/git,以及 viewing the certificate。根據[這些說明](不能發佈超過2個鏈接,對不起),應該有一個複選框「始終信任」該網站。我沒有看到這個複選框。
- 我打算嘗試鑰匙串急救,但是,這個功能已經在最近的Mac OS中被刪除了。
- 我試着尋找許多其他類似的問題,但是,很多人都無法理解或遵循答案中的說明。
例如,也許squid808的answer到一個類似的問題可以幫助我。他說:「相反,它是我們領域的根CA證書,我應該出口並告訴Git信任。」我幾乎不瞭解這是什麼意思,或者它與我有關,或者我會如何去做。根據我的研究,這似乎更適合運行服務器的人。它也似乎是Windows,而我在Mac上。
我明白,作爲一個臨時修復我除了可以使用git config --global http.sslVerify false
在捲曲-k
選項。這些解決方法是不安全的,所以我想讓我的SSL安全備份並儘快運行。
如果下面的嘗試我做的curl -L https://homebrew.bintray.com/bottles/libpng-1.6.29.sierra.bottle.tar.gz | bash -s stable
(釀造嘗試的一部分同樣失敗)輸出
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0curl: (60) SSL certificate problem: unable to get local issuer certificate
More details here: https://curl.haxx.se/docs/sslcerts.html
curl performs SSL certificate verification by default, using a "bundle"
of Certificate Authority (CA) public keys (CA certs). If the default
bundle file isn't adequate, you can specify an alternate file
using the --cacert option.
If this HTTPS server uses a certificate signed by a CA represented in
the bundle, the certificate verification probably failed due to a
problem with the certificate (it might be expired, or the name might
not match the domain name in the URL).
If you'd like to turn off curl's verification of the certificate, use
the -k (or --insecure) option.
道歉
- 解決這個看似零散,無序,這是因爲我很困惑,如果這是一個與git,curl更相關的問題,或者一般來說可能既不是也不僅僅是SSL證書。請讓我知道這個問題的標籤是否應該修復。
- 我可以發佈更多相關鏈接和圖片,但我受到聲望的限制。
我有另一個帳戶,我無法保持良好的聲譽。我試圖找出並解決我之前做錯的所有事情。任何關於如何改善這個問題的質量的反饋將不勝感激。謝謝。
'\ curl -L |是什麼輸出? bash -s stable' –
CodeWizard
@CodeWizard看到我更新的問題。 –