晚上使用更新源之后使用了git
命令,但是报错
error: server certificate verification failed
在stackoverflow
上有一页专门解答:server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none ,针对不同情况,里面有很多的解决方案。
我的属于系统时间错误,和下面这个问题相同:
Another cause of this problem might be that your clock might be off. Certificates are time sensitive.
This was my problem. My university was blocking ntp packets, which was preventing my system from updating time. Once I configured the university ntp servers things were working again. Thanks for this tip! – Kyle Mar 9 at 16:51
问题重现
****@****:~$ date -R
Sat, 18 Jan 2014 06:11:27 +0800
****@****:~$ git clone https://github.com/bugmeout/CPluslab.git
Cloning into ‘CPluslab‘...
error: server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none while accessing https://github.com/bugmeout/CPluslab.git/info/refs
fatal: HTTP request failed
由于不能够和时间服务器通信,用命令修改了时间之后,一切ok。
sudo date -s ‘22:36:00 2015-06-19‘
时间: 2024-10-19 16:05:00