I'm making the following call to branch.io
import requests req = requests.get('https://bnc.lt/m/H3XKyKB3Tq', verify=False)
It works fine in my local machine but fails in the server.
SSLError: [Errno 1] _ssl.c:504: error:14077410:SSL routines:SSL23_GET_SERVER_HELLO:sslv3 alert handshake failure
Openssl versions:
local: OpenSSL 0.9.8zg 14 July 2015
server: OpenSSL 0.9.8e-fips-rhel5 01 Jul 2008
Python:
local: 2.7.10 server: 2.7.6
Branch io server connection:
Chrome verified that DigiCert SHA2 Secure Server CA issued this website's certificate. The server did not supply any Certificate Transparency information.
I tried urllib2, but the result was same. Any help?
If the TLS/SSL handshake succeeds, then the TLS/SSL client and server transfer data to each other securely. Otherwise, if a TLS/SSL handshake failure occurs the connection is terminated and the client receives a 503 Service Unavailable error. The protocol used by the client is not supported by the server.
This SSL/TLS Handshake Failed Error occurs whenever the OS hasn't granted the read access to the OS, ultimately preventing the complete authentication of the webserver, which indicates that the browser's connection with the web server is not secure.
Jyo de Lys has identified the problem. The problem is described here and the solution is here. I did the following to get this working:
If you're getting this error while using urllib2, you'll need to upgrade to python 2.7.9 or later too.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With