Subscribe

WFA API - SSL error when doing API GET via Ruby RestClient

Hey Netapp folks,

 

 

The WFA APIs work great unil we try to call them via Ruby code using the RestClient gem.  Other gems have the same issue and calls to other servers using APIs are working fine.  Is this an SSL config issue on the WFA server.  We are running it on Windows 2012, WFA 4.1rc, signed SSL cert. 

 

It returns..."OpenSSL::SSL::SSLError: SSL_connect returned=1 errno=0 state=SSLv3/TLS write client hello: sslv3 alert handshake failure".

 

Anyone run into this??

Re: WFA API - SSL error when doing API GET via Ruby RestClient

@mbrownie1

 

 

When you use http instead of https, does it work?

 

Can you post your ruby code?

If this post resolved your issue, help others by selecting ACCEPT AS SOLUTION or adding a KUDO.

Re: WFA API - SSL error when doing API GET via Ruby RestClient

Hi,

     You can try to use TLS protocol while establishing the connection instead of SSLv3 which is disabled in WFA.

 

 

Anu

Re: WFA API - SSL error when doing API GET via Ruby RestClient

[ Edited ]

@sinhaa

 

Yes, http works (however, we of course diable http access in prod)

 

Here is an example of the code....

 

require 'openssl'
require 'rest-client'

 

@Job_status = (RestClient::Request.execute(
:method => :get,
:url => "https://netappwfa-server.com/rest/workflows/jobs?jobStatus=COMPLETED",
#:payload => '{}'
:headers => {:content_type => 'application/json'},
:verify_ssl => false,
))

puts @Job_status

Highlighted
Frequent Contributor

Re: WFA API - SSL error when doing API GET via Ruby RestClient

Can you try adding this property to the request -

:ssl_version => 'TLSv2'