Back to Home
Sunalamye icon

mcp-claude-shell

by Sunalamye

Overview

This server provides a structured interface for local Claude Code CLI commands, enabling generation, editing, and refactoring with built-in retry, timeout, and JSON validation capabilities via the MCP protocol.

Installation

Run Command
./mcp-claude.sh

Security Notes

The `mcp-claude.sh` script is critically vulnerable to shell injection. User-provided input parameters such as `jsonSchema`, `systemPrompt`, and `appendSystemPrompt` are directly embedded into shell command strings with single quotes (e.g., `'$json_schema'`) that are later executed via `bash -c`. A malicious client can inject arbitrary shell commands by including a single quote in these parameters, breaking out of the quoted string. For example, a `jsonSchema` value like `{'foo':'bar'}; rm -rf /; echo '` would result in the `rm -rf /` command being executed on the host system. Additionally, the underlying `claude` CLI is always invoked with `--dangerously-skip-permissions`, granting the AI agent broad, unconfirmed access to execute commands and modify files, which further exacerbates the risk if the system is compromised via prompt injection or the aforementioned shell injection vulnerability.

Similar Servers

Stats

Interest Score0
Security Score1
Cost ClassMedium
Avg Tokens1500
Stars0
Forks0
Last Update2025-11-26

Tags

MCP ServerClaude CLIAI ToolsShell ScriptCode GenerationJSON Validation