AI Security Maturity Model·AWS v1.0.0

Drag to explore · pinch to zoom

Enhanced Identity and Access ManagementDefense-in-depth layer: Identity & Data Capability 5 · Generative AI agentsUse case: AI that acts 👤 CustomerAWS Shared Responsibility Model: who implements and operates this control. Customer = you own it; AWS = AWS operates it and you inherit it; Shared = both have obligations.

c5.4 Grant agents least-privilege roles with no escalation path

Scope each agent's IAM role to only the tools, resources, and secrets it needs, so a compromised or manipulated agent cannot escalate through unintended tool combinations.

Foundational
Enhanced
Advanced
Effort: Medium Impact: High GenAI scopesFrom the AWS Generative AI Security Scoping Matrix.: 3 · Pre-trained models; 4 · Fine-tuned models Agentic security dimensionsFrom the AWS Agentic AI Security Scoping Matrix.: Identity, Operational boundaries

Implementation guidance

How to implement on AWS

Assign AgentCore Runtime agents IAM roles with minimum permissions, scoped to specific tools/resources/secrets. Centralize tool access through AgentCore Gateway with a separate identity store for agents (OAuth Client Credentials), store client IDs/secrets in Secrets Manager, and scope outbound authorization (SigV4/OAuth scopes) to only the tools each agent may invoke. Authorize each tool call with AgentCore Policy (Cedar) at the gateway, which denies by default.

An autonomous agent inherits its role's reach

An agent acts on your behalf using its IAM role. If that role is broad — or, worse, holds permissions that let it change its own permissions — a manipulated or compromised agent doesn't just misuse what it has; it can escalate to more. Scope the role to only the tools, resources, and secrets the agent needs, and explicitly slam the door on the handful of permissions that enable privilege escalation.

Grant only what the agent's task requires

Start from nothing and add the specific actions and resource ARNs the agent uses — the same least-privilege discipline as the model-invoke and tool roles:

{
  "Sid": "AgentTaskPermissions",
  "Effect": "Allow",
  "Action": ["bedrock:InvokeModel", "dynamodb:GetItem"],
  "Resource": [
    "arn:aws:bedrock:us-east-1::foundation-model/anthropic.claude-3-5-sonnet-20240620-v1:0",
    "arn:aws:dynamodb:us-east-1:111122223333:table/AgentState"
  ]
}

Explicitly deny the escalation paths

A short, well-known set of IAM/STS actions turns a limited role into an admin one. Even if they are never granted, an explicit Deny guarantees a widened policy can't reintroduce them:

{
  "Sid": "NoPrivilegeEscalation",
  "Effect": "Deny",
  "Action": [
    "iam:CreatePolicyVersion",
    "iam:SetDefaultPolicyVersion",
    "iam:AttachRolePolicy",
    "iam:PutRolePolicy",
    "iam:AttachUserPolicy",
    "iam:CreateAccessKey",
    "iam:UpdateAssumeRolePolicy",
    "iam:PassRole"
  ],
  "Resource": "*"
}

iam:PassRole is the classic one — the ability to hand a more powerful role to a service the agent can invoke. If the agent legitimately must pass a role, scope the Allow for iam:PassRole to that one role ARN with a Condition on iam:PassedToService, rather than leaving it in the deny.

No self-assumption chains

Keep the agent's trust relationships tight so it cannot assume a broader role. Combine an explicit deny (or a scoped sts:AssumeRole to specific role ARNs) with a permission boundary (see the tool-roles control), so identity policy AND boundary both cap the ceiling.

Naming note: replace the model and table ARNs. If the agent needs iam:PassRole, remove it from the deny and add a narrowly scoped allow instead — do not grant broad PassRole.

Acceptance criteria

Agent roles are least-privilege and scoped; gateway uses a separate agent identity store; OAuth scopes limit which tools each agent invokes; no broad escalation path exists. A tool call with no permitting policy is denied.

Practical implementation

How this control is implemented in each reference architecture:

Each agent in the Generative AI account gets a least-privilege IAM role and reaches tools only through AgentCore Gateway with a separate agent identity store and scoped OAuth.

  1. Assign AgentCore Runtime agents IAM roles with minimum permissions scoped to specific tools, resources, and secrets.
    Generative AI account IAM AgentCore Runtime
  2. Centralize tool access through AgentCore Gateway with a separate agent identity store (OAuth Client Credentials); store client IDs/secrets in Secrets Manager.
    Generative AI account AgentCore Gateway Secrets Manager
  3. Authorize each tool call at the gateway with AgentCore Policy: write Cedar policies that permit each agent identity (IAM or OAuth principal) to call only its own tools. Calls with no matching permit policy are denied by default.
    Generative AI account AgentCore Gateway
  4. Scope outbound authorization (SigV4/OAuth scopes) to only the tools each agent may invoke, leaving no broad escalation path.
    Generative AI account IAM Bedrock AgentCore

How to validate: Agent roles are least-privilege and scoped; the gateway uses a separate agent identity store; OAuth scopes limit which tools each agent invokes; chaining two tools cannot escalate. A tool call with no permitting policy is denied.

Avoid: A powerful shared agent role plus a permissive gateway. Scope the role and the OAuth scopes so tool chaining cannot escalate privilege.

Generative AI OU (multi-account) →

Least-privilege agent roles plus AgentCore Gateway with a separate agent identity store and scoped OAuth keep agents from escalating within the account.

  1. Give each agent an IAM role scoped to only its tools, resources, and secrets.
    Generative AI tier (IAM role) IAM Bedrock AgentCore
  2. Route tool access through AgentCore Gateway with a separate agent identity store; keep client secrets in Secrets Manager.
    Generative AI tier (IAM role) AgentCore Gateway Secrets Manager
  3. Authorize each tool call at the gateway with AgentCore Policy: write Cedar policies that permit each agent identity (IAM or OAuth principal) to call only its own tools. Calls with no matching permit policy are denied by default.
    Generative AI tier (IAM role) AgentCore Gateway
  4. Scope OAuth to only the tools each agent may invoke.
    Generative AI tier (IAM role) IAM Bedrock AgentCore

How to validate: Agent roles are least-privilege; the gateway uses a separate agent identity store; OAuth scopes limit tools; no broad escalation path exists. A tool call with no permitting policy is denied.

Avoid: Reusing the app role for agents. Give agents their own minimal roles and scope their tool access.

Single account (entry point) →

Threats addressed

  • Excessive agency: an agent reaching resources beyond its task.
  • Privilege escalation by chaining tools an agent should not combine.

AWS services

AWS IAM Amazon Bedrock AgentCore Gateway AWS Secrets Manager

Pricing

No additional charge

IAM roles and policies are free; this is a design control with no cost. IAM Access Analyzer (useful to confirm no unused or escalation-capable permissions remain) has no charge for external-access analysis; unused-access analysis is billed per resource analyzed. See Least-privilege permissions.

Framework mappings

OWASP GenAI/LLM Top 10 (2026)

  • LLM03 Excessive Agency

NIST AI Risk Management Framework (AI 100-1)

  • MANAGE.1 AI risks are prioritized, responded to and managed

AWS Security Hub — AI Security Best Practices

  • BedrockAgentCore.2 Bedrock AgentCore Gateways should require authorization for inbound requests

AWS Well-Architected Generative AI Lens (Security)

  • GENSEC05-BP01 Implement least privilege and permission boundaries for agentic workflows

OWASP GenAI Top 10 for Agentic Applications (2025)

  • ASI03 Identity and Privilege Abuse

Learning resources

References

  • AWS SRA for AI — Capability 5, Identity and access management