Skip to main content

code-mcp EUVDEUVD-2026-27215

| CVE-2026-7811 MEDIUM
Path Traversal (CWE-22)
2026-05-05 VulDB
5.5
CVSS 4.0 · Vendor: VulDB
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Network access to code-mcp service
  2. Delivery
    Craft path traversal payload (../ or absolute path)
  3. Exploit
    Submit path to MCP File Handler
  4. Execution
    is_safe_path function fails to validate
  5. Persist
    Access unauthorized file
  6. Impact
    Read 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.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
No patch listed yet 0.0% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – 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

code-mcp 4cfc4643541a110c906d93635b391bf7e357f4a8

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

Vendor (VulDB) PRIMARY 5.5 MEDIUM
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

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
None
Vulnerable system: Confidentiality
Low
Vulnerable system: Integrity
Low
Vulnerable system: Availability
Low
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

2
Severity Changed
May 05, 2026 - 05:22 NVD
HIGH MEDIUM
CVSS changed
May 05, 2026 - 05:22 NVD
7.3 (HIGH) 5.5 (MEDIUM)

DescriptionCVE.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

EPSS Score
0.0%
Top 86% exploitable
Exploit
POC
Public exploit code exists
Social Media
1
Sightings
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment CIRCL GitHub VulDB

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.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC Yes
EPSS 0.0%
Patch available No
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation
Poc
System Exposure· derived
Open
Automatable
Yes
Human Impact· derived
Medium
Technical Impact
Partial

Priority Score

48
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +28
PoC: +20
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Path traversal exploits occur when applications use user-controlled input to construct file system paths without proper validation.

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy