Contents
  1. The execution contract and its trusted components
  2. Process, container and virtual machine boundaries
  3. Operating-system controls and inherited access
  4. Capabilities, credentials and mediated operations
  5. Workspace paths and underlying storage
  6. Network reachability and service authority
  7. Resource budgets and limit outcomes
  8. Environment creation and execution readiness
  9. Termination, cleanup and environment reuse
  10. Artifact export and retained copies
  11. Snapshots, rollback and external effects
  12. Boundary failures and remaining containment
  13. Boundary evidence and workload-based selection
  14. Check understanding
  15. Open questions
  16. Selected talks
  17. References
  18. Talk library
← All topics

Sandboxes and Execution Isolation

A sandbox lets untrusted code perform useful work under enforced restrictions. Its safety depends on more than the execution technology: mounted storage, credentials, network paths, resource limits and retained outputs determine what the code can affect. Recoverability depends on which changes stay inside the environment and which reach systems that disposal or restoration cannot undo.

The execution contract and its trusted components

A sandbox is a controlled execution environment that restricts an application's permissions and access to resources. Generated code needs the same treatment as other untrusted code. The restriction must exist in the execution system; an instruction asking the program to avoid sensitive files does not prevent access.

A trust boundary separates different assumptions about control or authority. The trusted computing base comprises the hardware, firmware and software relied upon to enforce policy. For execution, that can include the kernel, runtime, management service and credential gateway. The protected assets determine which components belong in this set; AI Security explains the surrounding threat model.

A repository-build service provides a useful execution contract: receive one tenant's source, install dependencies, run tests and return selected changes for review. The harness—the runtime requesting and coordinating execution—needs observable results from this environment. Scheduling and continuation belong to Harness Engineering; executing code and incorporating its changes remain separate operations.

An execution contract specifies both permission and evidence.
Contract dimensionRequired specification
Assets and operationsName protected resources, permitted accesses and the enforcer for each crossing.
ConsumptionSpecify resource budgets, their scope and the response when a limit is reached.
Surviving stateIdentify disposable work, retained outputs and independently persistent effects.

Isolation limits where execution can act. Authorization determines whether a particular action on a particular resource is permitted. An allowed connection to a repository service therefore does not itself authorize a push. The control-placement distinction keeps execution restrictions from being mistaken for business approval.

Process, container and virtual machine boundaries

A process is a running program with an address space: the memory addresses it can use. Separate address spaces do not eliminate inherited access. On Linux, fork creates a child with initially copied memory and inherited file descriptors—handles referring to already-open resources. Parent and child can consequently retain access to the same underlying files.

The kernel is the operating-system component that mediates hardware and privileged operations. A container groups processes under operating-system isolation controls while sharing a kernel. A virtual machine runs a guest operating system, including its own kernel, behind a virtualization layer. Its virtual machine monitor, or VMM, manages guest execution and virtual devices.

Different paths to host services

Isolation changes the interfaces exposed to workload requests.

The VM branch depicts device servicing, not every instruction. All three designs retain host dependencies and separately granted resources.
Read the diagram as text
  • Container code.
  • gVisor workload.
  • Sentry.
  • Guest application.
  • Guest kernel.
  • VMM device handling.
  • Host kernel.
  • Container codeHost kernel: System calls.
  • gVisor workloadSentry: System calls.
  • SentryHost kernel: Restricted host interface.
  • Guest applicationGuest kernel: System calls.
  • Guest kernelVMM device handling: Device servicing boundary.
  • VMM device handlingHost kernel: Host operations.
The execution choice changes exposed interfaces and compatibility requirements.
ChoiceBoundary and remaining dependencyWorkload implication
Ordinary containerScoped resource views; application system calls still reach the shared host kernel.Broad Linux compatibility, with host-kernel exposure to assess.
gVisorIts Sentry implements application system calls and uses a restricted host interface; mapped files and allowed connections remain accessible.Check application compatibility and the actual filesystem/network configuration.
MicroVMA guest kernel and a reduced VMM device surface; host infrastructure still supplies resources.Check guest images, device support and host/guest maintenance obligations.
Language isolateA constrained language execution context exposing selected interfaces.Useful for functions; package installation, subprocesses and application servers require a compatible richer environment.

A VM exit transfers guest execution to host-side handling. Device-heavy workloads can incur repeated servicing costs; CPU work and cached guest operations follow different paths. These differences require workload measurements, not a universal overhead percentage.

Startup optimization also extends beyond the isolation runtime. Modal's 2025 architecture account pairs gVisor with custom scheduling and storage infrastructure. This illustrates why selecting a runtime does not settle image distribution, readiness or fleet behavior.

Operating-system controls and inherited access

A system call is a program's request for a kernel operation. Confinement combines controls over visibility, access, privilege and consumption. These properties are independent: hiding another process from a process listing does not establish that every route to its resources has been denied.

ControlEnforced propertyImportant exclusion
NamespacesSeparate views of resources such as process IDs, mounts and network stacks.A restricted view is not a resource-specific permission policy.
Identity-based permissionsKernel access checks use the requesting identity and applicable permissions.Privileged powers can bypass particular checks.
Linux capabilitiesDivide traditionally root-only powers into separately enabled privileges.Removing one power leaves ordinary permissions and other grants intact.
seccompFilters system-call numbers, argument values and metadata.Cannot dereference a pointer to inspect pathname contents.
LandlockAdds kernel-enforced restrictions on permitted resource operations.Supported rights vary by kernel interface version; previously opened files need separate handling.
Resource accounting and limitsMeasure or constrain consumption by grouped processes.Do not themselves determine which business data a process may read.

seccomp reduces exposed kernel interfaces; it is not a complete filesystem policy. Landlock supplies additional mandatory kernel restrictions that constrained code cannot simply waive. Inspect both supported rights and inherited handles before relying on the resulting policy.

Changing the apparent filesystem root with chroot does not close descriptors or change the current working directory. An already-open resource outside that tree can remain reachable. Path presentation and actual authority must therefore be checked separately.

Rootless Docker runs both its daemon—the management service—and containers without host root privileges. User-namespace remapping differs: its daemon retains root privileges. Rootless operation reduces those privileges, but mounts, networking, ordinary host permissions and kernel interfaces still need an explicit contract.

A host Docker socket is a management interface, not an ordinary workspace file. Access to a privileged daemon can permit requests to mount host storage into another container. Restricting the original container's visible paths does not remove authority granted through that socket.

Capabilities, credentials and mediated operations

An object capability is an unforgeable reference that identifies a resource and conveys authority to use it. Naming a resource is insufficient: a caller-supplied pathname does not grant permission to write there. The Confused Deputy explains how a service can accidentally apply its own stronger authority to a caller's request.

Linux capabilities use the same word for a different mechanism: dividing operating-system privileges. Ambient authority means broadly available access, such as access inherited from an execution identity, rather than a narrowly supplied resource reference. Minimizing it makes the workload's usable powers easier to identify.

Keep credentials behind checked operations

Example

Withholding a token still leaves broker authority to constrain.

Proposed broker contract: trusted identity, resource, operation and validity must match. Direct credential delivery instead gives workload code the credential.
Read the diagram as text
  • Workload.
  • Trusted execution identity.
  • Broker grant checks.
  • Broker-held credential.
  • Authorized service operation.
  • Rejected request.
  • WorkloadBroker grant checks: Data: requested operation.
  • Trusted execution identityBroker grant checks: Control: authenticated context.
  • Broker-held credentialBroker grant checks: Secret: retained outside workload.
  • Broker grant checksAuthorized service operation: All checks pass: attach credential.
  • Broker grant checksRejected request: Any check fails.

A credential broker is a trusted service that performs authenticated operations for a workload. A useful proposed grant binds trusted execution identity, target resource, permitted operation and validity period. Identity must come from trusted context, not a generated argument. The broker implements grants; AI Security's execution-authority discussion owns the underlying business policy.

Cloudflare's Dynamic Workers gateway demonstrates secret withholding: trusted loader code can attach credentials to selected outgoing requests. Its outbound restriction does not disable separately supplied bindings. Every binding therefore remains an independent grant to inspect.

Direct credential delivery exposes the credential to the receiving process. For example, the MCP TypeScript subprocess client filters its default environment, but explicitly supplied environment entries reach the launched server. Filtering defaults cannot protect a secret deliberately passed to untrusted execution.

Credential lifetime has several distinct events.
EventMeaning
Lease expiryThe recorded validity or renewal period ends. A lease is lifecycle metadata, not necessarily intrinsic expiry at the external service.
Revocation requestThe issuer attempts to withdraw authority. This may require contacting another system.
Confirmed invalidationThe relevant service no longer accepts the credential. Vault's database-unavailability example shows why expiry alone cannot establish this.

Credential copies also need lifecycle controls. Environment data can reach child processes; snapshots can retain tokens; logs can preserve secrets after execution ends. Avoid placing broad credentials in workload memory, and exclude tokens from routine diagnostic records.

Workspace paths and underlying storage

A mount makes storage visible at a filesystem path. A bind mount exposes existing host storage rather than copying it. Writes through a writable bind mount change that underlying storage.

OverlayFS combines lower and upper layers into one view. A write requiring modification of a lower-layer file copies it into the upper layer; the upper copy then takes precedence. This copy-on-write behavior separates shared base files from private changes.

Writes follow underlying storage

Example

A private write layer and a live host mount have different owners.

Private-layer disposal leaves the base unchanged; it cannot reverse writes through a separately granted host mount.
Read the diagram as text
  • Read-only base.
  • Workload.
  • Private upper layer.
  • Live host storage.
  • Read-only baseWorkload: Read.
  • Read-only basePrivate upper layer: Copy-up when required.
  • WorkloadPrivate upper layer: Workspace writes.
  • WorkloadLive host storage: Writable bind-mount grant.
A build workspace should make each storage relationship explicit.
Workspace componentMutation and retention rule
Read-only baseCommon tools are readable; changes belong in private writable state.
Copied task inputsThe execution edits its own copy, separated from other tenants' working files.
Private scratch and candidate outputsKeep intermediate work separate from files explicitly selected for retention.
Live host mountChanges affect host storage; read-only access is not a snapshot.

A symbolic link redirects pathname resolution; path traversal uses names such as parent-directory components to reach outside an intended tree. Trusted readers must constrain resolution, not merely check a string prefix. Linux openat2 can require containment beneath a directory and reject symlinks or mount crossings. These checks protect individual opens, not every later processing step.

Device files and management sockets expose operations beyond ordinary file contents. Existing descriptors can preserve access even after a path becomes invisible. The workspace specification must enumerate these grants alongside data paths; access governance determines which data access the environment should permit.

Network reachability and service authority

Egress is outbound communication; ingress is incoming communication. A network namespace supplies a separate view of network devices and stacks. Connection filters decide which address-and-port connections may occur. An application proxy receives requests on behalf of another program and can apply checks to their application-level contents.

Deny outbound communication unless the task requires it, then mediate the necessary paths. Identity-aware connections can help a destination identify the calling workload, as the Tailscale talk proposes. The receiving service must still decide which resource and operation that identity may use.

Cloud metadata endpoints expose instance information and potentially service credentials through special network paths. EC2 documents IPv4 and conditionally available IPv6 access, plus token-based IMDSv2 requests. Blocking public Internet access does not establish that these local paths are blocked. Token requirements alone do not exclude arbitrary code that can reach the endpoint.

DNS resolution translates hostnames into addresses; redirects instruct a client to contact another destination. Either can change where a validated request ultimately goes. SSRF prevention guidance therefore addresses destination membership, resolved addresses and redirects together. Server-side request forgery means inducing a service to contact an unintended destination using its own reachability or authority.

A reported repository-fetching exploit illustrates the consequence: changing a repository destination caused a tool to send its Git credentials elsewhere. The failure was in destination and credential handling; it did not require escaping the execution environment.

Network-policy declarations require effective enforcement. Kubernetes NetworkPolicy needs a supporting plugin; ingress and egress are independent, applicable allow rules combine, and policy distribution can lag creation. Changes to established connections are implementation-dependent. Readiness must establish the required restrictions before untrusted work starts, rather than merely confirm that a policy object exists.

Preview servers need separate inbound authentication and tenant routing. Arrakis's port-forwarding example explains connectivity into a guest, not permission to use the exposed service.

An allowed destination can still receive private data. Filesystem and network restrictions must therefore be assessed together, including every granted service interface. Disclosure paths explains how private-data access, attacker-controlled content and external communication can combine.

Resource budgets and limit outcomes

A control group, or cgroup, groups Linux processes for hierarchical resource accounting and enforcement. New children inherit membership, but moving a parent later does not move its existing descendants. Establish the execution group before setup begins, and verify that required controllers are enabled.

A limit's unit, scope and failure behavior are part of its meaning.
BudgetScope and mechanismLimit outcome
CPU rateGroup CPU time per period; cpu.max.Throttles execution.
Accumulated CPU timePer-process CPU seconds; RLIMIT_CPU.Soft limit signals; hard limit kills.
Elapsed runtimeService-manager active runtime deadline.Manager initiates termination under its configured rules.
Group memorymemory.high and memory.max.Pressure/reclaim; possible out-of-memory killing at the ceiling.
Virtual address spacePer-process addressable space; RLIMIT_AS.Memory operations can fail; this is not resident-memory usage.
Process countGroup pids.max.Rejects further process creation.
Device I/O rateThroughput or operations per second; io.max.Limits rate, not stored bytes.
Workspace allocationFilesystem block and inode quotas.Hard limits reject excess allocation; soft limits allow a grace period.
Individual file sizePer-file growth; RLIMIT_FSIZE.Signals or failed writes; does not cap total workspace size.

Resident memory occupies physical memory; virtual address space describes addresses a process can map. An inode represents a filesystem object, so many tiny files can exhaust object capacity before byte capacity. A quota must apply to the execution's intended user, group or project identity on a supporting filesystem.

Sleeping or waiting for a service consumes elapsed time without equivalent CPU consumption. An external deadline therefore serves a different purpose from CPU limits. For example, systemd separates startup, active-runtime and stopping timeouts; unit types and permitted deadline extensions affect whether a configured duration is truly a hard bound.

Output bytes, network volume and remote-operation spending require separate enforcement contracts. A local CPU ceiling cannot cap charges from permitted API calls. Specify the measuring component, concurrent-request accounting and overflow response before claiming a bound; retries can multiply downstream work even after the original caller stops waiting.

Per-execution ceilings also differ from service capacity. Admission control decides whether another execution may begin; supervision and cleanup require capacity of their own. Resource abuse supplies this availability context. Resource configurations affect task outcomes, so guaranteed allocations, hard limits and time budgets belong in execution records.

Environment creation and execution readiness

An image packages executable software, filesystem contents and configuration for environment creation. An image digest identifies content, whereas a tag can be reassigned. Recording a requested tag does not establish which image actually ran.

Dependency preparation is execution. npm's version 8 documentation describes installation lifecycle scripts and Git dependencies whose prepare scripts run before packaging. This versioned example establishes the ordering requirement: confinement must precede enabled hooks, not begin only when the advertised application command starts.

Confinement precedes untrusted setup

Example

A running environment is not necessarily ready for untrusted work.

Proposed creation contract: establish controls before admitting setup; failed establishment or readiness prevents workload admission.
Read the diagram as text
  • Select base and execution identity.
  • Prepare storage and controls.
  • Verify effective restrictions.
  • Run confined dependency setup.
  • Admit workload.
  • No workload admission.
  • Select base and execution identityPrepare storage and controls: Trusted preparation.
  • Prepare storage and controlsVerify effective restrictions: Check establishment.
  • Verify effective restrictionsRun confined dependency setup: Restrictions effective.
  • Verify effective restrictionsNo workload admission: Missing or failed control.
  • Run confined dependency setupAdmit workload: Setup and readiness pass.
  • Run confined dependency setupNo workload admission: Setup or readiness fails.

The creation gate should establish execution identity, private storage, effective access restrictions and budgets before admitting setup. Missing enforcement is a no-execution outcome. Readiness then includes the required tools and policy checks, not simply a running process. This is a proposed integration contract whose components must be verified together.

Image reuse, dependency caching and memory snapshots preserve different state. A memory snapshot can duplicate machine identifiers, randomness and cryptographic tokens. Repeated restoration therefore needs an explicit uniqueness mechanism. Giving a clone a new external name does not by itself refresh the state inside it.

Initialization captured before tenant inputs arrive avoids capturing those inputs. A later snapshot can retain tenant data in both memory and storage. Identity refresh addresses duplicated identity; it does not erase arbitrary retained contents. A clean base and fresh private writable state provide a clearer starting contract than undocumented reuse.

Record the actual image, runtime, policy, grants, limits, dependency inputs and cache conditions. Reproducing these conditions reduces environmental variation but does not freeze remote repositories or guarantee deterministic program behavior. Execution provenance explains how to retain this context without indiscriminate data capture.

Termination, cleanup and environment reuse

A caller timeout means the caller stopped waiting. A cancellation request asks execution to stop. Neither establishes observed termination. Temporal's activity documentation illustrates the distinction: cancellation is cooperative, and a timed-out attempt can continue. The execution service needs independent evidence about the actual unit it controls.

Stopping only the main process can leave descendants active. Whole-unit stopping must target the execution's group. Linux cgroup.kill targets a subtree, including concurrent forks; cgroup.events can report whether live processes remain. Process absence still says nothing about retained storage or credentials.

Stopped can still mean unclean

Example

Confirmed termination does not establish completed cleanup.

1 / 5 · Running

E owns active execution.

Proposed failure path. Earlier states remain visible as history; the newly added state is current.
Read the diagram as text
  • Environment E.
  • Running.
  • Stop requested.
  • Termination confirmed.
  • Cleanup unresolved.
  • Quarantined.
  • Environment ERunning: Initial state.
  • RunningStop requested: Stop initiated.
  • Stop requestedTermination confirmed: Whole-unit absence observed.
  • Termination confirmedCleanup unresolved: Cleanup incomplete.
  • Cleanup unresolvedQuarantined: Reassignment denied.
  1. Running. E owns active execution. Active: Environment E, Running. New: Environment E, Running.
  2. Request. A stop request is not completion. Active: Environment E, Running, Stop requested. New: Stop requested.
  3. Confirm. The execution unit is now absent. Active: Environment E, Running, Stop requested, Termination confirmed. New: Termination confirmed.
  4. Inspect. Retained-resource cleanup remains unresolved. Active: Environment E, Running, Stop requested, Termination confirmed, Cleanup unresolved. New: Cleanup unresolved.
  5. Hold. E remains unavailable to another tenant. Active: Environment E, Running, Stop requested, Termination confirmed, Cleanup unresolved, Quarantined. New: Quarantined.

An execution lease is a proposed time-bounded permission to remain active. Its enforcer must survive loss of the requesting controller. Manager timeouts are one building block, not evidence of complete orphan discovery, storage cleanup or authoritative status reporting. Those failure paths require an implementation and tests.

Cleanup also releases references and retained resources. A namespace can survive its last process through an open descriptor or mount reference. Network-policy changes may leave established connections intact. Destruction therefore needs checks appropriate to storage, references, connectivity and authority, beyond a process exit code.

Use finally-style cleanup for ordinary completion and exceptions, plus maximum lifetimes for abandonment. Neither can establish cleanup after every controller failure. Return exit reason, termination evidence and cleanup outcome separately; an unresolved cleanup state must remain unavailable for reassignment.

Pooling trades repeated initialization for a reset obligation. Before reassignment, establish that processes, memory, writable storage, credentials, connections and caches cannot expose prior-tenant state. A successful task is not reset evidence. When reset is unverified, creation from the recorded clean baseline is the defensible alternative; continuation policy remains in Harness Engineering.

Artifact export and retained copies

Artifacts are retained outputs: files, patches, reports and logs. A proposed export manifest names selected relative paths, their execution origin, size/count limits and intended use. Selection separates useful results from disposable workspace contents; recording origin does not validate those results.

Trusted exporters must resolve paths under an approved directory. openat2 can reject symlinks throughout a path and prevent mount crossings; O_NOFOLLOW only addresses the final component. These constraints do not validate contents or secure a later multi-step export against every race.

Export is another trust boundary

Example

Accepted extraction does not establish safe downstream use.

Proposed export path. Reject invalid selections and isolate partial output; retained artifacts still need checks appropriate to parsing, rendering or execution.
Read the diagram as text
  • Selected workspace files.
  • Trusted exporter.
  • Path, type and resource checks.
  • Retained artifact.
  • Rejected or partial output.
  • Downstream-use checks.
  • Selected workspace filesTrusted exporter: Selected data.
  • Trusted exporterPath, type and resource checks: Controlled reading/extraction.
  • Path, type and resource checksRetained artifact: Export checks pass.
  • Path, type and resource checksRejected or partial output: Check or extraction fails.
  • Retained artifactDownstream-use checks: Still-untrusted content.

Archive extraction adds link, special-file and resource risks. Use fresh destinations, reject unnecessary links, limit sizes and counts, and handle concurrent modification. Extraction filters are partial defenses; failed extraction can leave partial output.

Program-reported success, process exit status, accepted export and verified correctness are different observations. A patch can export successfully and still fail tests. Verification in a separate environment receives only transferred artifacts; verification inside the workload environment may inherit modified tools and state.

Parsing, rendering or executing an exported artifact opens another exposure. PatchPilot illustrates a useful authority split: the agent edits local files, while a deterministic controller handles repository writes and review handoff. Basic file checks support that split but do not establish code safety.

Logs are outputs too. Exclude access tokens and other unnecessary secrets, sanitize untrusted event fields, restrict readers and define disposal. Exported files, snapshots, caches and telemetry can outlive the workspace. Lifecycle fulfillment across derivatives explains why deletion at one location does not establish deletion everywhere.

Snapshots, rollback and external effects

A checkpoint is a saved recovery point; a snapshot captures specified environment state. Disk checkpoints can preserve installed packages and files for restoration on another node. Incremental snapshots retain changes between checkpoints, reducing repeated copying while making restoration depend on the saved lineage.

Running-state recovery needs more than files. Arrakis describes pausing the guest while capturing memory and writable filesystem state, then resuming. That coordinated capture has broader scope than disk persistence alone.

Local restoration leaves remote state

Example

Restoring disk state cannot resolve a missing remote acknowledgment.

1 / 4 · Save

C captures S's disk before changes.

Disk-only example. S and R retain identity; prior states remain historical. The service update persists after S restores checkpoint C.
Read the diagram as text
  • Sandbox S.
  • Service record R.
  • Disk checkpoint C.
  • Local edit.
  • Remote update committed.
  • Acknowledgment missing.
  • Local disk restored.
  • Remote reconciliation pending.
  • Sandbox SDisk checkpoint C: Capture disk.
  • Sandbox SLocal edit: Local write.
  • Service record RRemote update committed: Service commits.
  • Remote update committedAcknowledgment missing: Response lost.
  • Disk checkpoint CLocal disk restored: Restore S.
  • Acknowledgment missingRemote reconciliation pending: Outcome unconfirmed.
  1. Save. C captures S's disk before changes. Active: Sandbox S, Service record R, Disk checkpoint C. New: Sandbox S, Service record R, Disk checkpoint C.
  2. Change. Local editing and remote mutation both occur. Active: Sandbox S, Service record R, Disk checkpoint C, Local edit, Remote update committed. New: Local edit, Remote update committed.
  3. Lose response. The caller lacks confirmation of R's update. Active: Sandbox S, Service record R, Disk checkpoint C, Local edit, Remote update committed, Acknowledgment missing. New: Acknowledgment missing.
  4. Restore locally. S returns to C; R still needs reconciliation. Active: Sandbox S, Service record R, Disk checkpoint C, Local edit, Remote update committed, Acknowledgment missing, Local disk restored, Remote reconciliation pending. New: Local disk restored, Remote reconciliation pending.
Recovery follows the location and capture scope of each effect.
State or effectWhat recovery can change
Private workspace editsDiscard private state or restore a captured filesystem version.
Running guest stateRestore captured memory and machine state with the required backing resources.
Host bind-mount writesRecover the affected host storage separately.
Exported patchControl its separate retained copy and any subsequent incorporation.
Remote record updateInspect the receiving service; local rollback cannot establish its outcome.

An uncertain outcome occurs when an operation may have completed without confirmed acknowledgment. A remote record can change before the response disappears. Restoring local state neither reverses that change nor supplies the missing observation. Retain the operation identity and reconcile—compare local expectations with authoritative service state—before deciding what further action is needed.

An idempotent retry repeats one logical operation without duplicating its intended effect, when the receiving service enforces that contract. A caller-generated key in a local log is insufficient. A compensating action is a separately authorized corrective operation, not restoration of a sandbox snapshot. Uncertain effects and safe retries develops the recovery mechanics.

Boundary failures and remaining containment

An escape crosses an intended isolation boundary through a failure in implementation or enforcement. A crash inside the boundary does not establish escape: the relevant evidence is an effect outside the protected region. The V8 discussion illustrates this distinction without supplying a container-escape mechanism.

Different causal paths require different repairs.
Failure classExample pathRelevant repair
Implementation escapeA flaw lets code cross an intended runtime boundary.Repair and reduce exposed interfaces; reassess the compromised boundary.
Excessive grantA privileged Docker daemon accepts a request exposing host storage.Remove or narrow management authority; no exploit is required.
Harm within granted authorityCode reaches an allowed API and performs an unwanted operation.Constrain service authority and permitted data flows.

The attack surface is the set of interfaces an attacker can influence. Memory-safe VMM code and narrowly jailed device backends can reduce exposure. Operators still need to maintain the monitor and guest and host kernels.

Blast radius describes the resources and effects reachable after compromise. PatchPilot's production account identifies host Docker access as a dangerous grant despite surrounding sandboxing. Separating repository-write credentials into trusted orchestration limits direct agent actions, while leaving generated changes subject to downstream review.

Remaining controls help only while their enforcers remain trustworthy. A host supervisor can stop a compromised workload; a supervisor controlled by a compromised host cannot independently establish host safety. Linux process-memory access rules illustrate that the host kernel controls inspection permissions. Sandbox placement does not establish confidentiality against compromise of that same kernel.

Residual risk is the exposure remaining after controls. Shared-hardware side channels—information leakage through shared resource behavior—are one concern beyond ordinary access checks. gVisor explicitly leaves hardware side-channel defenses to the host and platform. Stronger execution boundaries therefore need stated assumptions rather than claims of immunity.

Stopping computation, cutting connectivity and invalidating credentials address different future effects. None recalls data already disclosed or proves that restoration is safe. Containment and verified restoration owns incident coordination and the evidence needed before resuming ordinary operation.

Boundary evidence and workload-based selection

Compare execution designs using the same repository, required tools, access contract and retained output. Keep environment failures distinct from patch failures. SWE-bench's evaluation reports distinguish unresolved tasks from missing results and ambiguous infrastructure-versus-patch failures; a missing result is not evidence that a patch was tested and failed.

A proposed verification plan joins each claim to an observable outcome.
Claim to testIndependent observation
Forbidden files and destinations are inaccessibleInspect protected host/service state as well as denial responses.
Granted authority stays within scopeCheck the actual target and operation against the intended resource boundary.
Setup and descendants remain boundedExercise setup hooks, exhaustion and child-process survival; record enforcement outcomes.
Outputs cross safelyExercise traversal, links, concurrent changes, oversized archives and partial extraction.
Trials start from the intended stateInspect the recorded baseline and residue between executions.
Controller loss is containedInject requester failure; independently observe termination and unresolved cleanup.

Use a separate, narrowly privileged verifier where independent observation is required. It should read authoritative evidence without gaining mutation or permission-granting powers. A passing check supports its tested property and configuration; unavailable observations remain unavailable. Controlled offline comparisons explains how to keep comparison conditions interpretable.

A cold start creates an environment without a running instance to reuse. Warm reuse retains initialized state. Tail latency describes the slower portion of a latency distribution; noisy-neighbor interference is delay or failure caused by competing workloads. Measure readiness, execution, memory use, interference, teardown and cleanup failures under stated concurrency and resource conditions.

Guest boot and useful task readiness are different endpoints. Firecracker's historical evaluation measured startup to guest init under specified minimal configurations; it did not include application dependency installation. Preserve measurement boundaries and distributions before comparing those numbers with an interactive build service.

Startup techniques remove different work. Content-addressed storage deduplicates image blobs; lazy loading avoids unused reads but can leave sequential access delays. Prefetching anticipates reads from earlier runs. Memory restoration can bypass repeated initialization. Modal's account demonstrates these complementary mechanisms without establishing a universal speed ranking.

Selection requires compatible functionality, demonstrated enforcement and acceptable lifecycle costs together. Extra resource headroom can prevent infrastructure failures, but can also enable different solution strategies. Record both guarantees and hard limits, and retain the execution provenance needed to explain the result.

Open questions

  1. Verified reuse remains difficult because useful initialization and tenant state can occupy the same memory or storage. Progress requires reset tests that detect retained data and duplicated authority across failure paths, not merely successful startup under a new environment name.

  2. Revocation needs observable completion when external services are unavailable. The unresolved design problem is bounding continued credential use while invalidation is delayed; progress would include outage tests and an explicit maximum exposure period backed by service behavior.

  3. Execution budgets remain fragmented across local resources and remote operations. Concurrent calls and retries make a single hard spending bound difficult. Progress would demonstrate shared accounting, defined overflow behavior and bounded in-flight exposure during failures.

  4. Startup optimization needs comparisons that include setup and retained-state constraints. Lazy reads and restored initialization move costs to different phases. Progress would report matched readiness and cleanup distributions for clean creation and pre-tenant snapshots, including changing dependency access patterns.

Follow the curated reading path through the speakers and demonstrations behind this entry.

Explore more talks

The rest of the library, beyond the curated path. Cited talks support this entry; reviewed transcripts were processed in full. Metadata candidates have not been reviewed as sources or verified as topic members.

8 matching talks

TalkSpeakerEventYear
Abhishek BhardwajAI Engineer World's Fair 20252025
Fouad MatinAI Engineer World's Fair 20252025
Lovina DmelloAI Engineer World's Fair 20262026
Rene BrandelAI Engineer World's Fair 20252025
Daniel ChalefAI Engineer World's Fair 20262026
Jonathan MortensenAI Engineer World's Fair 20252025
Vinoth GovindarajanAI Engineer World's Fair 20262026
David BrumleyAI Engineer World's Fair 20262026

References

Coverage and source review
Processed transcripts
13 processed in full · 5 in the curated path
Automated source review
Passed
Metadata candidates
0 unreviewed; not verified topic membership
Corpus version
1bd8e407b26a07b33815594e1b2db5f41827119a2b3cb6fbf240f9fc571fc767

Automated review checks source support; it is not publication approval.

A synthesis of selected conference talks and technical references. Citations link to the source material; they do not imply that every talk on this subject is included.

  1. NIST CSRC Glossary: Sandbox

    Terminology for the execution contract; definitions attributed to NIST publications and CNSSI.

  2. NIST CSRC Glossary: Trusted Computing Base

    First-use definition of trusted computing base; execution-boundary application is an explicit interpretation.

  3. OpenHands: An Open Platform for AI Software Developers as Generalist Agents

    Primary paper abstract, version 3; platform capabilities and separation of model, runtime, and evaluation.

  4. Safety and security for code-executing agents

    Give the agent a separate sandboxed environment and return its changes for review.

  5. The Protection of Information in Computer Systems: Basic Principles

    Section I.A.3, Design Principles, especially fail-safe defaults, complete mediation, and least privilege; section I.B, isolation mechanisms.

  6. Why, and how you need to sandbox AI-Generated Code? — Harshil Agrawal, Cloudflare

    Treat unbounded execution as both a cost risk and a denial-of-service risk, and enforce explicit execution limits.

  7. NIST Privacy Framework 1.0: lifecycle and minimized audit evidence

    Core ID.IM-P; GV.PO-P1; CT.PO-P; CT.DM-P5/P8; CM.AW-P6; PR.AC-P; PR.DS-P3.

  8. Beyond permission prompts: making Claude Code more secure and autonomous

    Primary engineering report; operating-system boundaries and permission-fatigue motivation.

  9. Linux fork(2): Separate Memory and Inherited Handles

    Linux process creation, memory separation, descriptor inheritance and parent-death behavior.

  10. Firecracker: Lightweight Virtualization for Serverless Applications

    Sections 2–3, jailer discussion, operational patching and Section 5.1; historical architecture and benchmark methodology.

  11. From fork() to Fleet: Designing an Agent Sandbox Cloud — Abhishek Bhardwaj, OpenAI

    Namespaces and cgroups address resource isolation and noisy neighbors, but containers still expose the shared host kernel; seccomp narrows that exposure at a compatibility cost.

  12. gVisor security model: containment and host dependencies

    Threats; Goals; What can a sandbox do?; System ABI, Side Channels and Other Vectors. Host-confidentiality limitation is an explicit inference from the documented trust boundary.

  13. Why, and how you need to sandbox AI-Generated Code? — Harshil Agrawal, Cloudflare

    Choose the execution environment per workflow step: isolates for constrained functions, containers for filesystem, process, and package-installation requirements.

  14. Arrakis: How To Build An AI Sandbox From Scratch

    Frequent device access can make VM exits and resumes a performance concern, so sandbox performance must be assessed against the workload.

  15. Keynote: The AI developer experience doesn't have to suck – why and how we built Modal

    Modal uses gVisor for isolation while building its own scheduling and surrounding infrastructure to meet its startup-latency goals.

  16. Linux namespaces(7)

    Namespace definitions, resource categories and lifetime; useful for separating visibility from cleanup.

  17. Linux Seccomp BPF Documentation

    Linux 5.17 documentation: introduction, limitations and filter inheritance.

  18. Linux capabilities(7)

    Description and capability list; complements the supplied capability-based security essay.

  19. Landlock: Unprivileged Access Control

    Introduction, rules and filesystem-access flags; concrete kernel-enforced access-control example.

  20. Linux chroot(2)

    Description and inherited-root behavior.

  21. Docker Rootless Mode

    How rootless mode works and its distinction from user-namespace remapping.

  22. Docker Engine Security: Daemon Attack Surface

    Daemon attack surface and resource-sharing examples; distinguish management authority from workload isolation.

  23. The Confused Deputy

    Three-page primary essay: compiler and billing-file example; discussion of two authorities; capability solution on page 2.

  24. OWASP Access Control

    OWASP; overview, least privilege, centralized checks and protected-resource examples. AI application is an engineering inference.

  25. Your Agent Didn’t Fail. Your Harness Did.

    Approval must remain bound to one specific action and its scope, identity, arguments, and lifetime; expiration should terminate the approval path.

  26. Cloudflare Dynamic Workers: Egress Control

    A concrete generated-code execution example of outbound mediation and keeping credentials outside workload memory.

  27. MCP TypeScript SDK: local subprocess launch and environment

    Official main-branch source: StdioServerParameters, getDefaultEnvironment and StdioClientTransport.start inspected.

  28. Vault: Lease, Renew, and Revoke

    Concrete credential lifecycle vocabulary: lease, expiry, renewal and revocation.

  29. Vault: Troubleshoot Irrevocable Leases

    Published failure scenario and explanation of unsuccessful credential revocation.

  30. Firecracker Snapshot Support

    Restore prerequisites, snapshot disk provisioning, and security and uniqueness.

  31. OWASP Logging Cheat Sheet

    Design, implementation, and testing: Data to exclude and Event collection; Deployment and operation: Protection and Disposal of logs.

  32. Docker Bind Mounts

    Mount meaning, mutation destination, read-only settings and recursive-mount limitations.

  33. Linux Overlay Filesystem

    Upper and Lower; Non-directories and copy_up behavior.

  34. Why, and how you need to sandbox AI-Generated Code? — Harshil Agrawal, Cloudflare

    PromptMotion's presented architecture gives each user a separate container and performs repository, dependency, and server operations inside it.

  35. Linux openat2(2): Constraining Untrusted Paths

    Resolve flags; applicable to trusted workspace readers and artifact exporters.

  36. Kubernetes Network Policies

    Prerequisites, isolation directions, Pod lifecycle and existing connections; concrete enforcement and readiness limitations.

  37. Why, and how you need to sandbox AI-Generated Code? — Harshil Agrawal, Cloudflare

    Block outbound networking by default and mediate necessary requests through a controlled service.

  38. What if the network was the sandbox?

    The proposed design moves authentication and authorization (AuthN/AuthZ) into identity-bearing network connections, combining reachability controls with identity available to the destination service.

  39. Amazon EC2: Access Instance Metadata

    IPv6 support, IMDSv2 token retrieval and container hop-limit considerations.

  40. OWASP Server-Side Request Forgery Prevention Cheat Sheet

    Overview; Case 1 example; application-layer protections and domain validation. Applies to model-selected URL-fetching tools.

  41. How we hacked YC Spring 2025 batch’s AI agents

    A tool that accepts an arbitrary repository destination can send its private-repository credentials to an attacker-controlled endpoint.

  42. Arrakis: How To Build An AI Sandbox From Scratch

    Arrakis gives each sandbox a TAP interface connected to a host bridge, then uses forwarding rules to expose guest services such as code execution and VNC.

  43. Linux Control Group v2

    Hierarchy, CPU, memory, process-count, I/O and core lifecycle interfaces.

  44. Linux getrlimit(2)

    Resource-limit definitions and CPU, address-space and file-size controls.

  45. systemd.service: Runtime and Stop Timeouts

    Upstream manual source: RuntimeMaxSec, TimeoutStartSec and timeout failure modes.

  46. Linux quotactl(2)

    Quota description and block/inode fields; complementary to cgroup I/O rate limits and per-file limits.

  47. AWS Builders' Library: timeouts, retries, backoff and jitter

    Timeouts; Retries and backoff; Jitter.

  48. Quantifying infrastructure noise in agentic coding evals

    Primary engineering experiment; controlled resource variation and infrastructure-versus-capability distinction.

  49. Images — Kubernetes

    Image names and image pull policy; artifact identity for the dependency-and-deployment example.

  50. npm v8 Scripts and Lifecycle Events

    Version 8.19.4 documentation; lifecycle scripts and Git dependency preparation.

  51. SWE-bench Docker Setup

    Docker Resource Management: Understanding SWE-bench's Docker Usage; Cache Level Configuration; Performance Optimization; Troubleshooting Docker Issues.

  52. Temporal Activity Execution

    What is an Activity Execution?; task-loss, Start-To-Close timeout and retry discussion; Cancellation.

  53. Why, and how you need to sandbox AI-Generated Code? — Harshil Agrawal, Cloudflare

    Make destruction part of lifecycle handling, with try/finally cleanup and maximum lifetimes.

  54. Demystifying evals for AI agents

    Primary engineering report; evaluation structure, grader types, and capability versus regression suites.

  55. Python tarfile: Extraction Filters and Further Verification

    Extraction filters, filter errors and verification guidance; concrete retained-artifact boundary.

  56. Harbor Task Structure

    Creating a task; Configuration & Metadata; Environment; Verifier; Verifier environment; What gets transferred; Network policy.

  57. We Gave an Agent Production Code Access and Then Tried to Sleep at Night

    Separate agent reasoning from privileged orchestration so an injected agent cannot directly push changes, open PRs, or trigger CI.

  58. From fork() to Fleet: Designing an Agent Sandbox Cloud — Abhishek Bhardwaj, OpenAI

    Periodic disk checkpoints allow long-running work to recover on another node and enable intentional fleet maintenance without discarding all accumulated work.

  59. From fork() to Fleet: Designing an Agent Sandbox Cloud — Abhishek Bhardwaj, OpenAI

    Frequent checkpointing at large scale favors incremental snapshots, cheap save operations and fast restore, with explicit choices about persistence scope and change granularity.

  60. Arrakis: How To Build An AI Sandbox From Scratch

    Arrakis checkpoints guest memory and the writable filesystem while the VM is paused, then resumes execution.

  61. Making Retries Safe with Idempotent APIs

    Retries and semantic equivalence; Late arriving requests and the life span of unique client request identifiers; Same client request ID, different intent.

  62. Teaching AI to Find Real Vulnerabilities — Prof. David Brumley, Bugcrowd

    A fault within the sandbox and an exploit that crosses the sandbox boundary are different capability levels.

  63. gVisor Security Model

    Official runtime architecture, System API, Other Vectors, and Goals: Limiting Exposure. Explains what a sandbox does rather than naming a product as a complete solution.

  64. Arrakis: How To Build An AI Sandbox From Scratch

    The talk connects microVM security to memory-safe VMM implementations and device jailing, and their smaller footprint to restricted architecture and device support.

  65. We Gave an Agent Production Code Access and Then Tried to Sleep at Night

    Giving an agent access to a host Docker daemon can undermine the surrounding sandbox by allowing privileged container creation.

  66. Linux Yama: process-memory inspection and privileged tracing

    Official Linux kernel Yama documentation, ptrace_scope threat discussion and modes 0–3. Local-assistant application is a stated implication, not a gVisor-specific tracing recipe.

  67. SWE-bench Evaluation Guide

    Overview; Basic Evaluation; Advanced Usage; Evaluation Results and report-counter explanations; Troubleshooting.

  68. Coding Agents Are Guessing: Measuring Action-Boundary Violations in Underspecified DevOps Instructions

    Sections III-B–III-D and VI-C; controlled underspecification, state reset, side-effect checks, and benchmark limitations.

  69. systemd.kill: Process Killing Procedure

    KillMode, signal escalation and process-survival warnings.

  70. The Protection of Information in Computer Systems: Basic Principles

    Section I.A.2 Controlled sharing and protected subsystems; I.A.3 principles c, e and f; I.B discussion of principals.

  71. Keynote: The AI developer experience doesn't have to suck – why and how we built Modal

    Content-addressed storage can represent container images as metadata pointing to deduplicated blobs, with data loaded only when accessed.

  72. Keynote: The AI developer experience doesn't have to suck – why and how we built Modal

    Sequential module reads can accumulate remote filesystem latency, so reducing transferred bytes alone is insufficient.

  73. Keynote: The AI developer experience doesn't have to suck – why and how we built Modal

    Restoring CPU memory can bypass initialization work that remains even after image data is cached.

  74. Arrakis: How To Build An AI Sandbox From Scratch

    Namespaces and cgroups bound resource visibility and consumption, but container processes still share the host kernel; Arrakis chooses microVMs to reduce exposure between tenants.

  75. Resolving an ambiguous payment request

    Network errors, Server errors and Idempotency; metadata correlation during reconciliation.

  76. Arrakis: How To Build An AI Sandbox From Scratch

    Grant only required Linux capabilities and apply seccomp filtering; the speaker recommends MiniJail to manage the difficult low-level APIs.

  77. Why, and how you need to sandbox AI-Generated Code? — Harshil Agrawal, Cloudflare

    Apply capability-based security: default deny, then expose only narrow, explicitly granted interfaces.

  78. Activity Definition — Temporal

    Official documentation, Idempotency section; recorded completions versus unreported activity attempts.

  79. From fork() to Fleet: Designing an Agent Sandbox Cloud — Abhishek Bhardwaj, OpenAI

    The speaker recommends microVMs for agents needing a full Linux environment, combining a hardware isolation boundary with a smaller, memory-safe and compartmentalized host implementation.