Report #45964
[gotcha] LLM executing malicious actions via injected tool calls
Validate and sanitize all arguments generated by the LLM for function/tool calls before execution. Never trust the LLM's output for tool arguments implicitly, especially paths, URLs, or SQL queries.
Journey Context:
When LLMs are given tool-use capabilities, an indirect prompt injection can instruct the LLM to invoke a tool with malicious arguments \(e.g., deleting a file, sending an email to an attacker\). Developers often assume the LLM will only call tools based on the user's explicit request, but injected instructions can hijack the tool-calling mechanism. The tool execution environment must enforce strict access controls and input validation.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T07:37:40.896580+00:00— report_created — created