I installed Ruby 2.0.0 on Windows XP, and run this script:
# testSSL.rb
require 'open-uri'
open('https://www.google.com')
I get a "certificate verify failed" error on http.rb line 921. Testing further, it seems that Ruby looks for the SSL certificates files here:
C:/Users/Justin/Projects/knap-build/var/knapsack/software/x86-windows/openssl/1.0.1l/ssl
How can I tell Ruby to look for these files where they were installed:
C:/Ruby200/lib/ruby/2.0.0/rubygems/ssl_certs.
Any help will be greatly appreciated!
Like this, but you get a warning because you overwrite a constant
or like this
In both cases followed by
You can download a valid .pem file from http://curl.haxx.se/ca/cacert.pem. Save this file to with the extension .pem in the path and with the name you reference in your script.