Board logo

标题: 解决错误 curl: (77) error setting certificate verify locations [打印本页]

作者: linda    时间: 2023-5-10 10:37     标题: 解决错误 curl: (77) error setting certificate verify locations

echo insecure >> ~/.curlrc

curl --insecure https://curl.se/ca/cacert.pem -o /etc/ssl/certs/ca-certificates.crt




ln -s /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem /etc/ssl/certs/ca-certificates.crt

yum使用curl库函数,如果curl不能正确get https url,就会出错:
Errors during downloading metadata for repository 'epel'


参考:
https://stackoverflow.com/questions/3160909/how-do-i-deal-with-certificates-using-curl-while-trying-to-access-an-https-url
https://forums.centos.org/viewtopic.php?t=72484

[ 本帖最后由 linda 于 2023-5-10 18:31 编辑 ]




欢迎光临 中神通公司技术论坛 (http://trustcomputing.com.cn/bbs/) Powered by Discuz! 6.0.0