Skip to content

Instantly share code, notes, and snippets.

@kont-noor
Forked from kendagriff/solution.md
Created September 28, 2017 13:07
Show Gist options
  • Save kont-noor/e53ad4690a0329b1cd7b6b000c45c7a5 to your computer and use it in GitHub Desktop.
Save kont-noor/e53ad4690a0329b1cd7b6b000c45c7a5 to your computer and use it in GitHub Desktop.
Solution to "OpenSSL::X509::StoreError: setting default path failed: Invalid keystore format" for JRuby

Solution to StoreError: invalid keystore format (OS X)

The following error appeared upon upgrading JRuby:

OpenSSL::X509::StoreError: setting default path failed: Invalid keystore format

Download cacert.pem

wget http://curl.haxx.se/ca/cacert.pem

Create a keystore from the file

sudo keytool -importcert -file cacert.pem -keystore /Users/youruser/.keystore

Set SSL_CERT_FILE

export SSL_CERT_FILE=/Users/youruser/.keystore

Install gems

jruby -S gem install whatever
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment