git SSL CA cert.... test

上网、浏览、聊天、下载等
回复
头像
eexpress
帖子: 58428
注册时间: 2005-08-14 21:55
来自: 长沙

git SSL CA cert.... test

#1

帖子 eexpress » 2012-11-19 23:26

代码: 全选

● git config --global https.proxy localhost:8087
● git config --global core.gitproxy localhost:8087
● git config --global http.proxy localhost:8087

● git remote add httpsgithub https://git@github.com:eexpress/eexp-bin.git
● git remote add http-github http://git@github.com:eexpress/eexp-bin.git

代码: 全选

● sudo  git config --system http.sslcainfo /bin/curl-ca-bundle.crt
● sudo  git config --system https.sslcainfo /bin/curl-ca-bundle.crt
● cat /etc/gitconfig 
[http]
	sslcainfo = /bin/curl-ca-bundle.crt
[https]
	sslcainfo = /bin/curl-ca-bundle.crt
● git push httpsgithub 
error: Problem with the SSL CA cert (path? access rights?) while accessing https://git@github.com:eexpress/eexp-bin.git/info/refs
fatal: HTTP request failed
● git push http-github 
error: The requested URL returned error: 501 while accessing http://git@github.com:eexpress/eexp-bin.git/info/refs
fatal: HTTP request failed
● 鸣学
头像
eexpress
帖子: 58428
注册时间: 2005-08-14 21:55
来自: 长沙

Re: git SSL CA cert.... test

#3

帖子 eexpress » 2012-11-20 15:06

搞清楚了。

代码: 全选

[http]
	proxy = localhost:8087
	sslVerify = false
设置本地端口

代码: 全选

git config --global http.proxy localhost:8087
直接关闭 SSL 证书校验

代码: 全选

git config --global http.sslVerify false
这才是关键,之前写错了。幸好去github看了下。

代码: 全选

git remote add httpsgithub https://eexpress@github.com/eexpress/eexp-bin.git

代码: 全选

● git push httpsgithub 
Everything up-to-date
● 鸣学
头像
eexpress
帖子: 58428
注册时间: 2005-08-14 21:55
来自: 长沙

Re: git SSL CA cert.... test

#4

帖子 eexpress » 2012-11-21 19:46

2012-11-21 19:29:38 三 ~/bin
● git pull
ssh: connect to host github.com port 22: Connection timed out
fatal: The remote end hung up unexpectedly
2012-11-21 19:30:44 三 ~/bin
● git pull httpsgithub
error: couldn't connect to host while accessing https://eexpress@github.com/eexpress/ee ... /info/refs
fatal: HTTP request failed
2012-11-21 19:34:57 三 ~/bin
● git pull httpsgithub
From https://github.com/eexpress/eexp-bin
ffdcad8..d26f063 master -> httpsgithub/master
You asked to pull from the remote 'httpsgithub', but did not specify
a branch. Because this is not the default configured remote
for your current branch, you must specify a branch on the command line.
2012-11-21 19:35:07 三 ~/bin
● git pull httpsgithub master
From https://github.com/eexpress/eexp-bin
* branch master -> FETCH_HEAD
Already up-to-date.
● 鸣学
回复