Report #91144
[gotcha] Passing LLM-generated file paths directly to filesystem MCP tools
Canonicalize and validate all file paths resolved by the LLM against a strict allowlist of base directories. Reject paths containing '..' or symlinks pointing outside the sandbox.
Journey Context:
Agents often need to read files. If the LLM is tricked via indirect injection to read '../../etc/passwd', and the MCP tool blindly executes read\_file, it leaks host data. Developers assume the LLM will only ask for project files, but LLMs have no inherent concept of filesystem boundaries.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T11:34:50.677491+00:00— report_created — created