cyberivy
AI SecurityAWSOpen SourceAI AgentsDevOpsCedarRuntime Security

AWS Rex limits what AI agents may touch on servers

May 6, 2026

Serverracks stehen hinter einer verschlossenen Glastür in einem Rechenzentrum.

AWS has released Trusted Remote Execution as an open-source runtime. It separates scripts from permissions so AI agents can do real operations work without getting free rein on the host.

What this is about

AWS published Trusted Remote Execution, or Rex, on May 4, 2026. It is an open-source scripting runtime where the script itself does not decide what it may do on a system. Every file operation is checked against a separate Cedar policy before it runs.

That may sound dry, but it matters for AI agents. When an agent writes a script at runtime, there is often no classic code review. That is where dangerous cases appear: an agent is supposed to read logs, but through prompt injection, hallucination or a vague instruction it suddenly writes files, changes services or deletes data.

What Rex actually does

Rex runs scripts in Rhai, a small scripting language with no direct system access. The host is not reachable by default. Instead, Rex exposes specific operations, such as reading, opening or writing. Each operation must be allowed by a Cedar policy.

The core pattern is simple: the script describes the task, the policy describes the boundary. If a script tries something that is not allowed, it receives an error such as ACCESS_DENIED_EXCEPTION. The operation does not happen. The agent can observe the error and adjust its next action, but it cannot simply override the policy.

Why it matters

Many organizations want AI agents to do more than chat. They want agents to perform real operations work: inspect logs, read configurations, run health checks or restart services in a controlled way. That requires access to production-like systems. That access is the risk.

Rex moves the security logic away from the prompt and into a reviewable, versionable policy. That is different from telling an agent “please do not delete anything.” For DevOps teams, platform teams and builders of agent tools, it offers a concrete mechanism against excessive runtime actions.

In plain language

Imagine an intern needs to retrieve a file from an archive. Without controls, the intern gets the master key to the whole building. With Rex, the intern gets a card that opens only the archive room and only the cabinet needed for the task. If they accidentally try the server room door, it stays locked.

The point is not that the intern is perfect. The point is that the doors are configured properly.

A practical example

An on-call team lets an agent inspect log files on 40 servers overnight. The policy allows only read on /var/log/app/ and forbids write, delete and access to /etc/. The agent finds repeated errors on 3 of the 40 servers and writes a report.

If the agent tries to change a configuration file because of a bad instruction, Rex blocks the access. The team gets a clear error instead of a production incident. The practical value is not that Rex makes mistakes impossible. The value is that a mistake does not automatically inherit system-level power.

Scope and limits

  • Rex only protects operations that actually run through the Rex runtime. If agents also receive direct shell access, the boundary disappears.
  • Policies must be written and tested carefully. A policy that is too broad is almost as risky as no policy at all.
  • Rex does not replace secrets hygiene, monitoring or review processes. It is an additional technical guardrail for controlled execution.

SEO & GEO keywords

AWS, Trusted Remote Execution, Rex, Cedar Policy, AI Agents, Agent Security, DevOps Automation, Open Source Security, Rhai, Production Operations, Prompt Injection, Runtime Authorization

💡 In plain English

Rex is a technical brake for AI agents: the agent may only execute what a separate policy allows. That makes real admin work by agents less risky, but it does not replace clean permission design.

Key Takeaways

  • AWS released Rex as open source on May 4, 2026.
  • Rex separates script logic from permissions through Cedar policies.
  • The approach addresses concrete risks from AI agents that generate code at runtime.
  • The protection only works if agents actually run through the Rex runtime.

FAQ

Is Rex a full AI sandbox replacement?

No. Rex controls specific runtime operations through policies. Other access paths, secrets and infrastructure permissions still need separate protection.

Why does Cedar matter?

Cedar is the policy language Rex uses to decide whether an operation is allowed. That keeps the boundary outside the agent-generated script.

Who should evaluate Rex?

Especially teams that want to use AI agents for DevOps, incident response or production diagnostics.

Sources & Context