Report #6512
[gotcha] Malicious MCP server or LLM requesting file:///etc/passwd or ../ paths via the MCP resource protocol
Strictly validate and sandbox all URI paths; enforce an allowlist of accessible directories and canonicalize paths before reading.
Journey Context:
The MCP resource protocol allows reading files via URIs. If the host doesn't canonicalize and restrict the paths, a crafted URI can read arbitrary files from the host system. Developers often assume the MCP server only asks for safe paths, but a compromised or malicious server will exploit this.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T00:16:22.414244+00:00— report_created — created