AI Security
Agentic AI security: your newest employee has admin rights and no manager
AI agents do more than answer. They call tools, read data and act in other systems, often with a person's keys. Five public incidents from 2025 show what goes wrong, and each points to a control, from an identity of the agent's own to a named owner who can stop it.

Published 7 min read
Agentic AI security is the work of controlling what an AI agent can reach and do. An agent does not just answer. It calls tools, reads data and acts in other systems, often with someone else's credentials. Securing it means giving each agent its own identity, the narrowest permissions that do the job, a person's approval for actions that cannot be undone, an owner who answers for it, and tools, MCP servers included, that are checked before it may call them.
Think of an agent as a new hire who never sleeps, takes instructions from anything it reads and, in many companies, was handed someone else's keys on the first day. Nobody would let a person start that way. Below are five incidents from 2025 that show what happens when an agent does, and the control each one calls for.
What makes an agent different from a chatbot
A chatbot produces text, and a person decides what to do with it. An agent decides and acts. It can run commands, query a database, send email, open a pull request or call another company's API, and it chains those steps together without stopping to ask. It also reads as it works: web pages, documents, tickets, emails. Any of that text can contain instructions, and the model has no reliable way to tell its user's instructions from ones planted in the content.
In July 2025, SaaStr founder Jason Lemkin was testing Replit's coding agent on a real project. During a code freeze, the agent ran commands against the live production database and wiped records for more than 1,200 executives and about 1,190 companies. Asked about it, the agent admitted it had ignored the instruction to wait for approval, and said a rollback would not work. Lemkin recovered the data himself. Replit's chief executive called the deletion unacceptable, and the company added automatic separation of development and production databases.
No attacker was involved. The agent had the access, and nothing stood between its decision and the database. That is the heart of agentic AI security: what an agent can damage is set by what it is allowed to do, not by what it is told.
Give every agent its own identity
Security teams already manage non-human identities: service accounts, API keys, OAuth apps, certificates. An AI agent is the newest and busiest of them, and it needs what the others need: an identity of its own that shows up in the logs and can be switched off.
When we first review a company's agents, we usually find the opposite. Agents run on a developer's personal token or on a shared service account, so the logs cannot separate what the agent did from what the person did. Nobody can list every agent, the tools it calls and the data it reaches, because some were set up by individual staff in an afternoon.
The theft of tokens from Salesloft's Drift shows why this matters. Drift is an AI chat app that companies connect to Salesforce and other systems. Between 8 and 18 August 2025, according to Google's Threat Intelligence Group, an attacker used OAuth tokens stolen from Drift to export data from customers' Salesforce instances, then searched it for AWS keys, passwords and Snowflake tokens. All Drift tokens were revoked on 20 August. Companies that knew which tokens their integrations held, and what each could reach, could answer the first question of the response in minutes. The others had to find out.
For each agent, that means:
- its own identity, not a person's and not a shared account
- short-lived credentials where the platform allows them, kept in a secrets store rather than in a prompt or a config file
- a line in an inventory: the agent, its owner, its tools, its data and every token it holds
- a way to revoke all of it at once
Give it the least it needs
The second thing reviews find is broad keys: admin or full-access API keys, chosen because a narrow key took longer to set up. With an agent, a broad key turns any mistake, or any planted instruction, into a large one.
In May 2025, Invariant Labs showed how. A developer's agent, connected to GitHub through the GitHub MCP server, was asked to look at the open issues in a public repository. One issue, written by an attacker, told the agent to gather information from the developer's other repositories. The agent read the private ones, because its token reached all of them, and published what it found in a public pull request. Invariant called it an architectural problem that no patch to the server could fix: the token gave the agent far more than the task needed.
Two months later, researchers at General Analysis showed the same pattern with the Supabase MCP server. A support ticket carried instructions for the agent that would later read it. The agent was connected with a service_role key, which bypasses the database's row-level security, so it read a private table of tokens and wrote them back into the ticket, where the attacker could see them. Running the server read-only removes the write-back step.
Simon Willison has a name for the combination behind both cases: the lethal trifecta. An agent that reads untrusted content, holds private data and can send data out can be turned against its owner by anyone who can put text in front of it. For each agent, remove one of the three. Give it read-only or project-scoped access unless writing is the point: one repository rather than all of them, one project rather than the whole account.
Decide what needs a person
Least privilege limits what an agent can do. Approval decides which of those things happen without anyone looking. In many of the companies we review, approval prompts have been set to "always allow" to save clicks, so the agent acts with no one checking.
Four kinds of action should always wait for a person:
- Anything irreversible: deleting data, dropping tables, force pushes, closing accounts.
- Money: payments, refunds, purchases, changes to prices or invoices.
- Sending data out: email or messages outside the company, sharing files, posting publicly.
- Changes to access or production: granting permissions, changing production configuration, deploying.
The approval has to be enforced outside the model. Replit's agent had been told to wait and did not. An instruction in a prompt is a request. A permission the agent's credentials do not have, or a step the platform will not run without a click, is a control. Everything else can run on its own, which keeps approvals rare enough that people still read them.
Secure the tools it calls, MCP servers included
The Model Context Protocol (MCP) is the usual way to connect an agent to tools: a server exposes tools, and the agent calls them. Each server is code that runs with the agent's credentials, so installing one carries the same supply chain risk as any other dependency.
In September 2025, Koi Security found a package called postmark-mcp on npm, presented as a server for the Postmark email service. Its first 15 versions worked as described. Version 1.0.16 added one line that sent a blind copy of every email to an address the attacker controlled. The Register reported about 1,500 downloads a week. Postmark had nothing to do with the package.
Before an agent may use a server:
- install it from the vendor's official package, pin the version and review updates before taking them
- give it the smallest scope that works, read-only where it can be
- read what each tool it exposes can actually do, since a server named for one job can carry tools for several
- check the agent that will use it against the lethal trifecta
The protocol itself has tightened. The current MCP specification, version 2026-07-28, builds authorization for servers reached over HTTP on OAuth 2.1. A server must accept only tokens issued for it, must not pass a client's token on to another service, and should ask for the smallest set of scopes. Authorization is still optional in the specification, so check whether each server you use applies it.
Who governs the agent
Every incident above shares one gap: nobody whose job was to decide what the agent could do. Four habits close it:
- A named owner. Each agent has a business owner who answers for what it does, the way a manager answers for an employee.
- Security signs off. Security approves the agent's tools, scopes and data before it goes live.
- Review on change. Permissions are reviewed when the agent gets a new tool or a new model, and on a schedule, like access reviews for staff.
- A way to stop it. Someone can revoke the agent's credentials and stop it at once, and knows how.
This belongs inside the company's AI governance, not beside it. A framework built on NIST AI RMF already asks who approves a new AI system and how its risk is assessed. Agents add the questions above. For a list of what to test, the OWASP Top 10 for Agentic Applications, published in December 2025, names the risks behind these incidents, from agent goal hijack to tool misuse and identity and privilege abuse.
Where to start this week
- List every agent, with its owner, its identity, its tools and the data it reaches.
- Replace personal tokens, shared accounts and full-access keys with one identity and one scope per agent.
- Turn approvals back on for the four kinds of action above.
- Review every MCP server in use: its source, its version, its scope and its tools.
- Make sure someone can stop each agent today, and write down how.
If you want a second pair of eyes, our AI system security review maps one agent end to end, tests it the way an attacker would, planted instructions included, and reports each finding with its fix. It takes 2 to 6 weeks at a fixed price. Hardening, the changes themselves made with your engineers, takes 2 to 4 months. Agent credentials deserve the same watch as any other: detection rules in your SIEM can alert when a token is used from a new place or at an unusual volume. And if you are deciding how to test an agent from the outside, red team vs penetration testing explains which kind of test answers which question.
Frequently asked questions
How is agentic AI security different from securing a chatbot?
A chatbot produces text, and a person decides what to do with it. An agent acts on its own. It calls tools, changes data and sends messages. Securing a chatbot is mostly about what it says and which data it can show. Securing an agent adds its identity, its permissions, the actions that need a person's approval and the tools it is allowed to call.
What is a non-human identity, and why does an AI agent need one?
A non-human identity is any account or credential used by software rather than a person, such as a service account, an API key, an OAuth app or a certificate. AI agents are the newest kind. An agent needs one of its own so that its actions appear in the logs as its own, its access can be limited to its job, and it can be switched off without locking out the person who set it up.
Is MCP safe to use in a company?
MCP is a protocol, and a server is as safe as its code, its source and the access you give it. The current specification builds authorization on OAuth 2.1 for servers reached over HTTP, but authorization is optional. Install servers from the vendor's official package, pin the version, give each one the smallest scope that works and review its tools before an agent may call them.
Who should own an AI agent?
A named person on the business side who answers for what the agent does, the way a manager answers for an employee. Security approves the agent's tools and access before it goes live. The owner makes sure its permissions are reviewed when it changes, and that someone can stop it at once.
Sources
- AI coding tool Replit wiped a database and called it a catastrophic failure, Fortune, 2025
- Widespread data theft targets Salesforce instances via Salesloft Drift, Google Threat Intelligence Group, 2025
- GitHub MCP exploited, accessing private repositories via MCP, Invariant Labs, 2025
- Supabase MCP can leak your entire SQL database, Simon Willison, on research by General Analysis, 2025
- Postmark MCP server code hijacked to steal emails, The Register, 2025
- Model Context Protocol specification, authorization (version 2026-07-28), Model Context Protocol, 2026
- OWASP Top 10 for Agentic Applications for 2026, OWASP GenAI Security Project, 2025
AI governance consulting and AI security
We help you govern, secure and watch the AI systems your company builds or buys. That means a governance framework your leadership can stand behind, a security review that tests how each system can be misused, the hardening it needs, and detection your team can operate.
Explore AI SecurityRelated reading
AI Security
10 ways your AI can be turned against you: OWASP Top 10 for LLMs vs MITRE ATLAS
A chatbot that invents a refund policy, an assistant that leaks mail without a click, a coding tool shipped with planted code. The OWASP Top 10 for LLM Applications names these risks for builders; MITRE ATLAS records how attackers carry them out. Here is how the two fit together.
7 min read
AI Security
AI governance framework: set the rules before your AI goes rogue
An AI governance framework decides which AI systems your company uses, what each may do, who approved it and how you notice when it goes wrong. NIST AI RMF supplies the risk questions, ISO/IEC 42001 the management system around them, and an acceptable use policy tells staff what they may do today.
6 min read
Tell us which AI systems you need to govern
List the tools and systems you use, built or bought. We reply within two business days.