解决:git SSL certificate problem: unable to get local issuer certificate

错误: git SSL certificate problem: unable to get local issuer certificate

这个问题是由于没有配置信任的服务器HTTPS验证。默认,cURL被设为不信任任何CAs,就是说,它不信任任何服务器验证。

只需要执行下面命令就可以解决:

git config --global http.sslVerify false
  • 266
    点赞
  • 260
    收藏
    觉得还不错? 一键收藏
  • 44
    评论
Hi there! It seems like you're facing an SSL certificate problem while using Git and getting the error "unable to get local issuer certificate." This error usually occurs when Git is unable to verify the SSL certificate of the remote repository. To fix this issue, you can try the following steps: 1. Update Git: Make sure you're using the latest version of Git. Older versions may have issues with SSL certificates. 2. Set the SSL verify flag: Run the following command to disable SSL verification temporarily: ``` git config --global http.sslVerify false ``` Note: This is not recommended for security reasons, but it can help identify if the SSL certificate is the root cause of the problem. 3. Configure Git to use the correct certificate bundle: Run the following command: ``` git config --global http.sslCAinfo /path/to/certificate.pem ``` Replace "/path/to/certificate.pem" with the path to your SSL certificate bundle. You can also try using a different certificate bundle if the current one is causing issues. 4. Update your system's certificate store: Sometimes, the SSL certificates on your system might be outdated or missing. Update your system's certificate store and try again. If none of these steps resolve the issue, it's possible that the SSL certificate is actually missing or not properly installed on the server you're trying to connect to. In such cases, you may need to contact the server administrator or use alternative methods for cloning or accessing the repository. I hope this helps! Let me know if you have any further questions.

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 44
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值