-
Notifications
You must be signed in to change notification settings - Fork 52
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Errno::ECONNRESET: Connection reset by peer - SSL_connect #13
Comments
I ran a test against their API (https://www.ssllabs.com/ssltest/analyze.html?d=swsim.stamps.com) and it seems that it's failing with TLS 1.2 and SSLv2. Does anyone have experience forcing a different TLS / SSL version with this gem? It seems like a solution would be to force SSLv3 and TLS 1.0. |
Hey @dsteadman. Sorry, I have not come across this issue before with stamps. I've tried it locally, but not getting the same error. I remember having OpenSSL and RVM issues with my Ruby version a while back. I'm not sure if it’s the same issue you're having though. |
I'm also seeing this issue when testing on ubuntu with rvm 1.22.3, ruby-2.0.0, and rails 3.2.14. @mattsears what were the issues you were having? Is there a way to explicitly configure the gem to use different TLS / SSL? |
I also just tried with a fresh rails project (ruby 1.9.3, rails 3.2.14) and I'm getting the same issues. My stamps settings look like this (with the correct integration id and u/p)
Gems look like this:
thanks for any insight. |
If anyone is still having this issue, I was able to resolve it by downgrading rvm to a version that includes openssl 0.9.8 curl -L https://get.rvm.io | bash -s -- --version 1.14.7 Noticed this looking around dsteadmans link (https://www.ssllabs.com/ssltest/analyze.html?d=swsim.stamps.com) and openssl 1.0.1 fails with handshake simulation. |
Thank you for your reponse, @v-fedorov. That solution worked for me too. |
I think the issue is related to the Stamps API only negotiating with clients running SSLv3. If you try their health endpoint using curl, I can only get it to work from our staging box using the --sslv3 switch:
I also get the same result if I try openssl s_client without forcing SSLv3. This worked for me:
Without forcing these options, the client is supposed to figure out the best protocol version to use and everything should just workTM. It seems that with our server setup that isn't happening. As I don't have control over setting this in my case, the workaround was to force SSLv3 at the Savon level. In my branch, I ended up configuring Savon and telling it the version and where the main ca_cert file is (the presence of which forces the underlying HTTPI adapter to use SSL).
If anyone can suggest a better way of forcing SSLv3, or avoid declaring the ssl_ca_cert_file (without verify none!) in a more platform independent way, please let me know. |
Any progress on this bug? I'm still having issues to no avail. I'm also a novice at web technologies so I'm stumbling through the SSLv3 and SSL certs issues. |
I recommend updating rvm.io using the following command \curl -L https://get.rvm.io | bash -s stable It has worked for me. |
I'm in China, I get the same problem because of the GFW(Great FireWall). |
I was looking for a while already, to get this nasty bug fixed while running most recent versions of Ruby and gem on Ubuntu 14.04. Then I read zhizouxiaos comment. Sitting in China as well, I should have tried with a VPN earlier. Made my day. Thanks for giving this hint! |
Mario you can just use Chinese mirror http://ruby.taobao.org/ |
Thanks for this advice lammersons. Tried, and works flawlessly without VPN. |
@zhizouxiao @lamersons ,Thanks for your responses, I met the same problem and tried several ways but no effect, your advice and solution save my day. |
@lamersons thank you very much , it worked! |
Same here, thank you @lamersons! |
What finally did it for me. Shutting down IPv6 ! networksetup setv6off "Wi-Fi" All is good now. I'm on macOS, by the way. |
Running 1.9.3 and Rails 3.2.14
I've been getting
Errno::ECONNRESET: Connection reset by peer - SSL_connect
I've tried this on multiple dev machines, made sure it wasn't an issue with openssl, all to no avail. Anyone experience the same / have a suggestion for what could be causing it?
Thanks
The text was updated successfully, but these errors were encountered: