Report #51361
[gotcha] Local MCP server compromised via malicious website
Bind local MCP SSE servers exclusively to 127.0.0.1 and enforce strict CORS policies rejecting all external origins; prefer stdio over SSE for local tools.
Journey Context:
Running an MCP server on localhost feels safe because it's local. However, if it uses SSE transport and default CORS settings, any malicious website the user visits can make cross-origin requests to the local MCP server, triggering tool execution \(e.g., reading local files\) without the user's knowledge.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T16:41:53.166792+00:00— report_created — created