Created
March 8, 2012 10:48
-
-
Save vladzloteanu/2000372 to your computer and use it in GitHub Desktop.
OSX Lion: SSL verification issue: Reinstall Ruby with OpenSSL support (with rvm)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Bug report: http://www.ruby-forum.com/topic/208026 | |
# | |
## Reproduce bug | |
require 'socket' | |
require 'openssl' # Should return true | |
s = TCPSocket.new 'bugzilla.redhat.com', 443 | |
ctx = OpenSSL::SSL::SSLContext.new | |
ctx.verify_mode = OpenSSL::SSL::VERIFY_PEER | |
s = OpenSSL::SSL::SSLSocket.new s, ctx | |
s.connect # Should throw OpenSSL::SSL::SSLError | |
# | |
## Reinstall ruby with openssl support | |
rvm pkg install openssl | |
rvm reinstall ree-1.8.7-2012.02 -C --with-openssl-dir=$HOME/.rvm/usr | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment