Excessive agency: how over-provisioned AI agents become insider threats
“We didn’t give the agent those permissions. We forgot to take them away.”
TL;DR
22.2% of public Claude Code permission files let the agent delete files without asking (UpGuard). 88% of organizations in a 2026 Gravitee survey reported confirmed or suspected AI agent security incidents in the past year, and only 21% of organizations in an Akto survey keep a current inventory of what their agents connect to. Over-provisioned agents are insider threats that operate at machine speed. OWASP lists this as LLM06 Excessive Agency in its 2025 Top 10. The 2025 entry also covers the tools, skills and plugins agents use, because the root problem is the same: agents have more power than they need. For how attackers exploit these permissions to escalate further, see The privilege escalation kill chain.

What does OWASP LLM06 actually say?
Excessive Agency occurs when an LLM-based system is granted more power, permissions, or system-level capabilities than its task requires. The 2025 update is significant: Insecure Plugin Design (LLM07 in the 2023 list) no longer has its own entry, and LLM06 now covers extensions directly, which OWASP describes as “tools, skills or plugins”. Insecure plugins and excessive agent permissions are treated as one problem.
The key shift in the 2025 version: it now explicitly addresses agentic systems, not just chatbots. The 2023 version worried about an LLM calling a function it shouldn’t. The 2025 version worries about an autonomous agent chaining tools, pivoting between systems, and escalating privilege without human visibility. The impact spans confidentiality, integrity, and availability depending on what systems the agent can reach.
The OWASP Top 10 for Agentic Applications (2026 edition) takes this further with the “Least Agency” principle: autonomy should match task scope, not capability scope. An agent that CAN read, write, and delete from a database should only be ALLOWED to do what its current task requires. The distinction between capability and permission is where most deployments fail.
How bad is the over-provisioning problem?
Worse than most security teams realize, because the defaults are open and the visibility is poor.
UpGuard analyzed 18,470 Claude Code permission files (.claude/settings.local.json) committed to public GitHub repositories (UpGuard). 22.2% let the agent run rm without asking, so a single prompt injection can delete files with no human in the loop. Nearly 20% let it run git push without asking, which can put unreviewed changes on a shared branch. Academic testing shows how reachable these permissions are: prompt injection made the agents in GitHub Copilot and Cursor execute malicious commands in as many as 84% of attempts (Liu et al., 2025).
OpenAI’s Codex CLI had CVE-2025-61260: versions up to 0.23.0 loaded a repository’s local .env and .codex/config.toml files without asking, so a malicious repository could define MCP server commands that ran as soon as a developer started codex inside it. The agent trusted project configuration that it should have treated as untrusted input.
Vendor surveys point the same way. Treat the exact numbers as directional:
| Metric | Value | Source |
|---|---|---|
| Organizations reporting confirmed or suspected AI agent security incidents in the past year | 88% | Gravitee, 2026 |
| Healthcare organizations reporting such incidents | 92.7% | Gravitee, 2026 |
| Organizations where all agents go live with full security and IT approval | 14.4% | Gravitee, 2026 |
| Executives confident their policies prevent unauthorized agent actions | 82% | Gravitee, 2026 |
| Agents operating without security oversight or logging | More than half | Gravitee, 2026 |
| Enterprises piloting or running early production agent deployments | 69% | Akto, 2025 |
| Organizations with a fully up-to-date inventory of agents, MCP servers, tools and connections | 21% | Akto, 2025 |
Sources: Gravitee, State of AI Agent Security 2026 (900+ executives and practitioners) and Akto, State of Agentic AI Security (100+ security and AI leaders, December 2025).
In Akto’s survey, 69% of enterprises were piloting or running agents in early production, but only 21% kept a complete, current inventory of what those agents connect to. Deployment is running well ahead of visibility.
Why do organizations over-provision?
Three forces push organizations toward excessive agency, and all three are rational in isolation.
Capability pressure. The business wants the agent to do more. Every permission restriction reduces functionality. The agent can’t summarize emails if it can’t read emails. It can’t fix code if it can’t write files. It can’t deploy if it can’t run commands. Each individual permission seems justified. The accumulated set creates an insider threat. Gartner predicted in August 2025 that 40% of enterprise applications would feature task-specific AI agents by the end of 2026, up from less than 5% in 2025. The deployment velocity leaves no time for permission auditing.
UX and developer shortcuts. Granular permission frameworks don’t exist for most agent platforms. The developer’s choice is often binary: grant access or don’t. “Just give it all permissions, it’ll figure it out” is faster than building a scoped permission model from scratch. When the agent works in demo, nobody goes back to tighten permissions before production.
Unclear dev/prod separation. Agents run with developer credentials during testing. Those same credentials get deployed to production because nobody builds a separate identity management system for AI agents. The agent inherits the developer’s full access: production databases, internal APIs, cloud infrastructure. A human developer exercises judgment about which permissions to use. An agent exercises whatever a prompt injection tells it to.
The result: 82% of executives say they are confident their policies protect them from unauthorized agent actions, but only 14.4% of organizations say all their agents go live with full security and IT approval (Gravitee, 2026). Confidence without control.
What does the “supercharged insider threat” look like?
Palo Alto Networks’ 2026 predictions call the AI agent “a potent insider threat”: trusted, always on, and holding privileged access (Palo Alto Networks, November 2025). The framing is accurate: an over-provisioned agent that gets hijacked through prompt injection or tool misuse becomes an autonomous insider operating at machine speed.
The difference between a compromised human and a compromised agent:
A human insider might run 5 database queries in an afternoon. An agent issues thousands per second. A human insider might exfiltrate files one at a time over weeks. An agent can enumerate and exfiltrate an entire document store in minutes. A human insider creates audit trails through login times, badge access, and behavioral patterns. An agent’s actions look identical to its normal operations.
Johann Rehberger’s research on Devin demonstrated this precisely. He reported the issues to Cognition on 6 April 2025 and published them in August 2025 as part of his Month of AI Bugs series, after follow-up questions about a fix had gone unanswered for more than 120 days. Starting from indirect prompt injection in a GitHub issue that Devin was asked to investigate, he got Devin to download and run malware that connected back to a command-and-control server, and to paste Jira and Slack tokens into a third-party website and send environment variables out with curl and wget. Devin can also be tasked from Slack, which makes the whole interaction unsupervised. All of this went through legitimate tool access that Devin already had. The agent wasn’t doing anything it couldn’t do. It was doing things it shouldn’t do.
The same Palo Alto Networks predictions put autonomous agents ahead of humans by a ratio of 82:1. Each one of those agents with excessive permissions is a potential insider threat waiting for a trigger.
What does least-privilege agent architecture look like?
graph TB
subgraph "Least-Privilege Architecture"
A[Agent Request] --> B{Permission<br/>Check}
B -->|Allowed| C[Task-Scoped<br/>Token Issued]
B -->|Denied| D[Request Rejected<br/>+ Logged]
C --> E{Action Type}
E -->|Read Only| F[Execute with<br/>Read Token]
E -->|Write/Delete| G{HITL Gate}
E -->|External Comms| H{HITL Gate}
G -->|Approved| I[Execute with<br/>Write Token]
G -->|Denied| D
H -->|Approved| J[Execute with<br/>Scoped Token]
H -->|Denied| D
F --> K[Audit Log]
I --> K
J --> K
end
Start read-only by default. Every agent session begins with read-only access. Write, delete, and execute permissions are granted per-action, not per-session. This is the single most impactful change organizations can make.
Use task-scoped tokens. AWS’s Agentic AI Security Scoping Matrix defines four scopes: no agency (read-only, human-triggered workflows), prescribed agency (any consequential action needs human approval), supervised agency (the agent plans and acts on its own toward goals a human sets) and full agency (the agent starts work on its own). The further up the scale, the stronger the controls you need. Issue JIT (Just-In-Time) ephemeral credentials valid only for a specific tool and the duration of that single task. Even a compromised agent can’t escalate beyond its current task scope.
Whitelist tools per agent role. A customer service agent needs access to the knowledge base and ticketing system. It doesn’t need database write access, shell execution, or email sending. Define positive lists (what the agent CAN do) rather than negative lists (what it can’t). Negative lists always miss something. Enforce the list outside the model, at the point where tool calls execute; ClawGuard is one research example of that runtime layer.
Implement HITL gates for high-impact actions. Deletes, financial transactions, external communications, and configuration changes require explicit human approval. The gate should show the action, the context, and the justification. This adds latency for sensitive operations but prevents the scenarios where a single injection causes catastrophic damage.
Rate-limit tool calls. An agent making 1,000 database queries per second is either broken or compromised. Set rate limits that reflect legitimate usage patterns. Alert on sustained high-volume tool usage.
Separate credentials per agent. Each agent gets its own identity with its own permissions. Shared credentials mean a compromise of one agent compromises all of them. For how to implement cryptographic agent identity, see Cryptographic capability binding.
Key takeaways
- OWASP LLM06:2025 (Excessive Agency) covers over-provisioned agents and the extensions they use; Insecure Plugin Design no longer has a separate entry
- 22.2% of public Claude Code permission files let the agent delete files without asking (UpGuard); only 14.4% of organizations say all their agents go live with full security approval (Gravitee)
- 88% of organizations in Gravitee’s 2026 survey reported confirmed or suspected AI agent security incidents in the past year
- Over-provisioned agents are insider threats at machine speed: thousands of actions per second through legitimate tool access
- Three forces drive over-provisioning: capability pressure, developer shortcuts, and unclear dev/prod separation
- Least-privilege architecture: start read-only, task-scoped tokens, whitelisted tools, HITL gates for high-impact actions, rate limits, separate credentials per agent
- Only 21% of organizations in Akto’s survey keep a complete, current inventory of their agents and what they connect to. Fix the visibility gap before fixing the permission gap.
FAQ
What is excessive agency in AI systems?
Excessive agency (OWASP LLM06:2025) occurs when an AI agent has more permissions, tools, or system access than its task requires. A coding agent that needs to read files but can also delete them, send network requests, and modify system configs has excessive agency. Prompt injection exploits these unnecessary permissions to cause damage beyond the original task scope.
Why do organizations give AI agents too many permissions?
Three reasons. Capability pressure: business demands fast deployment and broad functionality. UX shortcuts: granting all permissions is faster than scoping them per task. Unclear dev/prod separation: agents run with developer credentials in production. Only 14.4% of organizations say all their agents go live with full security and IT approval (Gravitee, 2026).
What does a least-privilege AI agent architecture look like?
Start every session in read-only mode. Issue task-scoped tokens that expire after each operation. Whitelist specific tools per agent role. Implement HITL gates for deletes, external communications, and financial transactions. Rate-limit tool calls. Separate credentials for each agent. Log every tool invocation.
How many organizations have had AI agent security incidents?
In Gravitee’s 2026 survey of 900+ executives and practitioners, 88% of organizations reported confirmed or suspected AI agent security incidents in the past year; healthcare reached 92.7%. More than half of agents run without security oversight or logging. In Akto’s December 2025 survey, only 21% of organizations kept a fully up-to-date inventory of their agents, MCP servers, tools and connections.