socketio / socket.io-client-cpp

C++11 implementation of Socket.IO client
MIT License
2.26k stars 729 forks source link

Connecting with "wss://" #95

Closed nwestbury closed 8 years ago

nwestbury commented 8 years ago

I've compiled the library successfully and connecting to the localhost with "ws://" URI works fine.

But when I try to connect to the external server (which uses encryption) "wss://" fails with the following:

[2016-05-08 17:07:27] [connect] Successful connection [2016-05-08 17:07:28] [error] handle_read_http_response error: websocketpp.transport:7 (End of File)

What are the steps I need to take in order to connect to a server with TLS encryption? Thanks!

melode11 commented 8 years ago

You need to recompile the lib with SIO_TLS macro to make it a secured socket.io client.

nwestbury commented 8 years ago

Thanks for the reply reply but could you show me how? I've tried make CXX-flags=-DSIO_TLS to no avail