What is vulnboxd?
vulnboxd is a defence kit for attack-defense CTFs. It has two halves:
- On the vulnbox, it takes care of your services: sets the box up in one go, deploys your patches at the end of each tick, filters the traffic that reaches the services, and rolls back what breaks.
- On your team's own server, the hub shows the whole team what is happening: every connection to the box, who is stealing flags, what each attack made the service do, and the buttons to answer it.
The first half works on its own in minutes. The second is optional and adds analysis on top. vulnboxd is purely defensive: it never attacks or submits flags.
On the vulnbox
Setup in one go. At the start of a game, vulnboxctl setup-interactive gives every service a git repository and a private GitHub or GitLab repository with its own deploy key, writes the capture tools' configuration, and installs vulnboxd. It is safe to run again.
It knows the game. A game mode for FAUST CTF or the ECSC brings the flag format, the tick timing and the vulnbox address, and reads the checker's verdict on each service from the gameserver.
It deploys your patches. vulnboxd polls each service's repository, builds the new version while the old one keeps serving, and swaps the containers in the last seconds of the tick. While a container restarts, the proxy holds new connections instead of refusing them, so a slow deploy is a slow request, not a failed check. See Deploys.
It filters the traffic. Every public port moves behind vulnboxd's proxy, which applies the rules in the service's vulnboxd-rules.yml: block, rewrite, stall, route or log TCP, UDP, HTTP (with h2c, gRPC and WebSockets), FTP and DNS, matched as the data streams by. Rules are edited through git and reload within a second; a bypass header lets your own exploits through. See Rules.
It undoes what breaks. A version that does not come up, or after which the checker says down, is rolled back with a pushed commit. When many commits landed since the last good version, a deploy bisect finds the bad one and reverts only that.
It tells you. Alerts go to a Discord webhook when a port stops answering, the checker says down, a deploy fails or something is rolled back. vulnboxctl top and Prometheus metrics show which rules fire.
It can capture. The capture broker serves the box's packets live over PCAP-over-IP, to the hub or to tools like Tulip.
In the hub
The hub is a web UI for the whole team, fed by an agent on the vulnbox:
- Flows: every connection reassembled and decoded (HTTP, HTTP/2, WebSockets, gRPC and Connect, the common database protocols), searchable and filterable, with deliberate obfuscation flagged.
- Attacks: flags leaving the box to anyone but the checker, as they happen.
- Host monitoring: with the host sensor, what each request made the service do (the shell it started, the file it read, the query it sent), linked exactly, never by timing.
- Alerts: the hub learns each service's normal behaviour from the checker and tells you when a request makes it do something else.
- Answers: rules drafted from an attack, previewed against the last 20 ticks and pushed to the box; exploit scripts from captured flows; shells and logs and a volume and database browser without SSH.
- Runtime hooks: for services where one process serves many requests, the hub proposes a small hook per container, which a player approves (Hook proposals).
The programs
| Program | Where | What it does | Needed? |
|---|---|---|---|
vulnboxd | vulnbox | the daemon: proxy and rules, deploys, rollback, bisect, alerts, metrics | yes |
vulnboxctl | vulnbox | setup, compose, top, rollback, bisect, upgrade | yes |
vulnboxd-pcap | vulnbox | the capture broker | for the hub or capture tools |
vulnboxd-agent | vulnbox | connects the box to the hub | for the hub |
vulnboxd-sensor | vulnbox | watches the services' processes with eBPF, read-only | for host monitoring |
vulnboxd-hub | your cluster | the hub: ingest, assembly, linking, alerts, web UI | for the hub |
| runtime hooks | in the services | tell the sensor which request did what | optional |
Each optional part runs on its own: when one is off or down, everything else carries on as before.
What it does not do
Worth knowing before you put it on a box ten minutes before a game:
- No attacking. No exploits, no flag submission. The hub's script generator writes a script from flows you captured, but running it is up to you.
- No host hardening. It does not firewall the box, manage users or patch packages. It filters the ports your services publish, and nothing else.
- No changes without you. The hub proposes hooks and drafts rules; a player approves every push. Only vulnboxd's own rollbacks act by themselves (and bisects, if you turn that on).
- GitHub- or GitLab-shaped setup.
initcreates repositories on GitHub or a GitLab. Any other remote works, but you pointoriginat it yourself. - One box. vulnboxd manages the services on the machine it runs on.
- x86_64 releases. Built for glibc on x86_64; anything else is a
cargo build --releaseaway.
Next steps
- Quick start: from a fresh box to a running vulnboxd and hub.
- How it works: what vulnboxd does to your services, and when.
- Using the hub: the hub's screens and a routine for the game.
- Glossary: the terms these pages use.