我可以使用ssh推送克隆项目,但是当我用https克隆项目时它不起作用.它显示消息错误如下.
server certificate verification failed. CAfile: /etc/ssl/certs/cacertificates.crt CRLfile: none
Run Code Online (Sandbox Code Playgroud) 我有一个使用自签名证书通过https工作的企业git服务器.本地克隆包含两个遥控器 - 指向该服务器的原点,另一个指向github.默认情况下从原点拉出失败:
$ git pull
fatal: unable to access 'https://user@code.example.com/git/fizzbuzz.git/': SSL certificate problem: self signed certificate
Run Code Online (Sandbox Code Playgroud)
github遥控器工作正常.
有两种经常建议的解决方案:
git config http.sslVerify false
Run Code Online (Sandbox Code Playgroud)
这是一个坏主意,并且在配置Git中建议接受特定https远程的特定自签名服务器证书:
git config http.sslCAInfo <downloaded certificate>.pem
Run Code Online (Sandbox Code Playgroud)
修复了从原点拉动,但打破了github远程:
$ git pull github
fatal: unable to access 'https://github.com/user/fizzbuzz.git/': SSL certificate problem: unable to get local issuer certificate
Run Code Online (Sandbox Code Playgroud)
如何在不破坏github的情况下从公司服务器上工作?
在GitHub 上 共享了一个解决方法sudo hwclock -s来重新同步 WSL 中的时钟,但是每次从睡眠/休眠状态恢复时都必须执行此操作。
clock windows-task-scheduler windows-subsystem-for-linux wsl-2
git clone由于这个错误,我一直无法得到任何github仓库
致命:无法访问'github_url':服务器证书验证失败.CAfile:/home/ubuntu/.ssh/rel3_dodroot_2048.crt CRLFile:none
我注意到其他一些人有类似的错误,但.ssl文件夹中的证书.我从来没有见过任何人在.ssh中的证书有这个问题,我不知道如何解决它.
环境:
我想在我的 Linux 计算机上安装 nvm。(我的Debian版本是10,Git版本是2.27。OPENSSL版本是1.1.1d 2019年9月10日)
我阅读了此文档https://github.com/nvm-sh/nvm#install--update-script 并输入了此脚本。
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.3/install.sh | bash
Run Code Online (Sandbox Code Playgroud)
这就是结果。
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
curl: (60) SSL certificate problem: self signed certificate in certificate chain
More details here: https://curl.haxx.se/docs/sslcerts.html
curl failed to verify the legitimacy of the server and therefore could not
establish a secure connection to it. To learn …Run Code Online (Sandbox Code Playgroud)