Registry / networking / reverse-wstunnel

reverse-wstunnel

JSON →
library1.2.2jsnpmunverified

A TCP tunnel over WebSocket for circumventing firewalls. Version 1.2.2 is the last published release, requiring Node.js ~0.10.21, and is in maintenance mode. It establishes a bidirectional tunnel by exposing a local port that forwards traffic through a WebSocket connection to a remote destination. Unlike newer alternatives like websocat or bore, wstunnel focuses on simplicity and direct proxy support (HTTP proxy, wss://).

npm install reverse-wstunnel
INSTALL
IMPORT
SIG · REVERSE-WSTUNNEL
R
reverse-wstunnel
networkingjavascriptv1.2.2
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

wstunnel
require('wstunnel')
import wstunnel from 'wstunnel'
Package is CommonJS-only, no ESM export.
wstunnel server
npx wstunnel -s 8080
wstunnel --server 8080
CLI uses short flags; long forms are not supported.
wstunnel client
npx wstunnel -t 33:2.2.2.2:33 ws://host:8080
wstunnel --tunnel 33:2.2.2.2:33 ws://host:8080
Use -t not --tunnel for tunnel argument.

Starts a WebSocket tunnel server on port 8080.

npx wstunnel -s 8080
Debug
Known issues
deprecatedPackage has not been updated since 2016 and relies on obsolete Node.js versions.
fix
Consider migrating to an actively maintained alternative like websocat or bore.
affects: >=0.0.0
gotchaUsing -c flag disables certificate validation, exposing to MITM attacks.
fix
Only use -c in trusted environments or when connecting to your own server.
affects: >=0.0.0
breakingThe package may not work with modern Node.js versions due to engine restriction (~0.10.21).
fix
Use an older Node.js version or consider alternative tools.
affects: >=12.0.0
gotchaCLI help is shown by running wstunnel without arguments; there is no --help flag.
fix
Run 'wstunnel' alone to see usage.
affects: >=0.0.0
Errors
Common errors & fixes
Error: Cannot find module 'websocket'
WebSocket dependency not installed automatically.
fix
Run 'npm install websocket' in your project or use npx which bundles dependencies.
Error: listen EADDRINUSE :::8080
Port 8080 is already in use.
fix
Specify a different port with -s, e.g., 'wstunnel -s 9000'.
wstunnel: command not found
wstunnel is not installed globally or not in PATH.
fix
Run 'npx wstunnel' or install globally with 'npm install -g wstunnel'.
TypeError: Cannot read property 'on' of undefined
Invalid arguments order or missing tunnel specification.
fix
Ensure correct syntax: 'wstunnel -t localPort:remoteHost:remotePort ws://server:port'.
Upgrade
Version history
1.2.2latest on npm
Audit
Dependencies
websocketoptionalWebSocket client/server implementation
optimistoptionalCommand-line argument parsing
Agent activity
19 hits · last 30 days
node
16
OpenAI (training)
1
Resources
reverse-wstunnel — npm install reverse-wstunnel · libregistry