-
Notifications
You must be signed in to change notification settings - Fork 166
Description
When trying to use beaver with tcp transport and ssl enabled, I get an exception. My backend is haproxy with ssl enabled. I tried to connect to same haproxy with other clients like kibana and it worked fine. So haproxy configuration seems to be correct. I have tried using self signed certificates on OS X and CentOS 7.2, and I get the same error.
This is the code line:
ssl.wrap_socket(self._sock,ssl_version=ssl.PROTOCOL_SSLv23,cert_reqs=ssl.CERT_NONE, ca_certs=<path to ca crt>)
I have tried all possible arguments in ssl.wrap_socket() method. Please help me with this issue.
Process Process-1:2: Traceback (most recent call last): File "/usr/local/Cellar/python/2.7.10_1/Frameworks/Python.framework/Versions/2.7/lib/python2.7/multiprocessing/process.py", line 258, in _bootstrap self.run() File "/usr/local/Cellar/python/2.7.10_1/Frameworks/Python.framework/Versions/2.7/lib/python2.7/multiprocessing/process.py", line 114, in run self._target(*self._args, **self._kwargs) File "/usr/local/lib/python2.7/site-packages/Beaver-36.0.0-py2.7.egg/beaver/run_queue.py", line 25, in run_queue transport = create_transport(beaver_config, logger=logger) File "/usr/local/lib/python2.7/site-packages/Beaver-36.0.0-py2.7.egg/beaver/transports/__init__.py", line 20, in create_transport transport = transport_class(beaver_config=beaver_config, logger=logger) File "/usr/local/lib/python2.7/site-packages/Beaver-36.0.0-py2.7.egg/beaver/transports/tcp_transport.py", line 25, in __init__ self._connect() File "/usr/local/lib/python2.7/site-packages/Beaver-36.0.0-py2.7.egg/beaver/transports/tcp_transport.py", line 52, in _connect self._sock = ssl.wrap_socket(self._sock,ssl_version=ssl.PROTOCOL_SSLv23,cert_reqs=ssl.CERT_NONE, ca_certs='/Users/akuncham/development/beaver_new/ssl2/server.crt',suppress_ragged_eofs=False) File "/usr/local/Cellar/python/2.7.10_1/Frameworks/Python.framework/Versions/2.7/lib/python2.7/ssl.py", line 911, in wrap_socket ciphers=ciphers) File "/usr/local/Cellar/python/2.7.10_1/Frameworks/Python.framework/Versions/2.7/lib/python2.7/ssl.py", line 579, in __init__ self.do_handshake() File "/usr/local/Cellar/python/2.7.10_1/Frameworks/Python.framework/Versions/2.7/lib/python2.7/ssl.py", line 808, in do_handshake self._sslobj.do_handshake() SSLError: [SSL: UNKNOWN_PROTOCOL] unknown protocol (_ssl.c:590)