A blog post could run commands on your laptop through MCP Inspector. What localhost doesn't protect
This is the request Oligo Security used to show CVE-2025-49596: http://0.0.0.0:6277/sse?transportType=stdio&command=touch&args=%2Ftmp%2Fexploited-from-the-browser Port 6277 is where MCP Inspector's proxy listened. Inspector is the official tool for poking at an MCP server while you build it: a web UI on one port, and a proxy on another that connects to your server. transportType=stdio told the…
This CVE concerns a security flaw in MCP Inspector, a local proxy tool. The vulnerability, CVE-2025-49596, lets attackers run processes on your laptop through the proxy. MCP Inspector runs a web UI and a proxy on different ports, with the proxy listening on port 6277 by default. The proxy doesn't require a token before version 0.14.1, so attackers could start any process they wanted with just a GET request from a webpage.
The attacker would have to trick a victim into visiting a specially crafted webpage, which would send a request to the attacker's server through the proxy. The proxy would then execute the specified process on the victim's machine, giving the attacker control. This vulnerability highlights the risk of using localhost (0.0.0.0) as a security boundary, as it grants access to all interfaces, not just the local machine.
MCP Inspector patched the issue in version 0.14.1, implementing two security checks: a random session token for each launch and an allow-list for the Origin header. The token prevents unauthorized access, and the Origin check ensures that requests come from the same origin as the proxy. Despite these improvements, the fix was released over a year after the vulnerability was disclosed.
Two gaps in the fix were discovered later: DNS rebinding and the lack of Origin check on the Host header. The DNS rebinding attack uses a domain that first resolves to the attacker's server, then to 127.0.0.1, allowing the browser to treat the attacker's page and the local port as the same site. The Host header check was also missing, allowing attackers to read stored OAuth tokens and local client config.
The current default configuration of MCP Inspector binds to 127.0.0.1, generates a token per launch, and checks Origin and Host headers. However, settings like DANGEROUSLY_OMIT_AUTH and DANGEROUSLY_BIND_ALL_INTERFACES can bypass these security measures. It's essential to review all processes running on your machine and ensure they are secure, especially those that open ports or handle sensitive data.
Rewritten by urgent.news; may contain errors — check the original.
Source: dev.to