Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-108953 Overview
CVE-2026-108953 is an OS command injection vulnerability [CWE-78] in mac-shell-mcp versions prior to 2.0.0. The mac-shell-mcp project exposes a Model Context Protocol (MCP) server that lets AI clients run shell commands on macOS. The server enforces a command whitelist, but attackers can inject shell metacharacters into the arguments field of execute_command to bypass that control. A whitelisted command such as pwd combined with an argument like ; executes arbitrary commands as the server user without approval.
Critical Impact
Malicious MCP clients or prompt injection payloads can execute arbitrary shell commands as the server user, bypassing the command allowlist and approval workflow.
Affected Products
- mac-shell-mcp versions prior to 2.0.0
- MCP clients and AI assistants connected to a vulnerable mac-shell-mcp server
- macOS hosts running the mac-shell-mcp server process
Discovery Timeline
- 2026-10-12 - CVE-2026-108953 published to NVD
- 2026-10-16 - Last updated in NVD database
Technical Details for CVE-2026-108953
Vulnerability Analysis
The mac-shell-mcp server implements a tool named execute_command that accepts a command name and an array of arguments. The server validates the command name against a whitelist and routes non-whitelisted commands through an approval queue. The validation applies only to the command token, not to its arguments.
When the server passes those arguments to a shell interpreter, metacharacters such as ;, &&, |, and backticks are interpreted as shell syntax. An attacker calls a benign whitelisted command like pwd and supplies ; followed by an attacker-chosen command. The shell executes both, so arbitrary commands run with the privileges of the MCP server process.
The exploitation path is relevant to AI-assisted workflows. Any prompt-injection payload reaching the MCP client can trigger execution without user approval. See the VulnCheck Security Advisory for the full disclosure.
Root Cause
The command handler constructs a shell invocation that concatenates whitelisted command names with raw user-supplied arguments. No argument sanitization, metacharacter filtering, or shell: false execution is applied. The relevant logic lives in command-service.ts lines 257-340.
Attack Vector
A local or remotely connected MCP client submits a crafted execute_command request. The attacker supplies a whitelisted command and places shell metacharacters inside the arguments array. Prompt injection in untrusted documents, web content, or tool outputs can also drive this request without direct attacker access.
// Fix commit metadata (source: GitHub)
// feat(security)!: rebuild on confinement, allowlists and no shell (2.0.0) (#20)
// Commit: 932ce733cde07bb30b1f186303e6692dbb5d087a
Source: GitHub Commit Overview. The release notes state the fix rebuilds the server around process confinement, strict allowlists, and non-shell execution.
Stop Remote Code Execution Before It Runs
Singularity™ Endpoint detects and blocks exploit attempts at machine speed, including zero-days and novel attack techniques.
Stop Exploit AttemptsDetection Methods for CVE-2026-108953
Indicators of Compromise
- execute_command invocations where the arguments field contains shell metacharacters such as ;, |, &, `, $(, or redirection operators.
- Child processes of the mac-shell-mcp Node.js server that are not members of the configured command whitelist.
- Outbound network connections initiated by processes spawned from the MCP server context.
Detection Strategies
- Log every execute_command request and alert on arguments containing shell control characters.
- Compare the parent-child process tree against the documented whitelist and flag deviations.
- Correlate MCP client prompts with subsequent shell activity to identify prompt-injection driven execution.
Monitoring Recommendations
- Enable macOS Endpoint Security ES_EVENT_TYPE_NOTIFY_EXEC auditing for the MCP server user.
- Capture MCP server stdout and stderr to a central log store for retroactive hunting.
- Monitor the mac-shell-mcp package version across developer workstations and build agents.
How to Mitigate CVE-2026-108953
Immediate Actions Required
- Upgrade mac-shell-mcp to version 2.0.0 or later immediately.
- Audit MCP server logs for execute_command calls containing shell metacharacters since deployment.
- Rotate any credentials, tokens, or SSH keys accessible from the host running the MCP server.
Patch Information
The fix is delivered in mac-shell-mcp2.0.0 via commit 932ce733cde07bb30b1f186303e6692dbb5d087a. The release rebuilds command handling around strict allowlists, process confinement, and shell-free execution. Review the GitHub Issue Discussion and the GitHub PoC Repository for upgrade guidance.
Workarounds
- Stop the mac-shell-mcp server until the 2.0.0 upgrade is applied.
- Run the MCP server under a dedicated low-privilege account with no sudo rights and restricted filesystem access.
- Restrict MCP client connectivity to trusted local sockets and block untrusted content sources that could carry prompt injection payloads.
# Upgrade mac-shell-mcp to the patched release
npm install -g mac-shell-mcp@2.0.0
# Verify the installed version
npm list -g mac-shell-mcp
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

