Skip to content

Instantly share code, notes, and snippets.

@the-teacher
Created October 10, 2016 10:41
Show Gist options
  • Save the-teacher/c7bf06e6cfcd3366c589481973e59be3 to your computer and use it in GitHub Desktop.
Save the-teacher/c7bf06e6cfcd3366c589481973e59be3 to your computer and use it in GitHub Desktop.
Fix for `ssl_connect returned=1 errno=0 state=sslv3 read server certificate b: certificate verify failed`

http://railsapps.github.io/openssl-certificate-verify-failed.html

Finally solve the problem:

brew install openssl
brew link openssl

cd /usr/local/etc/openssl/certs/
sudo curl -O https://curl.haxx.se/ca/cacert.pem
sudo mv cacert.pem cert.pem
cd -
echo "export SSL_CERT_FILE=/usr/local/etc/openssl/certs/cert.pem" >> ~/.bash_profile
source ~/.bash_profile
@the-teacher
Copy link
Author

unset SSL_CERT_FILE

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment