Search code examples
rubyrvmosx-mountain-lionruby-1.9.3rest-client

"bad ecpoint" SSL error on fresh RVM Ruby 1.9.3 install on OSX Mountain Lion


Trying to use Ruby 1.9.3 & rest-client to make https requests like:

RestClient.get('https://google.com')

always gives me a SSL error,

OpenSSL::SSL::SSLError: SSL_connect returned=1 errno=0 state=SSLv3 read server key exchange B: bad ecpoint

which I cannot figure out. bad ecpoint?

I've had no trouble making the same request with 1.9.3 & rest-client on another Mountain Lion machine.

Notes about this machine: MacBook pro with fresh Mountain Lion install, where I originally had some trouble installing gcc-4.2 via the XCode command line tools, but eventually got gcc-4.2 via homebrew/dupes. I've uninstalled & reinstalled RVM and 1.9.3 since then.


Solution

  • Explaining my comment...

    Update RVM to latest development version (but stable should work too):

    rvm get head
    

    Install all required libraries for ruby (autolibs=4 is for full automation):

    rvm --autolibs=4 --debug requirements
    

    Finally reinstall ruby:

    rvm reinstall 1.9.3
    

    You can enable full library automation within RVM for next commands with:

    rvm autolibs enable