Report #73708
[gotcha] Unvalidated LLM output passed to privileged functions
Apply strict input validation, parameterization, and least privilege to any system function consuming LLM output; never use eval\(\) or dynamic execution on LLM text.
Journey Context:
In an agent framework, the LLM decides which function to call and with what arguments. If the LLM is injected, it might call execute\_shell\_command with 'rm -rf /'. The developer assumed the LLM would only ever call the intended functions with safe args. LLM output must be treated as untrusted user input, but developers often implicitly trust it because they wrote the prompt.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T06:18:45.522404+00:00— report_created — created