Skip to content

Broker Mode

Chokri Hammedi edited this page Aug 2, 2026 · 1 revision

Broker Mode

Broker mode accepts multiple clients and forwards received bytes to the other connected clients. It is useful for manual collaboration, local labs, CTFs, debugging, and simple multi-peer terminal chat.

It is not a C2 component. It does not provide persistence, stealth, autonomous operation, embedded scripting, or tasking behavior.

Basic Broker

Start a broker:

wcat broker 0.0.0.0 5555

Connect clients:

wcat connect 127.0.0.1 5555

Chat Mode

--chat prefixes relayed messages with client labels and escapes terminal control bytes.

wcat broker --chat 0.0.0.0 5555

Client Limits

Limit connected clients:

wcat broker --chat --max-clients 16 0.0.0.0 5555

Set the per-client output buffer:

wcat broker --chat --broker-buffer 131072 0.0.0.0 5555

Slow clients are dropped when their output buffer cannot keep up. This keeps one slow receiver from blocking the whole broker.

Unix Socket Broker

Use a Unix domain socket for local-only broker workflows:

wcat broker --unix --chat /tmp/wcat-chat.sock
wcat connect --unix /tmp/wcat-chat.sock

Access Control

Restrict TCP broker peers with CIDR or exact IP rules:

wcat broker --allow 192.0.2.0/24 0.0.0.0 5555
wcat broker --deny 198.51.100.10 0.0.0.0 5555

Deny rules are evaluated before allow rules.

Clone this wiki locally