Back to MCP Directory
Shell
Model Context Protocol moderate risk

Shell

A secure server for executing whitelisted shell commands with stdin support, providing controlled access to system utilities.

Connections & Capabilities

Connects To

GitHub

Capabilities

exec

Quickstart

Install

npx -y @smithery/cli install mcp-shell-server --client claude

Config

{
  "mcpServers": {
    "shell": {
      "command": "uvx",
      "args": [
        "mcp-shell-server"
      ],
      "env": {
        "ALLOW_COMMANDS": "ls,cat,pwd,grep,wc,touch,find"
      }
    },
  }
}

Exposed MCP Tools (1)

high
mcp-shell-server

Executes whitelisted shell commands with input and timeout support.

Executes shell commands, potentially leading to system compromise if misconfigured.

Safety Assessment

This server is relatively safe when the command whitelist is carefully managed and timeouts are enforced. Risks increase if the whitelist is overly permissive or if the server is exposed to untrusted networks without proper security measures.

  • Command whitelisting restricts executable commands.
  • Shell operator validation prevents injection.
  • Direct command execution avoids shell interpretation.
  • Timeout control limits execution time.
  • Improperly configured whitelists can lead to vulnerabilities.
  • Potential for resource exhaustion if timeouts are not set correctly.
  • Exposure of server to network increases attack surface.
  • Incorrect handling of standard input could lead to unexpected behavior.