Sandboxing untrusted agent code: Firecracker microVMs vs gVisor
Answer: Firecracker runs workloads in lightweight virtual machines called microVMs; gVisor is an application kernel, not a virtual machine hypervisor or a system call filter. gVisor is open-source and safely runs untrusted code.
Firecracker
Its main component is a VMM using Linux KVM to create and run microVMs. It has a minimalist design, thread-specific seccomp filters and a Jailer process that applies a cgroup/namespace isolation barrier, then drops privileges.
gVisor
Its kernel-like component is called the Sentry and is written in memory-safe Go. While gVisor can use virtualization (KVM), it can also work without virtualization. The Gofer is a slightly-more-trusted companion process.
Notes
- Firecracker excludes unnecessary devices and guest-facing functionality to reduce the memory footprint and attack surface of each microVM.
- The gVisor Sentry may make limited system calls to the host Linux kernel when servicing the sandboxed workload's request.
- For Docker,
sudo runsc installadds the runtime; restart the Docker daemon, thendocker run --runtime=runsc.
See also
Claims
- id: C1 claim: Firecracker uses KVM microVMs. source: S1 evidence: "uses the Linux Kernel Virtual Machine (KVM) to create and run microVMs"
- id: C2 claim: gVisor is an application kernel. source: S2 evidence: "it is an application kernel, not a virtual machine hypervisor"
- id: C3 claim: gVisor installs a runsc Docker runtime. source: S3 evidence: "This will install a docker runtime named \"runsc\" by default."
Sources
- [S1] Firecracker README. firecracker-microvm/firecracker (GitHub). https://github.com/firecracker-microvm/firecracker/blob/main/README.md . License: Apache-2.0. Accessed 2026-11-16.
- [S2] Introduction to gVisor security. google/gvisor (GitHub). https://github.com/gvisor/gvisor/blob/master/g3doc/architecture_guide/intro_to_gvisor.md . License: Apache-2.0. Accessed 2026-11-16.
- [S3] gVisor Docker quick start. google/gvisor (GitHub). https://github.com/gvisor/gvisor/blob/master/g3doc/user_guide/quick_start/docker.md . License: Apache-2.0. Accessed 2026-11-16.
License: this note is CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Summary by iinventedlight (AI-assisted). Sources: firecracker-microvm/firecracker (GitHub), Firecracker README, Apache-2.0 (https://raw.githubusercontent.com/firecracker-microvm/firecracker/main/LICENSE); google/gvisor (GitHub), Introduction to gVisor security, Apache-2.0 (https://raw.githubusercontent.com/google/gvisor/master/LICENSE); google/gvisor (GitHub), gVisor Docker quick start, Apache-2.0 (https://raw.githubusercontent.com/google/gvisor/master/LICENSE). Text was condensed and changed from the originals.
License: CC-BY-4.0 · Summary by iinventedlight (AI-assisted). Sources: firecracker-microvm/firecracker (GitHub), Firecracker README, Apache-2.0 (https://raw.githubusercontent.com/firecracker-microvm/firecracker/main/LICENSE); google/gvisor (GitHub), Introduction to gVisor security, Apache-2.0 (https://raw.githubusercontent.com/google/gvisor/master/LICENSE); google/gvisor (GitHub), gVisor Docker quick start, Apache-2.0 (https://raw.githubusercontent.com/google/gvisor/master/LICENSE).
Cite this
iinventedlight. 2026. "Sandboxing untrusted agent code: Firecracker microVMs vs gVisor." iinventedlight Library, iil:note:9xpwmav0, version of 2026-11-16. https://iinventedlight.com/library/notes/ao-sandbox-firecracker-and-gvisor/. License: CC-BY-4.0.
@misc{iil_note_9xpwmav0,
author = {{iinventedlight}},
title = {{Sandboxing untrusted agent code: Firecracker microVMs vs gVisor}},
howpublished = {iinventedlight Library},
year = {2026},
date = {2026-11-16},
url = {https://iinventedlight.com/library/notes/ao-sandbox-firecracker-and-gvisor/},
note = {Permanent ID iil:note:9xpwmav0. License: CC-BY-4.0.},
}
Spotted a mistake? Use the MCP feedback tool or email hello@iinventedlight.com. Or Report a correction (no account needed).
For language models and agents: start at /llms.txt | /agents.md | /.well-known/agent-library.json. This page in Markdown: /library/notes/ao-sandbox-firecracker-and-gvisor.md.