AI agents are systems that not only generate text but independently execute steps: read and write files, launch programs, call interfaces.This very ability to act is what makes them interesting for development and business processes – and demanding in terms of security.

Anthropic, the provider of the Claude models, reports that its own models repeatedly find ways to break out of the intended test environment.To assess how strong this incentive actually is, researchers at the company have developed a new test.The details of the methodology are secondary here; what matters is the observation itself – and it comes not from critics but from the manufacturer.

Why this is relevant for projects

In practice, agents are rarely operated in isolation.They are connected to repositories, ticket systems, databases, mailboxes or deployment pipelines.An agent that only produces text suggestions in a test run often has write permissions in productive operation.

When a provider publicly admits that models probe the boundaries of their environment, a sober consequence can be derived from this: Safeguarding must not lie in the model alone.It belongs in the architecture around it – where it is verifiable and independent of the respective model version.

Sandbox means more than a dedicated container

A sandbox is an isolated execution environment in which a process can only access clearly defined resources.For agents, it is not enough to run the code in a container.At a minimum, the following must be clarified:

  • Network access: Which destinations may the agent reach?An allowlist of permitted addresses is more robust than a blocklist.
  • File system: Which paths are readable, which are writable?Project directory instead of system directory.
  • Secrets: Credentials and API keys do not belong in the model's context, but behind an upstream service that executes calls on its behalf.
  • Runtime and costs: Hard upper limits for steps, runtime and token consumption prevent an agent from burning resources in loops.

Permissions according to the principle of least privilege

The principle of least privilege – each component receives only the permissions it needs for its task – is established in IT security, but is often bypassed with agents.Often the agent gets a service account with far-reaching permissions because that accelerates integration.

More sustainable is a division by task: read access for research and analysis, a separate, narrowly limited write access for the few operations that are actually allowed to make changes.Changes to production systems should fundamentally run through the same path as human changes – i.e. via pull requests, reviews and deployment processes, not bypassing them.

Approvals in the right places

Not every action needs confirmation by humans; otherwise the productivity gain is lost.What makes sense is a gradation by impact and reversibility:

  1. Automatic: read operations, analyses, drafts in an isolated environment.
  2. Automatic with logging: changes that can be easily undone, such as commits in a feature branch.
  3. Only with approval: anything that has an external effect or is difficult to reverse – deployments, deletions, payments, emails to customers, changes to permissions.

Test before the agent gets permissions

The approach of specifically testing the behaviour of models in constructed situations can be adopted on a small scale.For your own agents, this means: define scenarios in which the shortest path to the goal violates the rules, and observe how the system reacts.

Typical test questions are: Does the agent try to reach a blocked resource via a detour?Does it report missing permissions or bypass them?Does it react to instructions hidden in processed content – for example in a website, a ticket or a PDF file?This case, called prompt injection in technical jargon, is particularly delicate with agents that have internet access, because external content can effectively become instructions.

Such tests should be run repeatedly, not just once.Models are updated, system prompts changed, tools added – any of these changes can shift behaviour.

Traceability as a foundation

Without complete logging, it is impossible to reconstruct what happened after an incident.What should be recorded is the executed tool calls with parameters, the decision points, rejected actions and the model version used.This serves not only troubleshooting but also documentation obligations towards customers, auditors and internal audit departments.

Equally important is a defined shutdown path: Who can stop the agent in case of doubt, how quickly, and which accesses are blocked in the process?This question should be answered before the first production run, not during an incident.

Don't forget the organisational side

Technical guardrails only work when it is clear who is responsible.This includes a named responsibility for each agent, an overview of all granted accesses and a rule for when an agent is taken out of operation.An agent that no one maintains any more but that still holds permissions is a risk with no countervalue.

It is also helpful to increase use step by step: first suggestions, then changes with approval, then more narrowly defined automatic processes.

Every step presupposes that the previous stage ran without incident over an extended period.

Classification for web and software projects

For projects, this above all means: the security effort shifts from the model into the system architecture. Anyone integrating agents into CMS workflows, deployment chains or customer processes should plan permissions, sandboxing and approval stages just as carefully as the data model and interfaces – and allow time for this in the budget. The benefit remains real, but it only arises where the agent has a clearly defined scope for action and every action remains traceable.

Sources