Skip to content

Latest commit

 

History

History
66 lines (43 loc) · 2.96 KB

File metadata and controls

66 lines (43 loc) · 2.96 KB

WebSocket sessions and WS Flow

Proxied WS / WSS connections sit next to HTTP in Capture. You can inspect the handshake and frames, search, simulate send, intercept text frames, and export HAR. When you need a fake server, enable WS Flow.

Single-file Flow and the session tools are available in 1.4.0 Beta. Multi-file workspaces and forwarding to a real upstream are still evolving — trust the in-app UI.

Full manual: WebSocket docs · WS Flow tutorial · .dpws reference · 中文


Capture a connection

The client must use the DevPeek proxy. WSS also needs a trusted CA and the host on the SSL include list (and not on exclude).

  1. In Capture, select the client tab and filter for WebSocket.
  2. Expand WebSocket connections under the HTTP list.
  3. Overview = URL and state; Handshake = Upgrade; Session = frames.
  4. The HTTP Upgrade row and the connection stay secondarily highlighted so you can jump between them.

Frames, simulate send, intercept

  • Filter by client/server direction; search payload text; hide Ping / Pong / Close.
  • Copy a text frame, or fill it into the composer, edit, and send again.
  • While the socket is Open, simulate client or server frames. Closed connections are read-only.
  • Intercept text frames pauses new text frames before the peer sees them. Edit and resume, or drop. You do not need a Flow for one-off edits.

HAR export can dump all frames, the current filter, the latest 500 / 2000 / 10000, or a window around one business frame. Control frames are omitted. Scrub tokens before sharing.


WS Flow as a virtual server

Open the right-rail WS Flow panel (or Proxy → WS Flow settings). This is a closable tool, not a permanent sidebar page.

When # ws matches and the file header has # upstream off, DevPeek does not connect to the real upstream. The Flow’s match → return → scope → lifecycle rules reply instead.

Right rail → WS Flow → new single-file rule
        ↓
Fill title, # ws, and body → Validate
        ↓
Save, enable, reconnect the client

Validate before apply: E errors block save; review W warnings for your scenario. # idle-timeout can close idle virtual sockets (0 / off = never).


Typical failures

Symptom Check
Handshake but no readable WSS frames CA trust, SSL include/exclude, certificate pinning
Flow does not match Rule enabled, new connection, # ws vs the real URL
Immediate disconnect Validation, # ping auto, # idle-timeout, unmatched behavior
Intercept disabled The connection is no longer Open

Related