debugmcp mcp-debugger server.ts handleGetSourceContext path traversal
Description
A vulnerability was identified in debugmcp mcp-debugger up to 0.20.0. Impacted is the function handleGetSourceContext of the file src/server.ts. The manipulation leads to path traversal. The attack is possible to be carried out remotely. The exploit is publicly available and might be used. The vendor was contacted early about this disclosure but did not respond in any way.
AI Insight
LLM-synthesized narrative grounded in this CVE's description and references.
A path traversal vulnerability in debugmcp/mcp-debugger up to 0.20.0 allows remote attackers to read arbitrary files via the handleGetSourceContext function.
Vulnerability
A path traversal vulnerability exists in debugmcp/mcp-debugger through version 0.20.0. The handleGetSourceContext function in src/server.ts accepts a user-controlled file argument. In host mode, resolvePathForRuntime returns the input path unchanged, and no workspace-boundary enforcement is applied before file operations [1]. This allows an attacker to read arbitrary files on the filesystem.
Exploitation
An attacker can send a crafted source-context request to the MCP tool endpoint, supplying an arbitrary file path (e.g., /etc/passwd) as the file parameter. The server validates the session (if any) but then proceeds to check the file existence and read its contents, effectively leaking the file's data to the attacker [1]. No special privileges are required beyond network access to the service.
Impact
Successful exploitation allows an attacker to read arbitrary files from the server filesystem, leading to information disclosure. This can expose sensitive configuration, source code, credentials, or other confidential data.
Mitigation
As of the latest information, the vendor has not responded to disclosure and no patch is available [1]. Users should monitor the repository for updates. Until a fix is released, mitigate by restricting network access to the affected service or implementing input validation to prevent path traversal (e.g., block absolute paths and ../ sequences).
AI Insight generated on May 25, 2026. Synthesized from this CVE's description and the cited reference URLs; citations are validated against the source bundle.
Affected products
2<=0.20.0+ 1 more
- (no CPE)range: <=0.20.0
- (no CPE)range: <=0.20.0
Patches
0No patches discovered yet.
Vulnerability mechanics
AI mechanics synthesis has not run for this CVE yet.
References
4- github.com/hyk6225/public_exp/issues/1mitreexploitissue-tracking
- vuldb.com/submit/813980mitrethird-party-advisory
- vuldb.com/vuln/365448mitrevdb-entrytechnical-description
- vuldb.com/vuln/365448/ctimitresignaturepermissions-required
News mentions
0No linked articles in our index yet.