M HYPE SPLASH
// general

I'm getting this error when I generate a new rails application

By Emma Payne
Fetching source index from
Retrying source fetch due to error (2/3): Bundler::Fetcher::CertificateFailureError Could not verify the SSL certificate for rubygems.
There is a chance you are experiencing a man-in-the-middle attack, but most likely your system doesn't have the CA certificates needed for verification. For information about OpenSSL certificates, see To connect without using SSL, edit your Gemfile sources and change 'https' to 'http'.
Retrying source fetch due to error (3/3): Bundler::Fetcher::CertificateFailureError Could not verify the SSL certificate for ruby gem.
There is a chance you are experiencing a man-in-the-middle attack, but most likely your system doesn't have the CA certificates needed for verification. For information about OpenSSL certificates, see To connect without using SSL, edit your Gemfile sources and change 'https' to 'http'.
Could not verify the SSL certificate for rubygems.
There is a chance you are experiencing a man-in-the-middle attack, but most
likely your system doesn't have the CA certificates needed for verification. For
information about OpenSSL certificates, see To connect without
using SSL, edit your Gemfile sources and change 'https' to 'http'. run bundle exec spring binstub --all

I ran gem update --system, but it did not work. I came down with another error:

ERROR: While executing gem ... (Gem::RemoteFetcher::FetchError) SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed ()

What is going on here and how can I fix it? Thank you

3

2 Answers

This issue usually occurs with old versions of rubygem. You can try updating it by running

gem update --system --source 

and after that

gem update

source.

5

Create a new file .gemrc in your home directory and add this line.

:ssl_verify_mode: 0

Now, it should continue even if it can't verify that the SSL connection is "trusted".

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy