CVE-2026-47708 json
MCP-for-Stata: Command injection via log_file_name parameter in Stata command wrapper
published 2026-06-04 5 mo ago modified 2026-10-24 15 d ago also GHSA-4p62-hqp5-g644 , PYSEC-2026-544 , EUVD-2026-46426
- cvss
- 9.3
- version 4.0, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 0.4%
- EPSS 0.4% chance of exploitation in 30 days, percentile 32%
- public exploits
- 0
- none known
Summary
MCP-for-Stata is an MCP server for Stata to integrate Stata into an agent. Prior to version 1.17.3, the `log_file_name` parameter in the `stata_do` API and CLI is directly interpolated into a Stata command string without sanitization. The security guard (`GuardValidator`) only scans the do-file content but does not validate this parameter. An attacker can inject arbitrary Stata commands (including `shell`, `python`, `erase`, etc.) by crafting a malicious `log_file_name` containing quotes, newlines, or Stata command separators. Version 1.17.3 contains a patch for the issue.
Patch / fix
CISA SSVC
- Exploitation
- Proof of concept is public
- Automatable
- yes
- Technical impact
- total
- Assessed
- 3 mo ago
Exploit prediction
0.38% chance of exploitation in the next 30 days, higher than 32% of all scored CVEs (FIRST EPSS, 2026-11-08).
Exploits and checks
- github.com https://github.com/SepineTam/mcp-for-stata/security/advisories/GHSA-4p62-hqp5-g644 referenced PoC, tagged "exploit" by a source, unverified
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CNA | 4.0 | 9.3 | CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N |
| CNA | 4.0 | 9.3 | CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| pypi | stata-mcp | <1.17.3 |
1.17.3 |
Affected products
- SepineTam stata-mcp
Classification
- Weakness
-
- CWE-77 Improper Neutralization of Special Elements used in a Command
References
-
github.com
/SepineTam/mcp-for-stata/commit/e6f945941ae0c7cf5e74a428e0b3dc82b396382f
web
-
github.com
/SepineTam/mcp-for-stata/security/advisories/GHSA-4p62-hqp5-g644
exploit
-
github.com
/SepineTam/mcp-for-stata/issues/74
web
-
github.com
/SepineTam/stata-mcp/security/advisories/GHSA-4p62-hqp5-g644
web
-
github.com
/SepineTam/stata-mcp
package
-
pypi.org
/project/stata-mcp
package
-
github.com
/advisories/GHSA-4p62-hqp5-g644
advisory
-
nvd.nist.gov
/vuln/detail/CVE-2026-47708
advisory
Sources
- CVE List CVE-2026-47708
- GitHub Advisory GHSA-4p62-hqp5-g644
- NVD CVE-2026-47708
- OSV PYSEC-2026-544
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.