SSL: WRONG_VERSION_NUMBER
I have tried to run the webrtc/sendrecv/gst/webrtc_sendrecv.py example, but I am not able to get it to work.
All the sendrecv-gst containers (sendrecv-gst, sendrecv-gst-java, and sendrecv-gst-rust) fail to build, so I tried to start the sendrecv-js
and signalling
containers using the webrtc/docker-compose.yml script (with all the sendrecv-gst containers disabled). Then I ran python webrtc/sendrecv/gst/webrtc_sendrecv.py 1 --server=wss://127.0.0.1:8443
.
I got the following error, which (after some googling) seems to be related to server expecting TLS, while client offers SSL.
Traceback (most recent call last):
File "sendrecv/gst/webrtc_sendrecv.py", line 189, in <module>
loop.run_until_complete(c.connect())
File "/usr/lib/python3.6/asyncio/base_events.py", line 484, in run_until_complete
return future.result()
File "sendrecv/gst/webrtc_sendrecv.py", line 40, in connect
self.conn = await websockets.connect(self.server, ssl=sslctx)
File "/home/niwi/.local/lib/python3.6/site-packages/websockets/client.py", line 535, in __await_impl__
transport, protocol = await self._create_connection()
File "/usr/lib/python3.6/asyncio/base_events.py", line 820, in create_connection
sock, protocol_factory, ssl, server_hostname)
File "/usr/lib/python3.6/asyncio/base_events.py", line 846, in _create_connection_transport
yield from waiter
File "/usr/lib/python3.6/asyncio/sslproto.py", line 505, in data_received
ssldata, appdata = self._sslpipe.feed_ssldata(data)
File "/usr/lib/python3.6/asyncio/sslproto.py", line 201, in feed_ssldata
self._sslobj.do_handshake()
File "/usr/lib/python3.6/ssl.py", line 689, in do_handshake
self._sslobj.do_handshake()
ssl.SSLError: [SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:852)