How to get soap4r to not bother verifying SSL certificate (verify_mode none)?

Using Ruby 1.8.7, Rails 2.3.8. I don't want it to verify the cert...

This is my backtrace:

OpenSSL::SSL::SSLError (SSL_connect returned=1 errno=0 state=SSLv3 read
server certificate B: certificate verify failed):
  httpclient ( lib/httpclient/session.rb:247:in `connect'
  httpclient ( lib/httpclient/session.rb:247:in `ssl_connect'
  httpclient ( lib/httpclient/session.rb:639:in `connect'
  httpclient ( lib/httpclient/timeout.rb:128:in `timeout'
  httpclient ( lib/httpclient/session.rb:631:in `connect'
  httpclient ( lib/httpclient/session.rb:522:in `query'
  httpclient ( lib/httpclient/session.rb:147:in `query'
  httpclient ( lib/httpclient.rb:953:in `do_get_block'
  httpclient ( lib/httpclient.rb:765:in `do_request'
  httpclient ( lib/httpclient.rb:848:in
  httpclient ( lib/httpclient.rb:764:in `do_request'
  httpclient ( lib/httpclient.rb:666:in `request'
  httpclient ( lib/httpclient.rb:596:in `post'
  (eval):6:in `getDataBySecure'

Using Ruby 1.8.7, Rails 2.3.8. I don't want it to verify the cert...

I think you can do something like
driver.options["protocol.http.ssl_config"] = {'verify_mode' => foo} or
maybe driver.options["protocol.http.ssl_config.verify_mode"] = foo


I tried that. In ~GEM_HOME/gems/soap4r-1.5.8/lib/soap/netHttpClient.rb,
I changed it to:

180 if SSLEnabled
181 http.ssl_config.verify_mode = nil
182 http.use_ssl = true

And I also tried with

http.ssl_config.verify_mode = (OpenSSL::SSL::VERIFY_NONE)

None of those seem to work.

It works locally... Hmm. My OpenSSL versions differs on the server and
locally. That's probably the culprit.

You tried what i suggested or you tried the monkey patch you posted below? It's worth noting that soap4r will use the httpaccess gem if it is present, falling back to net/http if it isn't - I think you may only have monkeypatched the net/http part of soap4r