2013年12月9日 星期一

[GIT] Fix git ca-bundle.crt issue: disable ssl verify

Reinstall ca-bundle.crt:

done......

最好是這樣簡單啦!!!




Issue case:
root@bejo:/tmp# git clone https://xxx.git
Initialized empty Git repository in /XXXpath/.git/
Password:
error:  while accessing https://xxx.git/info/refs

fatal: HTTP request failed
root@bejo:/tmp#

Because github runs HTTPS checkout and the web verify SSL by /etc/ca-bundle.crt

It records valid web but we don't need it. So disable them!!!

git config --global http.sslVerify false

--

BUT!!! disable SSL verify is not a good idea...

So...
#git config --global http.sslcainfo /etc/ssl/certs/ca-certificates.crt

redirect to new one

--
題外話:
這個CA裡面含有合法的憑證發行機構,所以缺了就不會認識SSL憑證。
更新方法:
#update-ca-certificates