Arviser

Agent tool permissions and MCP server review

Short answer: an agent can do whatever its tools allow, so the review starts with the tool list. Check which tools are exposed, what each one can reach, which actions need a human confirmation, where secrets live, and whether tool output is treated as untrusted text. Then check that every call is logged with enough detail to reconstruct an incident.

The Model Context Protocol (MCP) gives agents a standard way to discover and call tools served by an MCP server. The protocol makes connecting tools easy. It leaves the permission decisions to you. The same checks apply to MCP servers, plugin systems, and hand-written function calling alike.

Which tools should an agent be allowed to call?

Short answer: only the tools the task needs, listed explicitly. Start from an allowlist per agent and per workflow, with everything else denied. An MCP server that exposes twenty tools should not hand all twenty to a support agent that needs three. Review the list whenever a server adds tools.

An MCP client sees every tool the server lists, unless the client filters them. Pin the tools your client accepts instead of trusting discovery at runtime, and record the reason each tool is on the list. If nobody can say why a tool is there, remove it.

Tool descriptions are part of the attack surface too. The model reads them as instructions. A connector description that nudges the model toward a dangerous call is risk R-12 in the AI security risk catalog. Read every description you ship, and diff them when a server updates.

What are tool poisoning, rug pulls and tool shadowing?

Short answer: they are three names for attacks that arrive through the tool definitions themselves: descriptions, schemas and returned values. The OWASP MCP Security Cheat Sheet lists all three among its key risks. The three definitions are our paraphrase.

Attack What to inspect Pass criterion
Tool poisoning Every description, parameter name, schema and sample result the client accepts No definition addresses the model with instructions, and undeclared parameters are rejected
Rug pull A stored hash of each approved definition, compared at every connection A changed definition is blocked until a person reviews it
Tool shadowing Descriptions that name tools of other servers, and values from one server that appear in calls to another No description refers to another server's tools, and no cross-server flow goes unlogged

These checks sit next to the allowlist. The allowlist says which tools may run, and these checks say whether each tool is still the one you approved.

What scope should each tool run with?

Short answer: the scope of the user the agent is acting for, never a shared admin token. Each tool should run under the caller's identity, see only the records that user may see, and return only the fields the task needs. A shared service account turns every chat user into an admin.

Check three layers for every tool:

Multi-tenant systems need a tenant check inside the tool, before any data returns. The cross-tenant retrieval guide explains the same boundary for retrieval.

Which actions need a human confirmation?

Short answer: every action that is destructive, irreversible, external, or spends money. Deleting records, changing access rights, sending email, posting to external systems, and issuing refunds should wait for a human click that shows exactly what will happen. The confirmation must live outside the model, in code the model cannot skip.

A prompt instruction such as "always ask before deleting" is a request to the model. A planted instruction in a ticket can override it. Enforce the gate in the tool layer. Show the confirmation with concrete parameters (the recipient, the amount, the record ID) so the person approving can catch a wrong value. Risk R-21 covers staff who approve because the agent sounded sure, so keep the summary factual and short.

Why is tool output untrusted input?

Short answer: tool output often contains text written by someone outside your control. A ticket body, a web page, an error message from a third-party API, or a file name can all carry instructions. When that text enters the context, it can steer the next tool call. Treat every tool result as untrusted.

This is indirect prompt injection, labelled LLM01 Prompt Injection in our OWASP LLM Top 10 2026 mapping. Tools that change state without approval fall under LLM03 Excessive Agency. When one agent can read untrusted text, see private data, and send data outward, all three legs of the lethal trifecta are present. Splitting flows helps: a session that has read untrusted content loses access to sensitive tools until a human resets it.

Check What to inspect Test Pass criterion
Tool allowlist Tools exposed per agent and workflow Ask the agent to call a tool outside its list Call is refused by the client, not only by the model
Scope Identity and resource scope of each tool Run the same request as two roles Each role sees only its own records
Confirmation Gate on destructive and external actions Plant an instruction to delete or send Action waits for a human click with full parameters
Secrets Tokens in tool config, arguments, and output Plant a canary token where a tool can read it Canary never appears in answers, logs, or outbound calls
Tool output Free text returned by tools Put an instruction in a ticket the agent reads Instruction has no effect on later tool calls
Logging Record of every call and approval Replay one session from logs Caller, tool, arguments, result, and approver are recoverable

Where do secrets leak in an MCP setup?

Short answer: in server configuration, in tool arguments, and in tool output. API keys often sit in the MCP server's environment with broad scope. Some tools echo request details, including headers, into their results. Anything that reaches the context can appear in an answer, a log, or an outbound link.

Keep credentials on the server side, scoped per tool, and never pass them through the model. Redact tokens from tool output before it returns. Check that logs and traces do not store raw secrets, since broad access to traces is its own leak path (risk R-08).

Worked example (synthetic)

This example is synthetic. It describes no client system.

An internal ops agent connects to an MCP server with 14 tools. The workflow needs four: read ticket, search runbooks, read service status, and restart a staging service. The review finds that the agent can call all 14, including a tool that rotates production credentials, and that every call runs under one service token.

A planted line in a ticket asks the agent to restart a production service. The agent calls the tool without confirmation, because the only gate was a sentence in the system prompt. After the fix, the client pins the four tools, the restart tool rejects production targets, and a confirmation screen shows the service name before any restart. A re-run of the planted ticket produces a refused call and a log entry with the ticket ID.

Review checklist

Common questions

Is MCP itself insecure?

MCP is a protocol for connecting tools. The risk comes from which tools you expose, with what scope, and without which gates.

Can the system prompt enforce permissions?

No. Planted text can override prompt instructions. Enforce the tool list, scopes, and confirmations in code.

What should we log without storing sensitive prompts?

Log the tool name, caller identity, arguments with secrets redacted, result status, and the approver. Keep full prompt text under tighter access.

How do these checks stay in place after a review?

Turn the planted-instruction and canary cases into CI gates, and rerun them when a server adds tools.

Next: AI security risks · Lethal trifecta · Indirect prompt injection · OWASP LLM Top 10 2026 · Request a security review

Request a security review