Some platforms, particularly Microsoft Windows, will display the following message when you try to use a gem that utilizes SSL:

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

Fortunately there is a relatively easy fix that you can perform that should make this issue go away.

  1. First, download this file and place it somewhere on your file system. If you are using Windows, i recommend your Ruby folder.
  2. Next, rename the cacert.pem.txt file to cacert.pem
  3. Next, set an environment variable called SSL_CERT_FILE. The contents of the environment variable should be the path to the cert file you downloaded. For instance C:\Ruby200\cacert.pem.
  4. Finally, close and reopen your terminal windows and/or command prompt.

Once you restart your Rails server the issue should go away. That's it! Thanks for reading!