Gem::RemoteFetcher::FetcherError::SSL_connect returned=1 erno=0 state=SSLw3

Gem::RemoteFetcher::FetcherError::SSL_connect returned=1 erno=0 state=SSLw3

我遇到这个错误已经有一段时间了。我正在使用 Ruby 2.1.5 和 Rails 4.1.8。每当我 运行 命令时,问题标题中都会出现错误:

1 rails new app
2 gem install..

我 运行 1(rails 新应用)错误是:

Gem::RemoteFetcher::FetcherError::SSL_connect returned=1 erno=0 state=SSLw3.....certificate failed https://rubygems.org/gem/rake-10.4.2.gem.
An error occurred while installing rake <10.4.2> and bunler cannot continue. Make sure that gem install rake -v '10.4.2' succeeds before bundling.

我尝试 运行ning 2(gem 安装 rake)但我遇到了类似的错误:

Unable to download data from https://rubygems.org/- SSL_connect returned=1 erno=0 state=SSLw3....server certificate failed.

出了什么问题?这与我的网络安全有关吗?

找到解决方案。

gem source -r https://rubygems.org/

gem source -a http://rubygems.org/

删除安全的 URL,添加不安全的。我的宝石现在更新没有问题。