hunt-websocket

Detect WebSocket vulnerabilities including CSWSH, missing message authentication, and namespace authorization bypasses.

Updated Sep 6, 2026
One-click install
npx skills add https://github.com/inventashif/helpful-code-sidekick --skill hunt-websocket-inventashif
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: hunt-websocket
Source: https://github.com/inventashif/helpful-code-sidekick/tree/main/scripts/hackerai/skills/bughunter/hunt-websocket
Command: npx skills add https://github.com/inventashif/helpful-code-sidekick --skill hunt-websocket-inventashif

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? WebSocket endpoints are often overlooked during security testing, leaving real-time features like chat, notifications, and trading platforms exposed to hijacking, tampering, and cross-tenant data leaks. This Skill provides a structured methodology to find and validate WebSocket vulnerabilities during authorized bug bounty hunting. ## Core Features & Use Cases - CSWSH Detection: Test for Cross-Site WebSocket Hijacking by validating the three required conditions (cookie-authenticated handshake, no per-connection token, missing Origin enforcement) with a real attacker-origin PoC and out-of-band exfiltration proof. - Message-Layer Testing: Probe for missing per-message authentication, signed-message replay, state machine bypasses, and tampering of financial values like price, amount, and userId. - Protocol-Specific Attacks: Test socket.io namespace and room authorization bypasses, SignalR hub method authorization, Phoenix Channels topic joins, and handshake-layer Upgrade smuggling between proxies and origins. - Use Case: While testing a trading platform's bug bounty program, you discover a wss:// endpoint, confirm the handshake relies only on cookies, and prove CSWSH by receiving a separate victim account's data in an attacker-hosted page with OAST confirmation. ## Quick Start Ask the AI to hunt for WebSocket vulnerabilities on your authorized bug bounty target, starting with endpoint discovery and CSWSH testing.

Frequently Asked Questions about hunt-websocket

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I test for Cross-Site WebSocket Hijacking (CSWSH)?

CSWSH testing requires confirming three conditions: the handshake authenticates via ambient cookies, no unpredictable per-connection token exists, and the server does not enforce Origin. A bare 101 response from a foreign Origin is not proof; you must receive a different victim account's data in an attacker-hosted page and exfiltrate it to an OAST listener.

How to test socket.io namespace authorization bypass?

Open the raw socket.io WebSocket, then send a CONNECT packet like 40/admin, to join a privileged namespace. The bug is confirmed only when you receive 42 event frames containing another user's data, not just a successful namespace acknowledgment.

Does a 101 response from a foreign Origin confirm CSWSH?

No, a completed 101 handshake only proves the upgrade succeeded. Many servers accept the connection but validate Origin at the message layer or refuse to stream authenticated data, so you must demonstrate actual receipt of victim data.

What tools are needed for WebSocket security testing?

The methodology uses wscat or websocat as CLI WebSocket clients, curl for handshake probing, and Burp Suite Pro for WebSocket history interception, the HTTP Request Smuggler extension, and Collaborator for out-of-band proof.

Why is typing HTTP requests into an open WebSocket not request smuggling?

Once a WebSocket is established, payloads are wrapped in WS frames and never re-parsed as HTTP by the proxy. Real WebSocket smuggling happens at the handshake layer, where malformed Upgrade or Sec-WebSocket-Version headers make the front proxy and origin disagree on whether an upgrade occurred.

When is WebSocket message tampering a valid finding?

Tampering is valid only when the modified value, such as price or userId, persists server-side and is confirmed via a second channel like the order or balance API. A UI echoing your own frame back optimistically is not proof of impact.