Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Problems creating new Rails project: "There is a chance you are experiencing a man-in-the-middle attack"

Tags:

ruby

I've never seen this before, and a simple Google search for this exact message turns up nothing. Stack Overflow is

run  bundle install
Fetching source index from https://rubygems.org/
Resolving dependencies...
Could not verify the SSL certificate for https://rubygems.org/.
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
bit.ly/ssl-certs. To connect without using SSL, edit your Gemfile sources and change 'https'   to 'http'.

I followed the instructions on this page, and came up empty handed:

http://www.beginnerruby.com/rails-troubleshooting/fixing-opensslbundler-issue-for-rails-on-debian/

Anybody have any ideas?

Mac OSX Lion using RubyMine.

like image 288
jake Avatar asked Feb 18 '23 07:02

jake


2 Answers

I followed these instructions with no obvious results. Reading the comments somebody asked if the Terminal was re-opened. So, I closed/opened the terminal. That fixed my problem. I'm using SnowLeopard.

$ brew update
$ brew install openssl
$ brew link openssl --force
$ brew install curl-ca-bundle
$ brew tap raggi/ale
$ brew install openssl-osx-ca
like image 114
Merovex Avatar answered May 03 '23 00:05

Merovex


I think interpreting the exception should be straightforward(though I may be wrong) change source 'https://rubygems.org' at the top of your Gemfile to: source 'http://rubygems.org'

like image 24
bjhaid Avatar answered May 03 '23 00:05

bjhaid