8000 websocket middleware usage and examples needed, eg sniffing · Issue #110 · h2non/rocky · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on Mar 16, 2022. It is now read-only.
This repository was archived by the owner on Mar 16, 2022. It is now read-only.
websocket middleware usage and examples needed, eg sniffing #110
Open
@nqzero

Description

@nqzero

the readme mentions that websocket middleware can be called with rocky.useWs() but there isn't an example of doing anything useful (the example just calls next())

i'm trying to use rocky to log websocket messages

using nodejitsu's http-proxy (which i believe rocky is built on top of) i've used socket.on("data") during the upgrade to run a handler, but the data appears to be in a binary format. i'd like to be able to access the underlying text stream that i see in the client using devtools

using rocky, i haven't even gotten this far (i'm getting socket hang up errors). however, looking through the source i don't see any logic that appears to decode the binary stream. so i'm not spending effort to debug my rocky usage until i determine if the middleware support is truly middleware

does rocky support this usage ?

the use of "websocket middleware" suggests that it can. if not, the readme should be updated

side question ... if rocky can't do this, could you suggest another technique or tool to achieve my goal

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0