OpenAI published its internal security architecture for running persistent agents at scale — the blueprint it uses for more than 500 OpenClaw agents deployed company-wide. With the release of OpenClaw Enterprise (OCE), those controls are now available to any organization building persistent agents on top of OpenClaw.

What Shipped

OpenAI's post, "Securing persistent agents like OpenClaw at OpenAI," documents the security model the company developed over the course of deploying OpenClaw internally at scale. As of publication, OpenAI runs over 500 persistent agents across the entire company — from automated PR generators responding to product feedback to continuous data-experiment runners for new features.

The post describes five control layers, each addressing a category of risk that doesn't exist with traditional software:

1. Separation of trusted and untrusted execution. Traditional software relies on code being deterministic; attacks come from the outside. Persistent agents break both assumptions: they write code dynamically, and attacks can come from the inside when agents take misaligned actions. OpenAI's solution separates the OpenClaw Gateway (trusted deterministic code — networking, identity, sandboxing) from the agent harness (untrusted — the environment where the agent runs and writes code). These run in separate containers and, in OpenAI's case, separate clusters. This was implemented as remote harness execution in the OpenClaw open source project.

2. Hard sandbox boundaries. Once trusted and untrusted execution are separated, the untrusted side gets strict sandboxing. OpenAI's configuration covers four dimensions:

  • Network: An organization-managed allowlist. Their published requirements.toml allows github.com, api.github.com, and codeload.github.com, and explicitly denies pastebin.com, webhook.site, cloud metadata endpoints (metadata.google.internal, 169.254.169.254), and others.
  • Workspace: Writes limited to /home/dev-user/openclaw-workspaces; SSH credentials at /home/dev-user/.ssh denied.
  • Process: Isolation via the codex Linux sandbox. danger-full-access mode is excluded from allowedsandboxmodes; only read-only and workspace-write are permitted.
  • Secrets: Managed through a credential broker so secrets are never visible to the agent. GHTOKEN, GITHUBTOKEN, and OpenClaw-specific auth tokens are stripped from shell environments.

The post includes the full requirements.toml and config.toml configuration as copy-paste reference, covering sandbox modes, web search modes (only cached allowed, not live), network proxy requirements, filesystem permissions, and SOCKS5 controls.

3. Model-based auto-review. Static controls stop known bad actions; they don't scale with model capability. OpenAI's solution is Auto-review, where a second agent monitors and approves the actions of the primary agent. Constant human review creates approval fatigue — humans trained to blindly click "accept" are functionally useless as a safety check. The LLM-based reviewer filters the stream of agent actions, reserving human attention for genuinely high-value decisions. Auto-review is natively supported in both OpenClaw and Codex, and OpenAI enforces it on all agent actions in their deployment.

4. Agent identity separate from user identity. When an agent takes an action, the system needs to audit it, grant it appropriate resource access, and distinguish it from a human action. OpenAI gives each agent a unique identity associated with a ChatGPT Service Account, providing each agent its own inference credential separate from the user's. This also lets teams connect custom plugins and gives security teams the ability to revoke inference access from a specific agent if needed. The post references emerging specifications — WAG (Workload Authorization Grant) and XAA (OAuth delegation) — as the direction standards are heading.

5. Comprehensive observability. Every configuration change on the control plane and every agent turn is logged. Because agent turns can contain sensitive information, these logs are locked down and available only to a select subset of the security team. The goal is full lifecycle visibility — from how an agent was configured to every action it took.

OpenClaw Enterprise (OCE): Announced at OpenAI Dev Day, OCE is an open-source, vendor-neutral agent control plane. The standard codex preset embeds many of the safeguards described in the post. OpenAI notes the project is in pilot phase and plans a 1.0 release by end of year.

Why It Matters

This is the first detailed public blueprint for enterprise-grade persistent agent security from an organization that has actually deployed it at scale. The gap it fills is not theoretical: persistent agents have been technically possible for years, but lack of established security practices has been a genuine adoption blocker for enterprises in regulated industries.

The five-layer architecture addresses something that neither traditional application security nor prompt engineering alone can solve. Network allowlists, process isolation, and secret brokering are well-understood controls — the novel contribution here is showing how they compose with model-level controls (auto-review) and identity infrastructure (service accounts) into an integrated security posture.

The release of OCE with these controls built-in as a default preset matters because it removes the friction of implementing each layer independently. For teams that have been waiting for a "safe by default" agent control plane before deploying persistent agents, this is that offering.

The comparison to traditional software is worth internalizing: in traditional software, determinism is the baseline assumption and threats are external. With persistent agents, neither holds. The mental model shift this requires — treating agent outputs as untrusted regardless of model quality, enforcing isolation between the control plane and execution environment — is the core contribution of this post.

Adoption & Practical Steps

Based on the published architecture and configuration:

  • Start with the trusted/untrusted split. Remote harness execution in OpenClaw is the foundation everything else builds on. If the gateway and harness share a container, network controls and secret brokering lose most of their value because a compromised harness can reach the gateway directly.
  • Use the published requirements.toml as a starting point, not a template. The network allowlist OpenAI uses (github.com and related endpoints) reflects their use case. Your allowlist will differ. The important design principle is that the allowlist is managed at the organization level and the agent cannot expand it.
  • Enable auto-review on all actions initially. Even with low LLM-based rejection rates, running auto-review from the start gives you baseline data on what your agents are actually trying to do, which is the input you need to tune review thresholds and human escalation rules.
  • Provision agent identities before you need them. Using ChatGPT Service Accounts (or equivalent) from the start, rather than piggybacking on user credentials, makes auditing and revocation tractable. Adding this retroactively to a large agent fleet is expensive.
  • What is unknown: OCE is explicitly in pilot phase, and the 1.0 timeline (end of year) is OpenAI's own estimate. The gap between "controls built into the standard codex preset" and "fully production-hardened for a regulated industry" is not addressed in the post. The WAG and XAA standards referenced for agent identity are still in IETF draft status and not yet deployable.

The standard codex preset documentation and OCE project are referenced in the post for teams ready to begin implementation.

References