git clone报错: SSL certificate problem: unable to get local issuer certificate

今天下载OneOfEleven的K5固件代码,按照自己的要求编译一下功能,使用git clone拉代码时出错,查找了一些资料原来是SSL。

        报错:

$ git clone https://github.com/OneOfEleven/uv-k5-firmware-custom.git
Cloning into 'uv-k5-firmware-custom'...
fatal: unable to access 'https://github.com/OneOfEleven/uv-k5-firmware-custom.git/': SSL certificate problem: unable to get local issuer certificate

原因分析:这里其实是电脑没有安装对应的ca证书,所以无法通过https连接到git服务器。

查看git的ssl验证是否开启

git config --get http.sslVerify

从查询结果来看git默认是开启ssl验证,但是电脑没有安装对应的ca证书,所以无法通过https连接到git服务器。

解决办法:

        这里通过设置git的ssl验证跳过了这个错误(win下):

git config --global http.sslVerify false

评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值