1
votes
agent = Mechanize.new
agent.redirect_ok = true
agent.read_timeout = 300
agent.ssl_version = :TLSv1
agent.verify_mode = OpenSSL::SSL::VERIFY_NONE
agent.get('https://consumer.etoolbox.buildingcommission.com.au/Pages/Search.aspx')

its not running, it gave this error.

OpenSSL::SSL::SSLError: SSL_connect SYSCALL returned=5 errno=0 state=SSLv3/TLS write client hello

1

1 Answers

-3
votes

I found issue by myself. The issue was the version of ruby, my version is 2.4.1 so I change it to 2.3.1. And it works for me.