Skip to content
This repository was archived by the owner on Oct 20, 2022. It is now read-only.
This repository was archived by the owner on Oct 20, 2022. It is now read-only.

Fix non-working Router options.handleProtocols and options.disableProtocolCheck #23

@kenklin

Description

@kenklin

The Router constructor's options.handleProtocols handling seems like it is meant to either ...

  1. use the caller's options.handleProtocols, if supplied, or
  2. use the its default implementation accepting only the "wamp.2.json" subprotocol, or
  3. not supply handleProtocols at all to WebSocket.Server if options.disableProtocolCheck is true.

None of these seem to currently work. This can be seen by running node examples/basic and Autobahn's client at https://github.com/crossbario/autobahn-js code testing basic.js.

In wamp.rt, handleProtocol signature's second argument is a cb callback function which does not match WebSocket.Server options's handleProtocol's request causing problems. Perhaps this was left over from some other non-ws early web socket implementation that is non-compatible?

A fix will appear in https://github.com/kenklin/wamp.rt

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions