Isolation
MicroVM vs container: where gVisor puts the boundary
MicroVM vs container for untrusted agent code: compare shared kernels, gVisor's application kernel and KVM guests, then choose the boundary your workload needs.
Run mutually untrusted agent tenants in separate sandboxes, using gVisor when its application-kernel boundary fits or microVMs when each tenant needs its own Linux kernel. For microVM vs container choices, review credentials, mounts and network access separately from compute isolation.
Follow one system call#
Consider a package install script opening a file. In a native container, the host kernel handles that syscall; gVisor implements it in the Sentry; a microVM handles it in the guest kernel. Virtual-device I/O is a separate interaction below that guest kernel.
Docker Engine uses namespaces to separate views of processes and networks, and cgroups to account for and limit resources. Capabilities and seccomp narrow what the process can do. Those controls still depend on the host kernel enforcing them correctly.
gVisor redirects application syscalls to its Sentry. The Sentry implements the Linux-like interface and uses a restricted set of host operations underneath. It does not forward the application's syscall arguments directly. This adds an independent implementation between untrusted code and the host, rather than just another filter.
Firecracker and Cloud Hypervisor are VM monitors, not container runtimes. A guest-kernel compromise must still cross the virtualization boundary to compromise the host.
Compare the tradeoffs#
| Design | Boundary around the workload | Cost to evaluate | Good fit |
|---|---|---|---|
| Native Linux container | Host-kernel namespaces, capabilities and syscall policy | Shared-kernel exposure; configuration and daemon access | Trusted builds with familiar container tooling |
| gVisor | Per-sandbox Sentry implements the application kernel | Unsupported Linux interfaces; syscall-heavy workloads can cost more | Untrusted code that fits its Linux compatibility surface |
| KVM microVM | Separate guest kernel behind virtual hardware | Guest memory, device model and VM lifecycle | Untrusted tenants needing their own Linux kernel |
The gVisor security model warns that virtualization hardware alone does not guarantee a smaller attack surface. Device emulation, host support code, patching and configuration matter. gVisor and microVMs both reduce direct host exposure; neither removes every escape path or hardware side channel.
Review network permissions#
A VM does not stop an agent reading files you mounted into it or sending data to an API you authorized. Review outbound networking separately. Platinum's networking docs warn that its per-sandbox egress policy is not a hard security boundary against source-IP spoofing. Do not treat an allowlist as equivalent to isolating hostile tenants.
Choose for the workload#
Do not use a shared host kernel as your sole boundary for mutually untrusted tenants. A microVM is not the only alternative: gVisor’s runsc works with OCI container tooling without a separate guest kernel. Test package installs, browsers and syscall-heavy tasks against its compatibility surface. Keep the Docker daemon out of untrusted workloads’ control.
Platinum and Vercel Sandbox offer managed KVM-based isolation: Platinum runs one isolated microVM per sandbox using Cloud Hypervisor on KVM; Vercel uses Firecracker, which uses KVM. Vercel documents a separate Firecracker microVM, filesystem and network per sandbox. These services avoid operating the VM fleet yourself.
Sources, checked November 2026: Docker Engine security, gVisor architecture and security model, Firecracker, Cloud Hypervisor, Vercel Sandbox, and the linked Platinum docs.