Skip to content

AAK-MCP-BROWSEMCP-CVE-2026-55557-001: browse-mcp writes fetched content to a caller-controlled path (below 0.8.2)

Severity
HIGH
Category
Supply Chain (supply-chain)
Scanner
agent_audit_kit/scanners/mcp_cve_pins_2026_07.py
Auto-fixable
No.
SARIF name
BrowseMcpPathTraversal

What it detects

browse-mcp, a Playwright-based headless-browser MCP server, before 0.8.2 has browser_download write a fetched response body to join(save_dir, filename) without validating the caller-supplied save_dir, while browser_save_state and browser_load_state honour a caller-supplied path unchanged (CVE-2026-55557). An MCP client -- or an autonomous agent steered by indirect prompt injection, which is the realistic path -- writes outside the intended directory. Fixed in 0.8.2. The pinned artifact is the npm package (That1Drifter/browse-mcp); PyPI carries an unrelated browse-mcp (an academic-paper search server) whose 0.1.x line never approaches this floor.

How to fix

Upgrade browse-mcp to >= 0.8.2 and pin it. For a comparable download tool, resolve the destination and require it to stay under a fixed root (os.path.realpath / Path.resolve() then a containment check) rather than filtering the path string -- and treat the filename as untrusted too.

To confirm the finding is gone, report only this rule:

agent-audit-kit scan . --rules AAK-MCP-BROWSEMCP-CVE-2026-55557-001

Limitations

Reads browse-mcp in requirements*.txt at any depth and, at the project root only, in pyproject.toml, Pipfile, package.json, .mcp.json, mcp.json, claude_desktop_config.json and the Pipfile.lock, poetry.lock, uv.lock, package-lock.json, pnpm-lock.yaml and yarn.lock lockfiles, taking the lowest version a range allows and reporting a reference that states no version. The dependency is not read when it is declared in a sub-directory manifest (packages/app/package.json), in .cursor/mcp.json or .vscode/mcp.json, or in a lockfile format the reader does not parse (a Yarn 2+ yarn.lock). A file over 2 MB, or a lockfile over 32 MiB, is not read. A declaration nested more than 64 levels deep in package.json, a TOML manifest or an MCP config (an MCP server more than 62) is still judged, and reported without a line; a lockfile entry keeps its line at any depth.

References


All rules. This page is generated from the rule registry when the documentation is built; to change it, change the rule in agent_audit_kit/rules/builtin.py. To give the rule a hand-written write-up, add docs/rules/AAK-MCP-BROWSEMCP-CVE-2026-55557-001.md: the page then shows that text, with the registry reference appended under it.