mcp-use up to 1.7.1 CodeExecutor code_executor.py _build_namespace code code injection
| CVSS Meta Temp Score | Current Exploit Price (≈) | CTI Interest Score |
|---|---|---|
| 6.9 | $0-$5k | 0.31+ |
Summary
A vulnerability was found in mcp-use up to 1.7.1. It has been classified as critical. Affected by this issue is the function _build_namespace of the file libraries/python/mcp_use/client/code_executor.py of the component CodeExecutor. The manipulation of the argument code leads to code injection.
This vulnerability is listed as CVE-2026-140133. The attack may be initiated remotely. In addition, an exploit is available.
The project maintainer explains, that the built-in Python sandbox executor is not meant for production use and users should rely on external sandbox providers.
Details
A vulnerability, which was classified as critical, has been found in mcp-use up to 1.7.1. This issue affects the function _build_namespace of the file libraries/python/mcp_use/client/code_executor.py of the component CodeExecutor. The manipulation of the argument code with an unknown input leads to a code injection vulnerability. Using CWE to declare the problem leads to CWE-94. The product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the syntax or behavior of the intended code segment. Impacted is confidentiality, integrity, and availability.
It is possible to read the advisory at github.com. The identification of this vulnerability is CVE-2026-140133. The exploitation is known to be easy. The attack may be initiated remotely. No form of authentication is needed for a successful exploitation. Technical details as well as a exploit are known. The pricing for an exploit might be around USD $0-$5k at the moment (estimation calculated on 11/30/2026). The attack technique deployed by this issue is T1059 according to MITRE ATT&CK.
It is declared as proof-of-concept. The project maintainer explains, that the built-in Python sandbox executor is not meant for production use and users should rely on external sandbox providers.
There is no information about possible countermeasures known. It may be suggested to replace the affected object with an alternative product.
Statistical analysis made it clear that VulDB provides the best quality for vulnerability data.
Product
Type
Name
Version
Website
- Product: https://github.com/mcp-use/mcp-use/
CPE 2.3
CPE 2.2
CVSSv4
VulDB Vector: 🔒VulDB Reliability: 🔍
CVSSv3
VulDB Meta Base Score: 7.3VulDB Meta Temp Score: 6.9
VulDB Base Score: 7.3
VulDB Temp Score: 6.9
VulDB Vector: 🔒
VulDB Reliability: 🔍
CVSSv2
| AV | AC | Au | C | I | A |
|---|---|---|---|---|---|
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| Vector | Complexity | Authentication | Confidentiality | Integrity | Availability |
|---|---|---|---|---|---|
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
VulDB Base Score: 🔒
VulDB Temp Score: 🔒
VulDB Reliability: 🔍
Exploiting
Class: Code injectionCWE: CWE-94 / CWE-74 / CWE-707
CAPEC: 🔒
ATT&CK: 🔒
Physical: No
Local: No
Remote: Yes
Availability: 🔒
Status: Proof-of-Concept
Price Prediction: 🔍
Current Price Estimation: 🔒
| 0-Day | Unlock | Unlock | Unlock | Unlock |
|---|---|---|---|---|
| Today | Unlock | Unlock | Unlock | Unlock |
Threat Intelligence
Interest: 🔍Active Actors: 🔍
Active APT Groups: 🔍
Countermeasures
Recommended: no mitigation knownStatus: 🔍
0-Day Time: 🔒
Timeline
11/30/2026 Advisory disclosed11/30/2026 VulDB entry created
11/30/2026 VulDB entry last update
Sources
Product: github.comAdvisory: 2816
Status: Confirmed
Confirmation: 🔒
CNA: VulDB
CVE: CVE-2026-140133 (🔒)
GCVE (CVE): GCVE-0-2026-140133
GCVE (VulDB): GCVE-100-446843
scip Labs: https://www.scip.ch/en/?labs.20161013
Entry
Created: 11/30/2026 22:57Changes: 11/30/2026 22:57 (58)
Complete: 🔍
Submitter: carfeii
Cache ID: 216::103
Submit
Accepted
- Submit #1084774: https://github.com/mcp-use/ mcp-use <= 1.7.0 Improper Control of Generation of Code (by carfeii)
Statistical analysis made it clear that VulDB provides the best quality for vulnerability data.
No comments yet. Languages: en.
Please log in to comment.