Report #85356
[gotcha] Allowing unbounded recursive tool calls or infinite agentic loops
Enforce hard limits on the maximum number of tool calls per session or per user turn, and implement timeouts for tool execution. Break the loop if the agent repeats the same tool call with identical arguments.
Journey Context:
LLMs can get stuck in loops, especially when a tool returns an error and the LLM retries the exact same flawed logic. Without a circuit breaker, an attacker can craft a prompt that forces the agent to burn through thousands of dollars of API credits or overwhelm the MCP server. Hard limits and duplicate call detection are essential guardrails.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T01:51:18.587615+00:00— report_created — created