hagent through commit 761eec6 contains an OS command injection vulnerability that allows MCP clients to execute shell
Source GCVE Database
Not known to be exploited · CVSS 8.5 High.
Data as of 27 Oct 2026, 16:42 UTC
CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:NExploitation evidence
Disclosed: evidence found.
CVE published 27 Oct 2026
Detectable: no evidence on record.
No public nuclei template indexed
Weaponised: no evidence on record.
No public exploit code indexed in Metasploit or Exploit-DB
Exploited in the wildExploited: no evidence on record.
Not in CISA KEV and no source reports exploitation
Observed by OffSeq MirageSeen by Mirage: no evidence on record.
No attack traffic recorded by OffSeq Mirage sensors
A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 26 Oct 2026.
What to do
Affected software
| Product | Affected | Fixed in |
|---|---|---|
| masc-ucschagent | Affected
| Fixed in– |
GitHubmasc-ucsc/hagentpkg:github/masc-ucsc/hagentOther threats | Affected
| Fixed in– |
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
AI-suggested
Users should avoid running vulnerable versions or restrict access to MCP clients until a fix is released. Monitor vendor advisories for updates. Since subprocess.run is used with shell=True and untrusted input, applying input validation or sanitization on the args parameter is recommended as a temporary mitigation.
Description
An OS command injection vulnerability exists in hagent through commit 761eec6. This flaw allows MCP clients to execute arbitrary shell commands by injecting metacharacters into the args parameter of the hagent_arduino and hagent_esp32 tools. The vulnerability arises because crafted args are interpolated unsafely into arduino-cli and idf.py commands executed with subprocess.run(shell=True), enabling command execution with the privileges of the MCP server user.
References
- nvd.nist.gov/vuln/detail/CVE-2026-117573 (opens in a new tab)
- github.com/masc-ucsc/hagent/issues/98 (opens in a new tab)
- github.com/masc-ucsc/hagent (opens in a new tab)
- github.com/masc-ucsc/hagent/blob/761eec627a1e6fb128a2a8ce9245aa595cc2f7af/hagent/mcp/mcp_arduino.py (opens in a new tab)
- github.com/masc-ucsc/hagent/blob/761eec627a1e6fb128a2a8ce9245aa595cc2f7af/hagent/mcp/mcp_esp32.py (opens in a new tab)
- vulncheck.com/advisories/hagent-through-commit-761eec6-os-command-injection-via-arduino-and-esp32-mcp-tools (opens in a new tab)