Advisory Database
  • Advisories
  • Dependency Scanning
  1. pypi
  2. ›
  3. stata-mcp
  4. ›
  5. CVE-2026-47708

CVE-2026-47708: MCP-for-Stata: Command injection via log_file_name parameter in Stata command wrapper

June 4, 2026

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.

References

  • github.com/SepineTam/mcp-for-stata/commit/e6f945941ae0c7cf5e74a428e0b3dc82b396382f
  • github.com/SepineTam/mcp-for-stata/issues/74
  • github.com/SepineTam/stata-mcp/security/advisories/GHSA-4p62-hqp5-g644
  • github.com/advisories/GHSA-4p62-hqp5-g644
  • nvd.nist.gov/vuln/detail/CVE-2026-47708

Code Behaviors & Features

Detect and mitigate CVE-2026-47708 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 1.17.3

Fixed versions

  • 1.17.3

Solution

Upgrade to version 1.17.3 or above.

Impact 9.8 CRITICAL

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Learn more about CVSS

Weakness

  • CWE-77: Improper Neutralization of Special Elements used in a Command ('Command Injection')

Source file

pypi/stata-mcp/CVE-2026-47708.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Tue, 23 Jun 2026 12:23:14 +0000.