Troubleshooting Ssl Certificates, Ruby, MAC Os X Yosemite

Error Certificate verify failed (certificate has expired)): in Mac OSX 11.6.1 and ruby 3.0.3

The solution to this question was provided in another post by @jangaraj

It looks like you are using Ubuntu 14 and Savon 2 client. Savon 2 client doc: https://www.savonrb.com/version2/globals.html

ssl_ca_cert_file

Sets the SSL ca cert file to use.

Savon.client(ssl_ca_cert_file: "lib/ca_cert.pem")

I would point ssl_ca_cert_file to /etc/ssl/certs/ca-certificates.crt explicitly.

How to fix curl: (60) SSL certificate: Invalid certificate chain

Using the Safari browser (not Chrome, Firefox or Opera) on Mac OS X 10.9 (Mavericks) visit https://registry.npmjs.org

Screenshot of Safari showing certificate error

Click the Show certificate button and then check the checkbox labelled Always trust. Then click Continue and enter your password if required.

Always trust checkbox

Curl should now work with that URL correctly.

Could not verify the SSL certificate for https://rubygems.org/

I had this problem on Mac OS X Yosemite with ruby 2.3.1.
I fixed the problem by downloading http://curl.haxx.se/ca/cacert.pem to
/usr/local/etc/openssl/

and adding this line export SSL_CERT_FILE=/usr/local/etc/openssl/cacert.pem to .bash_profile

Credit to Can't run Ruby 2.2.3 with RVM on OSX but it was hard to google the right answer, so added to this page.

SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed on Mac

You need to update certificates:

sudo curl http://curl.haxx.se/ca/cacert.pem -o "$(ruby -ropenssl -e "p OpenSSL::X509::DEFAULT_CERT_FILE")"

Although this is considered to be not safe as the certificates are downloaded without https and there is no way to tell if they were not changed on the way.

RVM has updated code that will use OSX certificates to update the file and will pull automatically dependencies, you can get it with:

rvm get head
rvm install 1.9.3


Related Topics



Leave a reply



Submit