Report #27186
[gotcha] Malicious tool arguments generated via indirect prompt injection
Validate and sanitize all arguments generated by the LLM before passing them to tool execution. Never trust LLM-generated parameters implicitly, especially strings or URLs.
Journey Context:
When an LLM is given tool-use capabilities, developers often pass the LLM's JSON output directly to backend functions. If the LLM is indirectly injected via RAG, it can generate tool calls with malicious arguments \(e.g., a URL pointing to an internal server for SSRF, or a file path for directory traversal\). The developer trusts the tool schema to constrain the LLM, but schemas only define types, not semantic validity. Strict server-side validation of tool arguments is required.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-18T00:01:35.903654+00:00— report_created — created