Skip to content
Esc
↑↓navigate↵open⌘Jpreview
Start
On this page

Securely Deploying AI Agents

A guide to securing Autohand Code and Agent SDK deployments with isolation, credential management, and network controls.

← Back to Hosting

This guide covers threat models, built-in security features, security principles, isolation technologies, credential management, and filesystem configuration for secure Agent SDK deployments.

Threat Model

Understanding the threat model is essential for securing Agent SDK deployments. Consider the following attack vectors:

  • Prompt injection: Malicious inputs attempting to manipulate agent behavior
  • Tool abuse: Agents using tools to access unauthorized resources
  • Credential exposure: API keys or secrets being leaked
  • Data exfiltration: Sensitive data being extracted through agent outputs
  • Sandbox escape: Breaking out of isolated environments

Refer to the model card for detailed information about model capabilities and limitations.

Built-in Security Features

Security Principles

Security Boundaries

Establish clear security boundaries between the agent and your systems:

  • Separate agent execution from production infrastructure
  • Use network segmentation to limit agent access
  • Implement filesystem isolation for code and data
  • Apply least privilege to all agent operations

Least Privilege

Grant agents only the minimum permissions needed to complete their tasks:

  • Restrict tool access to only necessary tools
  • Limit filesystem access to specific directories
  • Use role-based access control for different agent types
  • Regularly audit and remove unnecessary permissions

Defense in Depth

Implement multiple layers of security controls:

  • Container isolation
  • Network restrictions
  • Filesystem controls
  • Request validation at a proxy

Isolation Technologies

Sandbox Runtime

The sandbox runtime provides OS-level isolation for agent execution:

Limitations

  • Same-host kernel: Unlike VMs, sandboxed processes share the host kernel. A kernel vulnerability could theoretically enable escape. For some threat models this is acceptable, but if you need kernel-level isolation, use gVisor or a separate VM.
  • No TLS inspection: The proxy allowlists domains but doesn’t inspect encrypted traffic. If the agent has permissive credentials for an allowed domain, ensure it isn’t possible to use that domain to trigger other network requests or to exfiltrate data.

Containers

Docker containers provide additional isolation layers:

gVisor

gVisor provides user-space kernel for stronger isolation:

Virtual Machines

For the strongest isolation, use virtual machines. Consider:

  • AWS Nitro Enclaves
  • Google Confidential Computing
  • Azure Confidential Computing
  • Firecracker microVMs

VMs provide kernel-level isolation and are suitable for high-security deployments.

Cloud Deployments

For cloud deployments, follow these security practices:

Credential Management

The Proxy Pattern

The proxy pattern centralizes credential management:

Configuring the SDK to Use a Proxy

Implementing a Proxy

Credentials for Other Services

Filesystem Configuration

Read-Only Code Mounting

Mount code as read-only to prevent agents from modifying it:

Writable Locations

Use tmpfs for writable directories that don’t need persistence:

Next Steps

Last updated on

Was this helpful?

Send Feedback

Help us improve this documentation page. Your feedback is valuable.

We'll only contact you if we need clarification