CVE-2026-30635: automagik-genie has a command injection vulnerability
automagik-genie 2.5.27 has a command injection in its MCP server. The view_task tool (alias view) builds a shell command from values returned by the Forge backend, so a Forge server controlled by an attacker can run commands on the user's machine. No patched version is listed.
Published May 11, 2026 · Updated May 18, 2026 · Analysis Nov 3, 2026
What an attacker can do
In dist/mcp/server.js, readTranscriptFromCommit() builds a command string from a template and runs it with execSync(), which hands it to /bin/sh (or cmd.exe on Windows). The values come from the Forge API response, not from the MCP client. commitSha, taken from after_head_commit, is placed outside any quotes, so ;, $(), backticks, | and && all run. gitDir, built from container_ref plus /.git, sits in double quotes where $() and backticks still work, but an fs.existsSync() check must pass first.
view_task calls viewSession(), which fetches the task attempt and its execution processes from Forge and passes them to the vulnerable function.
This is second-order injection. The attacker must control the Forge response. According to the researcher's write-up, the likely routes are: tricking a user into setting FORGE_BASE_URL to the attacker's server, compromising the real Forge backend or something between it and the MCP server, or a man-in-the-middle on the connection, which matters because the default URL is plain HTTP. That explains the High attack complexity in the vector. No further interaction is needed. The result is code execution as the user running the MCP server: environment variables, API keys, internal network access and persistence.
Who is affected
Affected: automagik-genie 2.5.27 exactly, per the package data. The sources do not state whether other versions are affected. Risk applies when the MCP server's view_task tool is used against a Forge backend you do not fully control or reach over plain HTTP. Check the installed version and Forge setting:
npm ls automagik-genie
echo $FORGE_BASE_URLautomagik-genie
- Ecosystem
- npm
- Affected
- = 2.5.27
- Fixed in
- No patched version yet
- Check
npm ls automagik-genie
How to fix it
No patched version is listed for automagik-genie. The researcher's write-up lists vendor notification as pending. Mitigations from the write-up: point FORGE_BASE_URL only at a Forge server you control, over a trusted network, and avoid plain HTTP across untrusted links. The code-level fix it recommends is to replace execSync() with execFileSync() and an argument array, check commitSha against a hex pattern of 5 to 40 characters, and resolve containerRef with realpath under an allowed workspace. Until a fixed release appears, consider not running the MCP server's view_task tool.
How to tell if you were hit
Check what FORGE_BASE_URL points to in your shell, MCP client config and .env files. Look for child shell processes started by the automagik-genie MCP server process that are not git, and for unexpected files or outbound connections soon after a view_task call. Forge responses with an after_head_commit value that is not a hex hash are a sign of an attack attempt. The sources give no log line for this.
Original advisory
From the GitHub Advisory Database (CC BY 4.0).
Command injection vulnerability in automagik-genie 2.5.27 MCP Server allows attackers to execute arbitrary commands via the view_task (aka view) in the readTranscriptFromCommit function in dist/mcp/server.js when a user reads from an external FORGE_BASE_URL.
Questions
- Can the MCP client send the malicious input?
No. The injected values come from the Forge backend's responses, not from the MCP client. The attacker has to control or intercept the Forge server the tool talks to.
- Is there a fixed version of automagik-genie?
None is listed. The package data names 2.5.27 as vulnerable with no patched release, and the write-up says vendor notification was pending.
- Why is attack complexity rated high?
Exploitation needs control over the Forge response: a hostile FORGE_BASE_URL, a compromised backend, or a man-in-the-middle on the default plain-HTTP connection.
References
How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. The analysis is written by an AI model from the sources listed above and checked by automated rules before it is published. Check versions against the vendor's advisory before you act. Methodology
More Other MCP servers and tools vulnerabilities
All Other MCP servers and tools entriesCVE-2026-102943
Dagu MCP DAG specification read bypasses path containment and workspace isolation
medium6.5Nov 10, 2026CVE-2026-102610
fast-agent: `fast-agent serve` binds HTTP to 0.0.0.0 with no authentication by default; with --shell this is unauthenticated remote command execution
medium6.4Nov 9, 2026CVE-2026-63655
tsParticles: Unbounded HTTP Request Body Buffering in @tsparticles/mcp-server Leads to Remote DoS
high7.5Nov 9, 2026CVE-2026-76892
tsParticles: Malformed JSON requests can terminate the @tsparticles/mcp-server HTTP process
high8.7Nov 9, 2026CVE-2026-76893
tsParticles: A single anonymous MCP session can monopolize HTTP mode and deny new clients
medium6.9Nov 9, 2026CVE-2026-77604
Code Graph RAG: MCP paginated read_file path traversal / arbitrary file read
high7.5Nov 9, 2026
