Skip to content
GitHub Security Advisories·Indexed by this site · Originally published· Event →· Its place in the scan record →

code-review-mcp-server unfiltered parameters led to command injection, fixed in 1.5.3

code-review-mcp-server: Command injection via unsanitized folderPath/baseBranch parameters

AI summary

code-review-mcp-server (CVE-2026-68934) fixed a command injection vulnerability in its MCP tools; versions before 1.5.3 are affected, and it is fixed in 1.5.3. The package's four tools getLocalGitDiff, codeReview, createPR, and getPRTemplate accept caller-controllable folderPath and baseBranch string parameters, and these values were previously concatenated directly into shell commands executed via child_process.execSync() (run through /bin/sh); constructing parameter values containing command separators or $(...) command substitution allows arbitrary command execution on the host running the MCP server. The fix replaces all execSync() calls with execFileSync() using argument arrays, passing input directly to git and gh without going through a shell.

Read originalgithub.com