You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've searched for any related issues and avoided creating a duplicate
issue.
Description
I'm using the handleProtocols property when creating a server to force clients connecting to the server to send the name of the required protocol. But when the client doesn't send any protocol, the function is not executed so validation can't be done.
Reproducible in:
version: 6.2.1
Node.js version(s): v8.15.1
Steps to reproduce:
Create a WebSocket.Server with a function in the handleProtocols property of the Options object
Create a client connecting with the server that doesn't send the Sec-WebSocket-Protocol.
The connection is established without calling the handleProtocols function.
Expected result:
I expect it to be executed always to be able to reject the request if the required protocol is not sent by the client.
Actual result:
Function is not executed and the socket is established.
issue.
Description
I'm using the
handleProtocols
property when creating a server to force clients connecting to the server to send the name of the required protocol. But when the client doesn't send any protocol, the function is not executed so validation can't be done.Reproducible in:
Steps to reproduce:
Create a
WebSocket.Server
with a function in thehandleProtocols
property of the Options objectCreate a client connecting with the server that doesn't send the
Sec-WebSocket-Protocol
.The connection is established without calling the handleProtocols function.
Expected result:
I expect it to be executed always to be able to reject the request if the required protocol is not sent by the client.
Actual result:
Function is not executed and the socket is established.
Attachments:
The text was updated successfully, but these errors were encountered: