Ho già esaminato molte delle domande simili a questa in overflow dello stack e sto chiedendo agli dei rubini di aiuto ora.SSL_connect SYSCALL restituito = 5 errno = 0 stato = SSL leggere server ciao A (OpenSSL :: SSL :: SSLError)
im ottenere questo stack trace quando si effettua una richiesta HTTP tramite rubino:
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/net/http.rb:918:in `connect': SSL_connect SYSCALL returned=5 errno=0 state=SSLv3 read server hello A (OpenSSL::SSL::SSLError)
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/net/http.rb:918:in `block in connect'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/timeout.rb:66:in `timeout'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/net/http.rb:918:in `connect'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/net/http.rb:862:in `do_start'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/net/http.rb:851:in `start'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/net/http.rb:1367:in `request'
Alcune cose da notare:
Ho già provato l'impostazione di questi attributi oggetto http:
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.ssl_version = :TLSv1
http.ciphers = ['RC4-SHA']
http.verify_mode = OpenSSL::SSL::VERIFY_NONE
ho già provato a fissare
require 'openssl'
OpenSSL::SSL::VERIFY_PEER = OpenSSL::SSL::VERIFY_NONE
Infine, questo errore si verifica solo su una delle mie macchine. La mia ipotesi è che io abbia una versione diversa di openssl o possibile qualche gemma che viene usata per una versione diversa. Entrambi sono Mac OSX Yosemite 10.10.5
Ecco l'ambiente per la macchina che funziona:
*** LOCAL GEMS ***
activesupport (4.2.4, 3.2.22)
addressable (2.3.8)
autoparse (0.3.3)
bigdecimal (1.2.4)
bluecloth (2.2.0)
builder (3.2.2)
bundler (1.6.2)
bundler-unload (1.0.2)
curb (0.8.8)
executable-hooks (1.3.2)
extlib (0.9.16)
faraday (0.9.2)
gem-wrappers (1.2.4)
google-api-client (0.8.4)
google_drive (1.0.1)
googleauth (0.4.2)
hurley (0.2)
i18n (0.7.0)
io-console (0.4.2)
jenkins_api_client (1.4.1)
json (1.8.1)
jwt (1.5.1)
launchy (2.4.3)
little-plugger (1.1.4)
logging (2.0.0)
macaddr (1.7.1)
maruku (0.7.2)
memoist (0.12.0)
mime-types (2.3)
mini_magick (4.2.7)
mini_portile (0.7.0.rc4)
minitest (5.8.1, 4.7.5)
mixlib-shellout (2.2.1)
multi_json (1.11.2)
multi_xml (0.5.5)
multipart-post (2.0.0)
netrc (0.7.7)
nokogiri (1.6.7.rc3)
oauth (0.4.7)
oauth2 (1.0.0)
plist (3.1.0)
polyglot (0.3.5)
psych (2.0.5)
rack (1.6.4)
rake (10.3.2, 10.1.0)
rdoc (4.1.0)
representable (2.3.0)
rest-client (1.7.2)
retriable (2.1.0, 1.4.1)
rubygems-bundler (1.4.4)
rvm (1.11.3.9)
signet (0.6.1)
sqlite3 (1.3.9)
systemu (2.6.4)
terminal-table (1.5.2)
test-unit (2.1.2.0)
thor (0.19.1)
thread_safe (0.3.5)
treetop (1.5.3)
tzinfo (1.2.2)
uber (0.0.15)
unicode (0.4.4.1)
uuid (2.3.7)
here is my version of openssl:
OpenSSL 0.9.8zg 14 July 2015
Ecco il mio ambiente per la macchina che non lavorare:
*** LOCAL GEMS ***
activesupport (3.2.22)
addressable (2.3.8)
autoparse (0.3.3)
bigdecimal (1.2.0)
bluecloth (2.2.0)
builder (3.2.2)
CFPropertyList (2.2.8)
curb (0.8.8)
extlib (0.9.16)
faraday (0.9.2)
google-api-client (0.8.4)
google_drive (1.0.1)
googleauth (0.4.2)
i18n (0.7.0)
io-console (0.4.2)
jenkins_api_client (1.4.1)
json (1.8.1, 1.7.7)
jwt (1.5.1)
launchy (2.4.3)
libxml-ruby (2.6.0)
little-plugger (1.1.4)
logging (2.0.0)
macaddr (1.7.1)
maruku (0.7.2)
memoist (0.12.0)
mime-types (2.3)
mini_portile (0.6.2)
minitest (5.8.1, 4.3.2)
mixlib-shellout (2.2.2)
multi_json (1.11.2)
multi_xml (0.5.5)
multipart-post (2.0.0)
netrc (0.7.7)
nokogiri (1.6.6.2, 1.5.6)
oauth (0.4.7)
oauth2 (1.0.0)
plist (3.1.0)
polyglot (0.3.5)
psych (2.0.0)
rack (1.6.4)
rake (10.3.2, 0.9.6)
rdoc (4.0.0)
rest-client (1.7.2)
retriable (1.4.1)
signet (0.6.1)
sqlite3 (1.3.9, 1.3.7)
systemu (2.6.4)
terminal-table (1.5.2)
test-unit (2.0.0.0)
thor (0.19.1)
thread_safe (0.3.5)
treetop (1.5.3)
tzinfo (1.2.2)
unicode (0.4.4.1)
uuid (2.3.7)
here is my version of openssl: (I tried upgrading to latest, that didnt work either)
OpenSSL 1.0.1g 7 Apr 2014
In questo caso, 'OpenSSL :: SSL :: VERIFY_PEER' è una costante e quindi non può essere assegnato a. Invece, un'opzione da provare è 'http.verify_mode = OpenSSL :: SSL :: VERIFY_NONE' nelle linee seguenti' Net :: HTTP.new' –
in realtà ho provato anche questo. lascia che aggiorni la mia domanda – Rafthecalf