Stata mcp: MCP-for-Stata: Stata Command Injection via Unsanitized `package` in `ado_package_install` (CVE-2026-55071)
A command injection vulnerability exists in the Stata MCP tool 'ado_package_install' due to unsanitized user input in the 'package' parameter. This allows an attacker to inject arbitrary Stata commands, including OS shell commands, leading to remote code execution (RCE) under the Stata-MCP server account. The vulnerability affects versions prior to 1.19.0 and has a high severity CVSS score of 8.4. The tool is enabled by default in the 'all' profile, requiring no special configuration to be exploitable. A patch is available to remediate this issue.
AI Analysis
Technical Summary
The 'ado_package_install' tool in the 'stata-mcp' package concatenates the user-controlled 'package' argument directly into a Stata command string without validation or sanitization. This string is sent verbatim to the Stata interpreter, which executes each line separately. Because Stata supports a 'shell' command that executes OS shell commands, an attacker can inject newline characters and shell commands to achieve arbitrary OS command execution. The vulnerability arises from the lack of input validation on the 'package' parameter and the absence of guard checks on this execution path. The tool is registered in the default 'all' profile, making it enabled by default. Proof-of-concept exploits demonstrate the creation of arbitrary files on the host system via injected shell commands.
Potential Impact
Successful exploitation allows an attacker with access to invoke the 'ado_package_install' MCP tool or its Python API to execute arbitrary OS-level commands with the privileges of the Stata-MCP server process. This can lead to full remote code execution, compromising the host system. The vulnerability is rated high severity with a CVSS score of 8.4, reflecting its potential for complete system compromise without requiring user interaction or privileges.
Mitigation Recommendations
A patch is available for this vulnerability. Users should upgrade to version 1.19.0 or later of 'stata-mcp' to remediate the issue. Until patched, avoid exposing the MCP server to untrusted users or networks. Note that the existing command guard mechanism does not protect the 'ado_package_install' path, so relying on it is insufficient. Follow vendor guidance for applying the official fix.
Stata mcp: MCP-for-Stata: Stata Command Injection via Unsanitized `package` in `ado_package_install` (CVE-2026-55071)
Description
A command injection vulnerability exists in the Stata MCP tool 'ado_package_install' due to unsanitized user input in the 'package' parameter. This allows an attacker to inject arbitrary Stata commands, including OS shell commands, leading to remote code execution (RCE) under the Stata-MCP server account. The vulnerability affects versions prior to 1.19.0 and has a high severity CVSS score of 8.4. The tool is enabled by default in the 'all' profile, requiring no special configuration to be exploitable. A patch is available to remediate this issue.
CVSS v3.1
Score 8.4high
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The 'ado_package_install' tool in the 'stata-mcp' package concatenates the user-controlled 'package' argument directly into a Stata command string without validation or sanitization. This string is sent verbatim to the Stata interpreter, which executes each line separately. Because Stata supports a 'shell' command that executes OS shell commands, an attacker can inject newline characters and shell commands to achieve arbitrary OS command execution. The vulnerability arises from the lack of input validation on the 'package' parameter and the absence of guard checks on this execution path. The tool is registered in the default 'all' profile, making it enabled by default. Proof-of-concept exploits demonstrate the creation of arbitrary files on the host system via injected shell commands.
Potential Impact
Successful exploitation allows an attacker with access to invoke the 'ado_package_install' MCP tool or its Python API to execute arbitrary OS-level commands with the privileges of the Stata-MCP server process. This can lead to full remote code execution, compromising the host system. The vulnerability is rated high severity with a CVSS score of 8.4, reflecting its potential for complete system compromise without requiring user interaction or privileges.
Mitigation Recommendations
A patch is available for this vulnerability. Users should upgrade to version 1.19.0 or later of 'stata-mcp' to remediate the issue. Until patched, avoid exposing the MCP server to untrusted users or networks. Note that the existing command guard mechanism does not protect the 'ado_package_install' path, so relying on it is insufficient. Follow vendor guidance for applying the official fix.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- GHSA-49m4-vp58-wgc9
- Osv Schema Version
- 1.4.0
- Aliases
- ["CVE-2026-55071"]
- Ecosystems
- ["PyPI"]
- Database Specific Severity
- HIGH
- Cvss Version
- 3.1
Threat ID: 6a7cd3debf8831d53917fb2a
Added to database: 08/12/2026, 20:13:18 UTC
Last enriched: 08/12/2026, 21:11:59 UTC
Last updated: 08/12/2026, 21:11:59 UTC
Views: 3
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.