Get the underlying web socket instance
Closes the web socket.
Optional
reason: stringThe reason for closing. If specified it is sent unencrypted to the remote side!
Releases the underlying websocket, so that it can be used by another class.
Attention: If messages arrive in the meantime they might get lost.
Send authentication request message.
the publicKey of the communication server
the challenge that has to be decrypted by the receiver and sent back in an authentication response message
Send the authentication success message.
Send the connection handover message.
Send Ping Message
Starts pinging the client.
Interval since last pong when to send another ping.
Time to wait for the pong (after a ping) before severing the connection.
Stops the ping / pong process.
If currently waiting for a pong, then the promise resolves
Wait for an arbitrary client message.
Wait for a client message with certain type.
expected command of message.
This class implements the server side of communication server communication.