Give it an identity, a purpose, and boundaries - not just an API key
Imagine you build an AI agent to help your support team investigate customer cases.
At first, it only summarizes information. Then you connect it to the ticketing system. Next, you let it retrieve internal documents. Eventually, someone asks: “Could it update the case for us, too?”
Each connection makes the agent more useful. It also gives it more authority.
Here is the security problem: a manipulated agent can use legitimate access for an unintended purpose. Its requests may look like ordinary authorized activity because it is using valid credentials.
That risk applies whether the agent borrows a human’s permissions or uses its own machine identity.
Before choosing an agent framework or IAM provider, we need to answer a simpler question:
What identity is acting, and what is that identity allowed to do?
That is where treating an agent as a production principal begins.
1. What does “production principal” mean?
In practical terms, a production principal is an identity whose access to real systems must be deliberately managed.
For an AI agent, that means more than assigning a name or storing a credential. The collection’s guidance is explicit: define what the identity may do, where it may do it, how long its credentials last, who owns it, what logs establish its behavior, and how quickly it can be revoked.
Think of it this way:
An agent’s name describes it. Its security identity determines the authority it can exercise.
Calling an agent SupportHelper does not establish a permission boundary. Giving it a distinct, owned identity with controlled access does.
“Production principal” is therefore a security operating model—not a claim that the agent is a person or should receive broad production privileges.
2. Why agents need explicit boundaries
Agents can interpret goals, select tools, retrieve context, and revise their plans after seeing results. Their exact sequence of actions may not be known until runtime.
That makes authorization more than a login check. Authenticating an agent is not enough to establish whether every action it chooses should be permitted.
For our support agent, these are different questions:
- Identity: Which agent is making the request?
- Authority: Is it using its own access or a human’s access?
- Permission: May that authority perform this operation?
- Autonomy: May the agent proceed, or does the action require human oversight?
The model should not be the sole authority deciding whether an operation is allowed. The OWASP guidance explicitly warns against relying solely on model output for authorization decisions.
3. Picture the boundary before writing code
Here is a conceptual architecture for our example—not a provider-specific implementation:

The important boundary is between proposing an action and being permitted to execute it.
For irreversible operations, OWASP recommends separating decision-making from execution. It also advises against unrestricted tool access and high-impact decisions without human oversight.
4. Write the agent’s identity specification
Before implementing authentication, write down the identity’s operating requirements.
For our fictional support agent, an initial specification might look like this:
Property | Illustrative requirement |
|---|---|
Purpose | Investigate support cases and prepare summaries |
Identity | A distinct identity for this agent’s production workload |
Owner | A named team accountable for its purpose and access |
Environment | Access bound to the production environment it serves |
Permissions | Read relevant cases; no user-account administration |
Action boundaries | High-impact changes require human oversight |
Credentials | Short-lived, automatically rotated, and revocable |
Interactive login | Denied unless explicitly needed |
Audit | Actions attributed to this agent rather than a shared automation account |
Retirement | A documented way to revoke access when its purpose ends |
These are proposed requirements for the example, not a configuration copied from the collection.
Why ownership deserves its own row
A machine identity can remain active long after the original project changes.
The collection describes agent identities persisting as vault tokens, service principals, or platform bot accounts. If nobody owns the identity’s purpose, permission drift can go unnoticed.
An owner should therefore be accountable for the agent’s continuing need for access—not merely for creating its credentials.
5. Make the source of authority visible
An agent can operate in two important ways:
It uses human authority
It may work through a user’s browser session, repository credential, SaaS token, or approval flow.
It uses non-human authority
It may use its own bot credential, service principal, workload identity, or CI token.
Neither arrangement is automatically safe. Broad permissions in either path can become available to an attacker who manipulates the agent.
For each sensitive action, document:
Is this the agent’s own authority, or authority delegated by a human?
Do not hide the answer behind “the agent has access.” The collection specifically warns about systems that mix identity modes without making that mixture explicit.
6. Limit both permissions and agency
Least privilege asks:
What access does this identity need?
The collection introduces a complementary idea: least agency.
It asks:
How much autonomy, tool use, workflow reach, and action authority should the agent have?
For our support example, that distinction matters. An agent might be allowed to read a case and propose an update without being allowed to independently execute a high-impact change.
Permissions control what is accessible. Agency boundaries control how much the agent may do with that access.
7. Check that the identity is operationally manageable
Before connecting the agent to real resources, review these questions:
- Can we identify its accountable owner?
- Are its permitted actions and environments explicit?
- Can we distinguish its actions from other automation?
- Are credentials short-lived and automatically rotated?
- Is the authority source clear for sensitive actions?
- Can we revoke its access quickly?
- Are authorization decisions enforced outside the model?
- Do high-impact actions receive the required oversight?
These checks reflect the collection’s identity-lifecycle guidance and OWASP’s authorization and oversight controls.
The takeaway
An AI agent is not just a model connected to tools. It is an actor using authority.
Treating it as a production principal means making that authority explicit, bounded, attributable, owned, and revocable.
Start there - not with the API key.
In the next article, we will draw the identity and authorization architecture in more detail: the human, the agent, the tools, the protected resources, and the decisions between them.
