openssl - win7下安装sass失败,提示ruby证书不对?
PHP中文网
PHP中文网 2017-04-24 09:12:42
0
4
771

步骤:
1.

gem sources --remove https://rubygems.org/

2.

gem sources -a https://ruby.taobao.org/
Error fetching https://ruby.taobao.org/:
        SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: ce
rtificate verify failed (https://rubygems-china.oss-cn-hangzhou.aliyuncs.com/spe
cs.4.8.gz)

3.

gem sources -l
*** CURRENT SOURCES ***

问题出处:
http://stackoverflow.com/questions/4528101/ssl-connect-returned-1-errno-0-state-sslv3-read-server-certificate-b-certificat

https://gist.github.com/fnichol/867550

I had this same issue while working on a Ruby project. I am using Windows 7 64bit.

I resolved this by:

Downloading the cacert.pem file from http://curl.haxx.se/ca/cacert.pem.
Saved that file to C:/RubyCertificates/cacert.pem
Then set my environmental variable "SSL_CERT_FILE" to "C:/RubyCertificates/cacert.pem"
source: https://gist.github.com/fnichol/867550

证书地址:http://curl.haxx.se/ca/cacert.pem

按照上面这位网友的方法配置了环境变量如下图

再次执行gem sources -a https://ruby.taobao.org/
报错依旧

有谁遇到过,还是我的环境变量没有配置对呢?

PHP中文网
PHP中文网

认证高级PHP讲师

reply all(4)
左手右手慢动作

Now Taobao gem has stopped updating and maintaining, it is currently being maintained by ruby-china.
gem source --remove https://ruby.taobao.org/ --add http://gems-china.org/

洪涛

gem source --add http://rubygems.org/
gem source -l

伊谢尔伦

I encountered the same problem and passed the steps successfully after following the steps at https://gist.github.com/fnichol/867550 (you need to log out of the machine).
But I added it to the system variable, I don’t know if this is the reason.

Ty80

To add it to the system variables, just restart the computer and execute the command to switch Taobao sources

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!