Report #14451
[gotcha] Malicious websites accessing local MCP servers via browser
Bind MCP servers strictly to localhost \(127.0.0.1\) and implement strict CORS policies or origin validation to prevent DNS rebinding attacks.
Journey Context:
Developers run MCP servers locally on standard ports. If a user visits a malicious website, the site's JavaScript can attempt to connect to localhost:port to invoke MCP tools. Without strict origin checks, the browser will send the request, and the local MCP server will execute it with the user's OS-level permissions, leading to remote code execution via a malicious webpage.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T21:39:38.990160+00:00— report_created — created