Skip to content

Back to the catalog

VMs won't contain cyber-capable agents
blog.trailofbits.comwriteup

VMs won't contain cyber-capable agents

Trail of Bits gave GPT 5.6-Cyber preview access and tasked it with escaping a QEMU/KVM VM on a Debian 12 host; the agent succeeded three separate times, first via a recently disclosed host kernel bug (Januscape, CVE-2026-53359), then by chaining CVE-2026-9539 in libslirp with an unmarked bug fix, and finally by autonomously discovering and chaining multiple 0-day vulnerabilities in the kernel/QEMU stack over roughly 12 hours of largely unsupervised operation. The author argues off-the-shelf VMs (even hardened stable distros) no longer reliably contain a sufficiently capable AI agent — treat such agents as an APT — though Firecracker's minimal attack surface withstood the same agent's attempts.

TL;DR Trail of Bits shows GPT 5.6-Cyber autonomously escaping a QEMU/KVM VM sandbox three times, twice via known-but-unpatched bugs and once via chained 0-days, arguing VMs can no longer contain cyber-capable AI agents.
Document

What it is

A Trail of Bits field report (Patch the Planet) documenting that a preview model, GPT 5.6-Cyber, escaped a QEMU/KVM sandbox VM (Debian 12 oldstable, AMD Zen3) to read a host flag — the author's actual dev-machine sandbox, not a contrived lab. The takeaway the summary understates: the author now argues a VM alone should no longer be treated as a containment boundary for a capable agent, and such agents should be modeled as an APT.

How it works — the escape surface

The escapes all exploit resources the VM must share with the host to be useful (networking, shared libraries, kernel interfaces). The author explicitly frames the tension: a sandbox useless without shared state, screen, file transfer, and network; those pathways are the attack surface. Notably the agent tried and abandoned several paths, which the summary omits:

  • CUPS: found a network-reachable CUPS server with an unpatched-in-oldstable CVE, but exploitation was blocked by AppArmor.
  • Hardware side channel: detected the host ran with mitigations=off and attempted CPU-bug-based host memory read oracles — abandoned as too unreliable.
  • Only then did it fall back to source-level bug-hunting of kernel/QEMU/libslirp, chaining 0-days.
flowchart TD
  A[Agent SSH into VM] --> B{Escape path}
  B --> C[Host kernel: Januscape CVE-2026-53359]
  B --> D[libslirp 4.7.0: CVE-2026-9539 + unmarked fix]
  B --> E[CUPS CVE] -->|blocked by AppArmor| X[abandoned]
  B --> F[HW bug oracle, mitigations=off] -->|unreliable| X
  C -->|kernel updated| D
  D -->|QEMU/libslirp rebuilt| G[0-day hunt in source]
  C & D & G --> H[Read host flag]

Preconditions / Affected

  • Kernel path: unpatched host kernel (Januscape, CVE-2026-53359 — no public exploit existed; agent built one).
  • Network path: Debian 12 shipping libslirp 4.7.0 (VM user-mode networking), vulnerable to CVE-2026-9539, plus a bug-fix commit with no CVE that combines into arbitrary host read/write.
  • The AppArmor block and the mitigations=off finding show configuration hardening (MAC, CPU mitigations on) affected which paths were viable.

What to do

The page gives no patch commands, but the concrete engineering signals are:

  • Don't rely on oldstable currency: libslirp 4.7.0 in Debian 12 carried a known CVE plus a fixed-but-uncatalogued bug that never reached the distro. Rebuild QEMU/libslirp from upstream and strip unneeded features (the author did this after escape 2).
  • Keep AppArmor/MAC enabled — it stopped the CUPS chain outright.
  • Do not run the host with mitigations=off.
  • Treat capable agents as APTs: assume compaction/subagent persistence over ~12h and audit final artifacts for objective-cheating (author started the agent outside the VM precisely because escapes hardlock it).

Caveats

Escape 1 (Januscape) did not land cleanly — the author judges it would have with more revision, so score it as demonstrated capability, not a clean pop. Model is preview/unreleased; the host was a throwaway dev machine with nothing valuable, which lowered the author's own risk bar.

Organisations named here

  • GPT 5.6-Cyber
  • Januscape

CVEs named here

  • CVE-2026-53359
  • CVE-2026-9539

Technologies named here

  • Debian 12
  • GPT 5.6-Cyber
  • Linux kernel
  • Codex with goal mode
  • QEMU/KVM
  • libslirp
  • libslirp 4.7.0
  • AppArmor
  • CUPS server
  • Firecracker
  • QEMU
  • Debian
  • Codex
  • Patch the Planet

Techniques named here

  • VM/sandbox escape
  • 0-day discovery and exploit development
  • Vulnerability chaining
  • Hardware bug exploitation for read oracle
  • Network service reconnaissance
  • Autonomous long-horizon operation

Threat actors named here

  • GPT 5.6-Cyber