By NHI Mgmt Group Editorial TeamBased on Agentic Fabriq: “Sandboxing Agents: What Each Isolation Boundary Actually Contains” (September 4, 2026)

TL;DR: Agent sandboxes fail more often because they let requests leave, credentials stay mounted, and sessions carry too much authority than because an attacker escapes the boundary, according to Agentic Fabriq. The decisive control is not the box type alone but whether egress, secrets, filesystem scope, and session lifetime are tightly constrained.


At a glance

What this is: This is a boundary-by-boundary guide to agent sandboxing that argues exfiltration controls, not escape prevention alone, decide whether code, browser, or desktop agents stay contained.

Why it matters: It matters because IAM and NHI teams need to govern what an agent can access, send, and retain inside the sandbox, not just which isolation technology sits underneath it.


Context

Most sandbox discussions start with the wrong question. A container, microVM, or VM can reduce escape risk, but the operational failure often comes from what the agent is allowed to do inside the boundary. For agentic systems, the real issue is whether the sandbox can make outbound requests, see mounted secrets, or carry authority beyond the task.

That makes sandbox design an identity problem as much as an isolation problem. When the agent holds valid credentials, the box is only one layer in the control stack, and the more important questions are what session authority exists, what filesystem scope is exposed, and whether the sandbox can reach anything outside its intended task. Treat secrets management as part of the boundary, not an adjacent concern.


Key questions

Q: What should security teams do first when an agent sandbox can reach the network?

A: Start by denying outbound access and allowlisting only the destinations the task truly needs. If a sandbox can send packets freely, containment shifts from isolation to hope, because hostile code, prompt injection, or mistaken automation can exfiltrate data or trigger live actions without ever escaping the box.

Q: Why do agent sandboxes become high risk when credentials are mounted inside them?

A: Because the sandbox then inherits the full authority of those credentials. Isolation may still reduce host compromise, but it does nothing to limit what the agent can do with valid secrets already present in the runtime, which turns a containment decision into a blast-radius problem.

Q: What breaks when browser agents inherit authenticated sessions?

A: The main failure is that the agent inherits the user's reach without inheriting the user's judgment. That means tokens, cookies and delegated permissions can be used to submit forms, manipulate accounts or move data across systems as if the activity were legitimate. Once session authority and agent action are combined, traditional login controls are no longer enough.

Q: How should teams decide between containers, microVMs, and kernel-enforced controls for agent sandboxes?

A: Start with the asset at risk, the input source, and the blast radius you can tolerate. Containers are faster but weaker against kernel compromise, microVMs isolate more strongly but add overhead, and kernel-enforced controls are strongest locally but less suitable for multi-tenant platforms.


Technical breakdown

Why egress control is the real sandbox boundary

A sandbox can still fail even when no escape occurs if the agent can make outbound connections. Egress defines whether generated code, browser automation, or desktop actions can exfiltrate data, call attacker infrastructure, or invoke live systems. If the sandbox holds credentials and can reach the network, the containment story collapses into policy on the outside instead of isolation on the inside. For agentic workloads, the most important question is not “can it break out?” but “what can it talk to if it stays in?” See the AI Coding Agents Security Guide.

Practical implication: Design for deny-by-default egress and allow only the specific destinations the task genuinely needs.

Why secrets inside the sandbox undo the boundary

Isolation technology does not compensate for credential placement. If a sandbox contains long-lived tokens, API keys, or mounted cloud credentials, then any process that runs inside it inherits that authority. In that case, a microVM or container mostly changes the path of compromise, not the blast radius. The stronger pattern is to keep raw secrets out of the guest and let a broker inject credentials only at call time on the outbound leg, so the sandbox can request actions without owning reusable secrets. See the API Key Management Guide.

Practical implication: Move credential possession out of the sandbox and into a brokered action path.

How filesystem scope and lifetime shape agent risk

A sandbox that can see a home directory, shared volume, or full repository checkout can reuse far more data than the task requires. That expands both exposure and persistence, especially when sessions survive after the work is done. Short-lived sandboxes with copy-in inputs, copy-out outputs, and no durable state limit how much an attacker or a mistaken agent can keep touching. This is why lifetime and filesystem scope belong in the same design conversation as the isolation runtime itself. Read the Ultimate Guide to NHIs: Static vs Dynamic Secrets.

Practical implication: Minimise mounted state and destroy the task environment after completion.


Threat narrative

Attacker objective: The objective is to make the agent exfiltrate data or perform unauthorised actions while remaining within a session that still appears legitimate.

  1. Entry occurs when the agent is given legitimate execution rights inside a sandbox that still has network access and mounted credentials.
  2. Escalation happens when the agent uses those credentials or reachable services to perform actions the operator did not intend, without needing a kernel escape.
  3. Impact follows when data leaves through authorised outbound channels or destructive actions are executed under the agent's session authority.

Read and download The State of NHI & AI Agent Breach Report 2026, covering 200+ breaches impacting Non-Human Identities including AI Agents.


NHI Mgmt Group analysis

Sandboxing is an identity governance problem disguised as infrastructure design. The article shows that the decisive failure mode is not only runtime escape but authority that survives inside the box. Once a sandbox can hold credentials, reach the network, and persist long enough to reuse state, the control plane has already ceded too much. The implication is that sandboxing must be governed as a scoped identity boundary, not treated as a packaging choice.

Secret placement is the control that determines whether isolation has any real meaning. NHI controls assume that credentials are separable from execution environment, but agent sandboxes break that assumption when secrets are mounted directly into the runtime. That creates a reusable authority surface that outlives the task and can be exercised by whatever code runs inside the guest. The practitioner conclusion is to measure sandbox safety by what authority never enters it.

Browser and desktop agents expose the confused deputy as a governance failure, not a technical quirk. The article's browser examples show that the agent can be fully authorised and still be steered by untrusted content. In that model, stronger isolation does not solve the problem because the session itself is the weapon. Practitioners need to recognise that human-paced approval loops and post-hoc review do not contain actions already authorised within the session.

Identity blast radius is the right named concept for this pattern. The relevant question is how much authority, data visibility, and network reach the agent carries at the moment it runs. A boundary that reduces escape risk but leaves broad egress and mounted secrets still produces a large blast radius. The practitioner takeaway is to govern containment by reachable impact, not by the elegance of the isolation stack.

Read next: Secrets Management Guide

What this signals

The next governance shift is to treat sandboxing as a control over reachable authority, not just execution environment. Teams that keep measuring only escape resistance will miss the more common failure mode: a legitimate session with too much network reach, too much filesystem scope, and too much retained authority.

Identity blast radius: this is the practical measure of how much damage an agent can cause if it stays inside its boundary but keeps its secrets and outbound reach. The stronger the sandbox looks on paper, the less it matters if the agent can still call external systems and act with reusable privilege.


For practitioners

  • Set egress to deny by default Allow only the specific destinations the task needs, and route any live data access through a brokered proxy rather than direct outbound access.
  • Remove reusable credentials from the guest Keep API keys, tokens, and cloud credentials out of the sandbox and inject authority only at call time through a controlled service boundary.
  • Copy inputs in and results out Avoid mounting live repositories, home directories, or shared volumes unless the task genuinely requires them, and destroy the environment after the run.
  • Treat browser sessions as hostile authority Use ephemeral profiles, narrow origin access, and explicit step-up controls for irreversible actions because the session, not the browser process, is the control problem.

Key takeaways

  • Agent sandboxing fails when it protects the host but leaves the agent free to exfiltrate data or act with mounted credentials.
  • The main control question is not which isolation runtime to use, but how much authority, network reach, and filesystem scope the task receives.
  • A useful sandbox minimises secrets, narrows egress, and dies with the task, so the blast radius stays small even if the agent misbehaves.

Related NHI Mgmt Group resources: Secrets Management Guide · API Key Management Guide · Guide to the Secret Sprawl Challenge · Enterprise Browser and Browser Security Guide


Standards & Framework Alignment

This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.

OWASP Non-Human Identity Top 10 and OWASP Agentic AI Top 10 address the attack and risk surface, while NIST CSF 2.0 and NIST Zero Trust (SP 800-207) set the governance and control requirements practitioners need to meet.

FrameworkControl / ReferenceRelevance
OWASP Non-Human Identity Top 10NHI-02 — Secret LeakageThe article centers on secrets mounted into sandboxes and exposed through task execution.
NHI-07 — Long-Lived SecretsThe post argues that long-lived tokens inside sandboxes undo the containment boundary.
NHI-04 — Insecure AuthenticationBrowser and desktop agents rely on live sessions whose authority can be manipulated.
Recommendation — Keep reusable secrets out of task sandboxes and broker credential use at call time. Replace long-lived credentials with brokered, short-lived authority where tasks execute. Scope interactive sessions tightly and require step-up controls for irreversible actions.
OWASP Agentic AI Top 10ASI02 — Tool MisuseAgents can misuse permitted tools and outbound channels even without escaping the sandbox.
ASI03 — Identity & Privilege AbuseThe article's core issue is authority that persists inside the agent boundary.
Recommendation — Constrain tool reach and outbound actions so agent authority cannot drift at runtime. Limit agent privilege to the minimum task scope and revoke it when the task ends.
NIST CSF 2.0PR.AA-05 — Access Permissions, Entitlements and AuthorizationsSandbox boundaries here are fundamentally about permissions, entitlements, and reachable actions.
PR.DS-01 — Data-at-Rest is ProtectedMounted files and copied inputs inside the sandbox define the data exposure surface.
Recommendation — Align sandbox permissions and entitlements to the task's exact data and action needs. Protect task data by minimising mounts and preventing unnecessary data persistence.
NIST Zero Trust (SP 800-207)Section 2 — Zero Trust ArchitectureThe article applies zero trust logic to agent sessions and outbound access decisions.
Recommendation — Treat every outbound request from the sandbox as untrusted until explicitly authorised.

Key terms

  • Identity Blast Radius: The amount of damage a compromised identity can cause across systems, data, and infrastructure. In NHI environments, it is shaped by permissions, network reach, and administrative capability rather than by the credential alone. Reducing blast radius is a containment strategy that limits lateral movement and data exposure.
  • Confused Deputy: A confused deputy is a privileged system that is tricked into performing an action on behalf of an untrusted requester. In agentic AI, the agent may misread malicious input as legitimate intent and then use its own authority to act, which turns a logic problem into a security incident.
  • Brokered Credential: A brokered credential is a secret held by an enforcement layer and injected only when a specific action is authorised. This keeps reusable credentials out of the agent runtime, which reduces exposure to prompt injection, context leakage, and direct secret reuse.
  • Default-Deny Egress: Default-deny egress means outbound network traffic is blocked unless it is explicitly allowed by policy. For agentic workloads, this stops prompt-injected or compromised processes from contacting attacker-controlled hosts, even if the code inside the session is otherwise able to run normally.

Deepen your knowledge

NHI governance, agentic AI identity, and machine identity lifecycle are core topics in our NHI Foundation Level course, the industry's only accredited NHI security programme. If you are building or maturing an IAM programme, it is worth exploring.
NHIMG Editorial Note
Published by the NHIMG editorial team on October 22, 2026.
NHI Mgmt Group, the independent authority on Non-Human Identity, IAM, and Agentic AI security. nhimg.org