Probably most of you have at one point encountered SSL errors on ruby and I know I have spent a good portion of a day figuring why the certificates installed wouldn’t work.

If you get something like this then read on for the fix:

C:/Ruby23-x64/lib/ruby/2.3.0/net/http.rb:933:in `connect_nonblock': SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed (OpenSSL::SSL::SSLError)

You need to download the latest CA certificate and I suggest this CACERT download.

Create a new folder C:\certs and add the cacert.pem certificate there.

And now you need a new System Environment Variable: SSL_CERT_FILE=C:\certs\cacert.pem