Example code "sslechoclient.html" not connecting to sslechoserver



  • Hello,

    I am trying to run the example project sslechoserver in Qt 5.4 on Ubuntu 14.04 32 Bit. The server runs just fine and the sslechoclient example project can connect to the server, too, but when I try to run sslechoclient.html (which can be found in the folder of the sslechoserver example project) and I click the connect button I get "ERROR: undefined", followed by "DISCONNECTED".

    I found out that the html file's error is being thrown inside the "websocket.onerror" function and not in the catch-block inside the "initWebSocket" function.

    If I click the state button after this error happened, I get "WebSocket state = 3 ( CLOSED )".

    Unfortunately I have no idea what went wrong exactly. Does anyone know how to solve this?

    Cheers
    Alex



  • Additional info:
    I installed the example client and server from http://www.tutorialspoint.com/html5/html5_websocket.htm
    The server was accessible from all 3 of my clients (the Html/Js-Clients from both examples as well as the Qt client from C++). The Qt server however was only accessible from the Qt C++ client.

    Since the Python server uses unencrypted connections, I tested this, too, but the Python server gave me a reaction to encrypted connections, too (i.e. an error), while the Qt server didn't react at all no matter what kind of connection was tried to make.

    Also I retrieved the onClosed-code in case of the error in the Qt server. It is 1006, which means that apparently the server was not found at all.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.