Overthinking Loops in Agents: A Structural Risk via MCP Tools
AI 摘要
恶意MCP工具可诱导LLM Agent产生过度思考循环,造成资源浪费和任务性能下降。
主要贡献
- 揭示了tool-using LLM agents中的供应链攻击风险。
- 提出了结构性过度思考攻击的概念。
- 实现了多种恶意工具来触发过度思考循环。
- 验证了解码时的简洁控制无法有效防止循环。
方法论
通过设计恶意MCP工具,并在多种工具型LLM上进行实验,评估攻击的影响。
原文摘要
Tool-using LLM agents increasingly coordinate real workloads by selecting and chaining third-party tools based on text-visible metadata such as tool names, descriptions, and return messages. We show that this convenience creates a supply-chain attack surface: a malicious MCP tool server can be co-registered alongside normal tools and induce overthinking loops, where individually trivial or plausible tool calls compose into cyclic trajectories that inflate end-to-end tokens and latency without any single step looking abnormal. We formalize this as a structural overthinking attack, distinguishable from token-level verbosity, and implement 14 malicious tools across three servers that trigger repetition, forced refinement, and distraction. Across heterogeneous registries and multiple tool-capable models, the attack causes severe resource amplification (up to $142.4\times$ tokens) and can degrade task outcomes. Finally, we find that decoding-time concision controls do not reliably prevent loop induction, suggesting defenses should reason about tool-call structure rather than tokens alone.