Command injection flaw found in code-review-mcp-server
Advisory published on 16 November 2026 says caller-supplied folder and branch names ran straight through a shell, allowing arbitrary commands on the host.
By The Agentic Times ·

A GitHub security advisory published on 16 November 2026 warns that the npm package code-review-mcp-server, used to give AI coding agents access to code review tasks, allowed arbitrary commands to be run on the machine hosting it. The flaw, tracked as CVE-2026-68934 under advisory GHSA-jq3q-62jc-fqq9, affects all versions before 1.5.3.
According to the advisory, the package exposes four MCP tools — getLocalGitDiff, codeReview, createPR and getPRTemplate. MCP, the Model Context Protocol, is the interface that lets an AI agent call external tools. Each of those tools accepts two string parameters supplied by the caller: folderPath and baseBranch.
The problem was how those strings were used. The advisory says the values were interpolated directly into shell command strings and executed with Node's child_process.execSync(), which runs the resulting command through /bin/sh. Anything that the shell treats as a separator or as a nested command would therefore be obeyed rather than treated as text.
The advisory gives worked examples. A baseBranch value of main; <arbitrary command> # would terminate the intended git command and run whatever followed, with the trailing hash comment swallowing the rest of the original line. A $(...) command substitution would have the same effect. A folderPath that breaks out of the surrounding quotes also works. The result, in the advisory's words, is arbitrary command execution on the host running the MCP server.
That matters because of where these servers typically sit. A code review MCP server runs on a developer machine or a build host, with access to source repositories and, in this case, the git and gh command line tools. Any command the server process can run, an attacker who controls the parameter values can run too.
The maintainers fixed the issue in version 1.5.3. According to the advisory, every execSync() call was replaced with execFileSync() using argument arrays. That change passes the inputs directly to git and gh as discrete arguments, without a shell in between, which the advisory describes as eliminating the injection at its root. It is the standard remedy for this class of bug: stop building a command as a single string, and hand the program its arguments separately.
There are no workarounds. The advisory states plainly that the only remedy is to upgrade to code-review-mcp-server 1.5.3 or later. Users still on an earlier version should assume the tools are callable with untrusted input and update.
The advisory does not say whether the flaw was exploited, does not name a reporter, and does not give a timeline for when the vulnerable code was introduced. It also does not state how many installations are affected.
The pattern is a familiar one in the MCP ecosystem. Tool parameters that look like ordinary configuration — a path, a branch name — arrive from whatever is driving the agent, and may ultimately originate from content the agent has read rather than from a human typing at a prompt. Treating those values as trusted strings and pasting them into a shell command removes the boundary between data and instruction. The fix shipped here, passing arguments as arrays rather than concatenated text, closes that gap for this package.
Sources
- github.comhttps://github.com/advisories/GHSA-jq3q-62jc-fqq9
