Capabilities (what the sandbox can do)
Core capabilities
- MicroVM lifecycle: create/start/stop/destroy Firecracker microVMs via the manager API.
- Command execution: run shell commands inside the VM as uid/gid 1000 (user
user). - TypeScript execution: run TypeScript via Deno (
run-ts), with restricted permissions. - Structured results:
run-tssupports returning JSON viaresult.set(...)/result.error(...)in addition to stdout/stderr. - Files API: upload/download tar.gz archives, restricted to
/workspace(symlinks/traversal rejected). - Networking controls:
- per-VM firewall allowlist (
allowIps) + optionaloutboundInternet - guest networking configured by the manager (tap/NAT on host; eth0 in guest)
- per-VM firewall allowlist (
- Snapshots (optional):
- enabled by
ENABLE_SNAPSHOTS=true - snapshot/restore flows preserve a disk baseline so
/workspacefiles (e.g. uploaded SDK) can be reused
- enabled by
Isolation properties (important)
This is not “just containers”:
- untrusted code runs inside a Firecracker microVM
execis additionally chrooted so the guest OS filesystem is not visible (use/workspacefor user operations)
What untrusted code can access
- File system: only
/workspace(both forexecand forrun-tsread/write permissions) - Network:
- controlled by allowlist +
outboundInternetpolicy run-tscan requestallowNet, but it is still subject to the firewall policy applied by the manager/agent
- controlled by allowlist +
Output limits
The guest agent caps stdout/stderr buffering (to avoid memory blowups) and supports timeouts per request.