Skip to content
IAM Insights

Briefing · Paper · source · updated · Boston Identity

Tool poisoning runs through calls an agent is allowed to make; MindGuard looks for it in the model's attention

Researchers at the University of Science and Technology of China, Beihang University and Ocean University of China propose MindGuard, a guardrail that reads an agent model's attention to see which tool description drove each MCP tool call. In the August 2025 version it caught most poisoned calls on the MCPTox benchmark and named the poisoned tool almost every time, though its false-alarm rate depends on a threshold the operator sets. It only works where someone can see inside the model.

arXiv · Zhiqiang Wang, Haohua Du, Xiang-Yang Li · August 28, 2025 · read

share
4 findings6 sectionsAgentic identity
14,140 words. With Zhiqiang Wang, author.
01

What's happening

Finding4
BI-FIND-2025-0402Lead finding

In Wang and co-authors' account, instructions hidden in one MCP tool's description lead the agent to make unauthorized calls through tools it is allowed to use.

Wang and co-authors treat MCP tool poisoning as a confused-deputy attack: instructions hidden in one tool's description lead the agent to make "legitimate but unauthorized tool calls" to other tools, such as reading SSH keys or redirecting an email, and the poisoned tool itself never runs. They leave its execution out of scope because permission systems would catch it, so the harm comes through tools the agent is allowed to use. In their CaMeL case study, the rule that an email recipient must come from the user still passes: the poisoned description sat in the trusted planner's context, and CaMeL tags any literal value written into the plan as coming from the user.

Figure steps
  1. A malicious MCP server's Tool-A2 description sits in the planner's context next to the user's request to send an email.
  2. The planner writes an ordinary email call with the attacker's address as the recipient.
  3. The rule that recipients must come from the user passes, because CaMeL tags any literal value its trusted planner writes into the plan as coming from the user.
  4. The honest email tool sends the message to the attacker; Tool-A2 itself is never called.
  5. MindGuard reads the planner's attention, traces the recipient back to Tool-A2's description and blocks the call before it runs.
Fig. 1

A poisoned tool description sets the email's recipient, which CaMeL's check passes and MindGuard blocks.

Drawn from the paper's CaMeL case study (figure 14, first version)Source dated August 28, 2025Passage: Section 4

BI-FIND-2025-0404

MindGuard needs the model's internal attention, so it runs only where the model runs, such as at the model provider or on a self-hosted open-weight model.

MindGuard needs the model's internal attention, so it runs only where the model runs. The authors name two settings: providers of proprietary models offering it as an added security service, with Claude Desktop as their example, and organisations that host open-weight models themselves. We read that as ruling it out for an enterprise that reaches a hosted model through an API and sees only its output. The authors also count on that attention staying private. Their answer to an attacker who crafts a payload to draw little attention is an argument they call "a heuristic, not a formal proof", and this version runs no such attack.

high confidencebest source: independent researchobserved Aug 2025EvidenceTool poisoning as a confused-deputy attackAdaptive attacks argued, not tested
flag a problem with BI-FIND-2025-0404
BI-FIND-2025-0403

On MCPTox, MindGuard flagged poisoned tool calls from the model's attention at 81.6% to 98.1% average precision when harmless cases also held a poisoned tool.

MindGuard reads the agent model's own attention to judge which parts of the context drove a tool call, and flags the call when an uninvoked tool's description weighs too heavily against the user's query and the called tool's own description. On MCPTox, across seven open-weight model setups, its average precision ran from 81.6% to 98.1% when the harmless cases also held a poisoned tool, and from 94.4% to 99.4% against a clean set; the abstract's "94%-99%" matches the clean-set column. When it caught an attack, it named the poisoned tool 95.5% to 100% of the time. Those averages hide the operating point: the authors leave the threshold to the operator. On MCPTox, Qwen3-8B with and without chain-of-thought flagged 30.0% and 38.9% of harmless calls at threshold 0.3 and 7.1% and 13.1% at 0.5, while the share of attacks caught fell from 98.6% and 100% to 95.1% and 97.1% (Table V).

medium confidencebest source: independent researchobserved Aug 2025EvidenceSection 2Detection and attribution on MCPTox
flag a problem with BI-FIND-2025-0403
BI-FIND-2025-0405

In the authors' test on three model setups, four adapted defenses missed most poisoned calls or flagged many normal ones, while MindGuard caught most attacks.

In the authors' comparison on three model setups, the four defenses they adapted to tool poisoning (MCIP, an LLM-based injection detector, Attention Tracker and MELON) either missed most poisoned calls or flagged many normal ones, while MindGuard caught most attacks with few false alarms. The text says MindGuard beat them on every metric, but the paper's own chart shows MELON with fewer false alarms on two of the three setups, while catching at most about half the attacks. CaMeL and IsolateGPT were left out because they assume the planner's context is trusted. MindGuard added 0.1 to 1.8 seconds per call and no tokens, where the LLM detector and MELON each spent more than 1,000.

medium confidencebest source: independent researchobserved Aug 2025EvidenceSection 4
flag a problem with BI-FIND-2025-0405
02

Section by section

6

showing 6 of 6

[1]

Tool poisoning as a confused-deputy attack

Zhiqiang Wang

Agentic identity

Wang and co-authors define the Tool Poisoning Attack: a malicious MCP server registers a tool whose description carries instructions, and a harmless request then leads the agent to call a different, legitimate tool, such as reading SSH keys or sending email to the attacker. The poisoned tool never runs. The authors leave its execution out of scope because permission systems would catch it, and they assume the defender can read the model's attention.

technical artifactfrom published text

[2]

Decision Dependence Graph and the Anomaly Influence Ratio

Zhiqiang Wang

MindGuard turns the model's attention into a Decision Dependence Graph. Its vertices are the user query, each tool's description, and the tool name and arguments the model generates; edge weights are Total Attention Energy, the sum of squared attention scores after a two-stage attention-sink filter. A call is flagged when an uninvoked tool's weight, relative to the query plus the invoked tool's own description, passes one threshold, and that tool is named as the source.

technical artifactfrom published text

[3]

Detection and attribution on MCPTox

Zhiqiang Wang

The test set is MCPTox plus clean ToolACE cases, across seven open-weight setups: Qwen3-8B and 14B with and without chain-of-thought, Phi-4, Mistral-7B and Gemma2-9B. Detection average precision is 81.6 to 98.1 when harmless cases still hold a poisoned tool, and 94.4 to 99.4 against the clean set (Table IV). Attribution accuracy is 95.5 to 100. The operator sets the threshold: on Qwen3-8B, 0.3 catches every attack but flags 38.9% of harmless calls, and 0.9 catches 91.2% at 0.9% (Table V).

technical artifactfrom published text

[4]

Comparison with other defenses, cost, and the CaMeL case

Zhiqiang Wang

Against MCIP, an LLM-based detector, Attention Tracker and MELON on three setups (Fig. 13), MindGuard sits at high detection and few false alarms; MELON has fewer false alarms on two setups but catches at most about half the attacks. CaMeL and IsolateGPT are left out because they assume a trusted planning context. MindGuard adds 0.1 to 1.8 seconds and no tokens (Fig. 7). In a worked case (Fig. 14), CaMeL's recipient rule passes a poisoned plan that MindGuard blocks.

technical artifactfrom published text + figures

[5]

Ablations, filter settings and tool count

Zhiqiang Wang

Removing the attention-sink filter hurts most: average precision on Qwen3-8B falls from 0.93 to 0.57. In the same curves a one-stage filter takes it to 0.83, though the text calls that a 36% drop, and merging tool name and arguments into one vertex takes it to 0.86. The filter holds for k from 25 to 200 and entropy thresholds above 0.7 (Fig. 12). The authors say adding registered tools does not degrade detection (Fig. 10).

technical artifactfrom published text

[6]

Adaptive attacks argued, not tested

Zhiqiang Wang

The authors argue that an attention-minimisation attack, a payload that steers the call while drawing little attention, runs against how attention works; they call this a heuristic, not a formal proof. They add that the main users, providers of closed models, keep attention private, so attackers cannot easily craft such payloads. This version runs no adaptive attack. Multi-turn attacks such as return-oriented programming chains are left for future work.

technical artifactfrom published text

Terms used

Model Context Protocol
Model Context Protocol: an open standard, originated by Anthropic, for connecting AI assistants to tools and data.
MCPTox
Research benchmark testing whether malicious instructions in MCP tool descriptions can redirect an agent through legitimate tools.
Tool poisoning
Hiding malicious instructions in the description or parameters of a tool an AI agent can call, so the model is steered into leaking data or taking actions its user never intended.
SSH
The protocol administrators and automated jobs use to log in to servers; its long-lived keys are a common unmanaged machine credential.
CaMeL
Research system that tracks data provenance within one agent run to keep untrusted content from steering privileged actions.
Open-weights model
An AI model whose trained parameters are published for download and local use, so its developer cannot monitor or restrict how it is used or strip safeguards after release.
Chain of thought
A model's written-out reasoning steps, produced before its answer or action; the text that chain-of-thought monitoring reads.
Claude Desktop
Anthropic desktop host app for MCP servers.

Read next

Was this briefing useful?

Share this briefing

Every finding, forecast and open question on this site has a permanent ID. If we reword one, its ID stays the same, so a citation keeps pointing to the same claim.

Follow us on LinkedInRSS feed

Working on an identity problem this research touches? Talk to Boston Identity