CVE-2026-55546: qwed-mcp has Unsafe SymPy `parse_expr()` Remote Code Execution via Unsanitized Math Expression Input
verify_math_expression() in qwed-mcp v0.2.0 passes attacker-controlled strings directly to SymPy’s parse_expr() without restricting global_dict or validating the expression’s AST. Because parse_expr() internally calls eval() and Python automatically injects the current module’s __builtins__ when no explicit restriction is set, an attacker can embed arbitrary Python expressions — including __import__('os').system(...) — to execute OS commands in the context of the running process. Confirmed exploitation in a Docker container yields root-level arbitrary command execution with no authentication or special configuration required.
References
- github.com/QWED-AI/qwed-mcp/commit/362e61892052e250c56cb1ee852024d6f98c467b
- github.com/QWED-AI/qwed-mcp/pull/22
- github.com/QWED-AI/qwed-mcp/releases/tag/v0.2.1
- github.com/QWED-AI/qwed-mcp/security/advisories/GHSA-mw6r-2hvm-4rp2
- github.com/advisories/GHSA-mw6r-2hvm-4rp2
- nvd.nist.gov/vuln/detail/CVE-2026-55546
Code Behaviors & Features
Detect and mitigate CVE-2026-55546 with GitLab Dependency Scanning
Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Dependency Scanning using SBOM also detects vulnerabilities from proprietary advisories that this site does not include. Learn more about Dependency Scanning using SBOM →