Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessNetwork access to code-mcp service
-
DeliveryCraft path traversal payload (../ or absolute path)
-
ExploitSubmit path to MCP File Handler
-
Executionis_safe_path function fails to validate
-
PersistAccess unauthorized file
-
ImpactRead or modify sensitive data
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V5 - File Handling Path canonicalization, traversal prevention
MITRE ATT&CK
2 techniques across 2 tactics: Discovery, Collection The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Remote unauthenticated attackers can exploit this vulnerability against default configurations of code-mcp. The attack requires the MCP File Handler component (src/code_mcp/server.py) to be active and accessible over the network; no special configuration or authentication is required (PR:N/UI:N per CVSS vector). The vulnerability is triggered by submitting a path traversal payload in file path parameters to the handler. No user interaction is needed. Exploitation is limited only by file system permissions on the host running code-mcp-the attacker can read or write files that the code-mcp process has access to. If code-mcp runs with elevated privileges, the impact increases significantly. |
| Impact | The CVSS v4.0 vector (AV:N/AC:L/AT:N/PR:N/UI:N) indicates network-accessible, low-complexity remote exploitation against unauthenticated users with no user interaction required, representing baseline attack feasibility. The base score of 5.5 is moderate, with limited impact across confidentiality, integrity, and availability (VC:L/VI:L/VA:L). However, the E:P (exploitability=public) tag confirms publicly available exploit code, elevating practical risk beyond the numerical score. The absence of CISA KEV listing and no mention of active exploitation in the wild suggest this is not yet widely exploited despite public POC availability-a pattern typical of newly disclosed vulnerabilities in niche tools. The rolling-release model creates ambiguity: defenders cannot easily determine if their deployed version is patched because the project has no released fix version to target. The vendor's lack of response to early disclosure is a negative signal for timely remediation. Real-world priority depends on deployment scope: organizations using code-mcp for file serving or document access should treat this as medium-priority due to easy exploitability; those using it in isolated development environments or with network-level access controls face lower risk. The limited scope impact (SC:N/SI:N/SA:N) suggests the vulnerability does not propagate across system boundaries. |
| Exploit ScenarioDerived | An attacker sends a remote HTTP or network request to the code-mcp service with a crafted file path containing directory traversal sequences (e.g., ../../../../etc/passwd or absolute paths like /etc/passwd) to the MCP File Handler endpoint. The is_safe_path function fails to properly sanitize the input, allowing the attacker to access files outside the intended directory. The server returns the file contents or allows read/write operations on sensitive files, compromising confidentiality or integrity. Publicly available exploit code in the GitHub issue demonstrates this technique. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – May 05, 2026
Path traversal vulnerability in 54yyyu code-mcp's MCP File Handler (function is_safe_path in src/code_mcp/server.py) allows remote unauthenticated attackers to access files outside intended directories with low confidentiality, integrity, and availability impact. Publicly available exploit code exists; the project uses rolling releases without versioned releases, and the vendor has not yet responded to early disclosure.
RemediationAI
Immediate action: upgrade code-mcp to a version released after commit 4cfc4643541a110c906d93635b391bf7e357f4a8. Since the project uses rolling releases without version tags, monitor the GitHub repository (https://github.com/54yyyu/code-mcp/) for commits that address the path traversal in is_safe_path or pull requests closing issue #4 (https://github.com/54yyyu/code-mcp/issues/4). Pending a vendor fix, implement compensating controls: restrict network access to the code-mcp service using firewall rules or reverse-proxy authentication (trade-off: reduces usability if remote access is required); disable or remove the MCP File Handler component if not essential to your workflow; or run code-mcp in a sandboxed environment (chroot, container, or VM) with read-only mount of the filesystem (trade-off: limits functionality). The vulnerability is in path validation logic, so patching or code review should focus on hardening the is_safe_path function to prevent .. sequences and absolute path bypass.
Affected VersionsENISA
Affects your stack
Find out whether the stacks and servers you run are on an affected version.
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
The vulnerability exists in the is_safe_path function of the MCP File Handler component in code-mcp, which is responsible for validating file paths before operations. The flaw is classified as CWE-22 (Improper Limitation of a Pathname to a Restricted Directory, also known as path traversal). This occurs when user-supplied path input is not properly canonicalized or validated, allowing attackers to use directory traversal sequences (such as ../ or absolute paths) to reference files outside the intended base directory. The affected product uses a rolling release model without discrete version tagging, making version identification difficult; the vulnerability is present up to commit 4cfc4643541a110c906d93635b391bf7e357f4a8 in the 54yyyu/code-mcp repository.
Know when Code Mcp gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N/E:P
Primary rating from Vendor (VulDB) · only source for this CVE.
CVSS VectorVendor: VulDB
Lifecycle Timeline
2DescriptionCVE.org
A vulnerability has been found in 54yyyu code-mcp up to 4cfc4643541a110c906d93635b391bf7e357f4a8. The affected element is the function is_safe_path of the file src/code_mcp/server.py of the component MCP File Handler. Such manipulation leads to path traversal. It is possible to launch the attack remotely. The exploit has been disclosed to the public and may be used. This product takes the approach of rolling releases to provide continious delivery. Therefore, version details for affected and updated releases are not available. The project was informed of the problem early through an issue report but has not responded yet.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Path traversal exploits occur when applications use user-controlled input to construct file system paths without proper validation.
EUVD-2026-27215
NVD
CVE.org
EPSS
Vulnrichment
GitHub
VulDB
Exploit-DB