browse-mcp has an arbitrary file write via unconfined download and state paths
CVE-2026-55557 · GHSA-m9mq-7m7q-xc6p · published 2026-08-25
- Severity
- High
- CVSS score
- 8.6
- Chance of exploitation (EPSS)
- 0.24%
- Fixed in
- 0.8.2
- Exploitation No known exploitation
- Automatable No
- Technical impact Total
- CISA SSVC
browserdownload wrote a fetched file to join(savedir, filename) with no validation of savedir, and browsersavestate / browserloadstate honored an explicit path unchanged. The MCP caller controls these arguments (a malicious MCP client, or an autonomous agent steered by indirect prompt injection on a visited page), so an attacker could supply an arbitrary savedir (or state path) together with a URL whose response body became the file contents, writing attacker-controlled bytes to any path the process can reach (for example ~/.bashrc, an autostart entry, or a cron file). That is an arbitrary file write that can lead to host code execution.
Upgrade browse-mcp to 0.8.2 or later. If you start it from an MCP config with npx or uvx, pin that version so an old cached copy is not used.
Fixed in 0.8.2. savedir is confined under the download root (~/.browse-mcp/downloads) and the explicit state path under ~/.browse-mcp/state; absolute paths and .. escapes are rejected, and download filenames are reduced to a bare basename. forcefetch now also honors the origin fence. Data roots remain relocatable via BROWSEMCPHOME. Upgrade to browse-mcp 0.8.2.
Restrict the exposed tools with BROWSEMCPTOOLS to a set that excludes browserdownload, browsersavestate, and browserload_state (for example the hardened recipe in SECURITY.md). Note that the allowlist hides the tools from an agent but does not stop a malicious MCP client from calling them by name, so upgrading is the real fix. Reported privately by novice-22.
| Package | Registry | Affected | Fixed in |
|---|---|---|---|
| browse-mcp | npm | <= 0.8.1 | 0.8.2 |
- CriticalMCP Path Traversal Allows Full-Filesystem Read and JWT Secret Exfiltration Leading to Account Takeoverlangflow, langflow-base
- Critical@zereight/mcp-gitlab: Unauthenticated arbitrary file read via `upload_markdown` enables PAT exfiltration and full account takeover@zereight/mcp-gitlab
- CriticalFlowise RCE via SQL Database Chain Nodeflowise, flowise-components
- CriticalLangroid: SQLChatAgent dangerous-function blocklist can be bypassed with quoted or schema-qualified pg_read_file callslangroid
- Criticalfast-mcp-telegram: Bearer token path traversal bypasses reserved Telegram session protectionfast-mcp-telegram
- CriticalMCP Toolbox HTTP tool path parameters allow traversal to unintended endpointsgithub.com/googleapis/mcp-toolbox
The impact, patch and workaround text comes from the advisory, shortened (GitHub Advisory Database, CC BY 4.0). Proof-of-concept and reproduction sections and code are left out; the original advisory has them.