tufantunc/ssh-mcp

tufantunc/ssh-mcp

от tufantunc
MCP-совместимый сервер для удаленного выполнения shell-команд на Linux и Windows через SSH. Поддерживает sudo, настраиваемые таймауты и аутентификацию. Отлично подходит DevOps и разработчикам, работающим с LLM.

SSH MCP Server v2

NPM Version Downloads CI OpenSSF Scorecard OpenSSF Best Practices codecov License GitHub issues

SSH MCP Server is a security-first Model Context Protocol server that gives LLM agents controlled SSH access to remote hosts — with command classification, policy-based authorization, human-in-the-loop approval, and full audit logging.

The risk this server exists to manage. Giving an LLM shell access on a remote host puts private data, untrusted input and network egress in one place — Simon Willison's "lethal trifecta". Prompt injection has no general fix, so ssh-mcp assumes any command may be attacker-influenced: it classifies before executing, authorizes against a role × host-group matrix, gates destructive work behind approval, and records the decision either way. That narrows the blast radius; it does not remove the risk. Two things stay yours: never point it at a root account, and never set auto approval on a production profile. SECURITY.md has the full threat model.


Quick Start

1. Install
npm install -g ssh-mcp
2. Configure

Without a config the server still starts, so a client or directory can complete the MCP handshake and read tools/list — but every tool call is refused until you configure it, with a message naming the path below. Nothing runs on a host until this step is done.

Часто задаваемые вопросы

Инструменты были проиндексированы:
exec

Выполняет shell-команду на удалённом SSH-сервере и возвращает вывод.

Параметры
  • commandstringобязательный

    Команда оболочки для выполнения на удалённом SSH-сервере.

  • descriptionstring

    Необязательное описание того, что делает эта команда.

sudo-exec

Выполняет команду shell на удалённом SSH-сервере с помощью sudo. Использует пароль sudo, если он указан, в противном случае предполагает sudo без пароля.

Параметры
  • commandstringобязательный

    Команда оболочки для выполнения с sudo на удалённом SSH-сервере.

  • descriptionstring

    Необязательное описание того, что делает эта команда.

2.19.1основная
2.19.0
2.18.0
2.17.0
2.16.0
2.15.0
2.14.0
2.13.0
2.12.0
2.11.0
2.10.0
2.9.1
2.9.0
2.8.3
2.8.2
2.8.1
2.8.0
2.7.0
2.6.0
2.5.1
2.5.0
2.4.2
2.4.1
2.4.0
2.3.4
2.3.3
2.3.2
2.3.1
2.3.0
2.2.6
2.2.5
2.2.4
2.2.3
2.2.2
2.2.1
2.2.0
2.1.0
2.0.4
2.0.3
2.0.2
2.0.1
2.0.0
1.5.0
1.4.0
1.3.0
1.2.2
1.2.0
1.1.0
1.0.9
1.0.8
1.0.7
1.0.6
1.0.5
1.0.4
1.0.3
1.0.1
1.0.0

Выберите клиент, чтобы установить tufantunc/ssh-mcp:

Любой клиент

Конфиг добавления MCP сервера стандартный, обычно он не меняется вообще, поэтому подходит практически к любому ИИ клиенту, поддерживающему MCP.

{
  "mcpServers": {
    "tufantunc-ssh-mcp-jmkz0wu8ed": {
      "command": "npx",
      "args": [
        "ssh-mcp",
        "-y",
        "--",
        "--host=1.2.3.4",
        "--port=22",
        "--user=root",
        "--password=pass",
        "--key=path/to/key",
        "--timeout=30000",
        "--maxChars=none"
      ]
    }
  }
}
CursorCursor

Перейдите по ссылке и сервер автоматически будет добавлен в Cursor. Либо откройте/создайте файл ~/.cursor/mcp.json(%USERPROFILE%\.cursor\mcp.json на Windows) и добавьте конфиг сервера:

{
  "mcpServers": {
    "tufantunc-ssh-mcp-jmkz0wu8ed": {
      "command": "npx",
      "args": [
        "ssh-mcp",
        "-y",
        "--",
        "--host=1.2.3.4",
        "--port=22",
        "--user=root",
        "--password=pass",
        "--key=path/to/key",
        "--timeout=30000",
        "--maxChars=none"
      ]
    }
  }
}
VS Code

Создайте .vscode/mcp.json в проекте (ключ верхнего уровня — servers):

{
  "servers": {
    "tufantunc-ssh-mcp-jmkz0wu8ed": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "ssh-mcp",
        "-y",
        "--",
        "--host=1.2.3.4",
        "--port=22",
        "--user=root",
        "--password=pass",
        "--key=path/to/key",
        "--timeout=30000",
        "--maxChars=none"
      ]
    }
  }
}

Либо добавьте сервер через терминал:

code --add-mcp "{\"name\":\"tufantunc-ssh-mcp-jmkz0wu8ed\",\"type\":\"stdio\",\"command\":\"npx\",\"args\":[\"ssh-mcp\",\"-y\",\"--\",\"--host=1.2.3.4\",\"--port=22\",\"--user=root\",\"--password=pass\",\"--key=path/to/key\",\"--timeout=30000\",\"--maxChars=none\"]}"
ClaudeClaude Desktop

Откройте Settings → Developer → Edit Config — это откроет файл claude_desktop_config.json:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json

Впишите сервер и полностью перезапустите Claude Desktop:

{
  "mcpServers": {
    "tufantunc-ssh-mcp-jmkz0wu8ed": {
      "command": "npx",
      "args": [
        "ssh-mcp",
        "-y",
        "--",
        "--host=1.2.3.4",
        "--port=22",
        "--user=root",
        "--password=pass",
        "--key=path/to/key",
        "--timeout=30000",
        "--maxChars=none"
      ]
    }
  }
}
Claude CodeClaude Code

Добавьте сервер одной командой в терминале:

claude mcp add tufantunc-ssh-mcp-jmkz0wu8ed -- npx ssh-mcp -y -- --host=1.2.3.4 --port=22 --user=root --password=pass --key=path/to/key --timeout=30000 --maxChars=none

Либо через JSON-конфиг:

claude mcp add-json tufantunc-ssh-mcp-jmkz0wu8ed "{\"command\":\"npx\",\"args\":[\"ssh-mcp\",\"-y\",\"--\",\"--host=1.2.3.4\",\"--port=22\",\"--user=root\",\"--password=pass\",\"--key=path/to/key\",\"--timeout=30000\",\"--maxChars=none\"]}"
CodexCodex

Добавьте сервер командой в терминале:

codex mcp add tufantunc-ssh-mcp-jmkz0wu8ed -- npx ssh-mcp -y -- --host=1.2.3.4 --port=22 --user=root --password=pass --key=path/to/key --timeout=30000 --maxChars=none

Либо вручную в ~/.codex/config.toml(%USERPROFILE%\.codex\config.toml на Windows):

[mcp_servers.tufantunc-ssh-mcp-jmkz0wu8ed]
command = "npx"
args = ["ssh-mcp", "-y", "--", "--host=1.2.3.4", "--port=22", "--user=root", "--password=pass", "--key=path/to/key", "--timeout=30000", "--maxChars=none"]
PerplexityPerplexity

MCP доступен подписчикам Perplexity Pro / Max / Enterprise. Локальные серверы — только в приложении для macOS.

  1. Откройте Настройки аккаунта → Connectors.
  2. Установите вспомогательное приложение PerplexityXPC (один раз).
  3. Нажмите Add Connector → вкладка Simple.
  4. В поле Server Name укажите tufantunc/ssh-mcp, а в поле команды запуска — строку ниже:
npx ssh-mcp -y -- --host=1.2.3.4 --port=22 --user=root --password=pass --key=path/to/key --timeout=30000 --maxChars=none

Нажмите Save и дождитесь статуса Running.

WindsurfWindsurf

Откройте Windsurf Settings → Cascade → MCP Servers или отредактируйте файл ~/.codeium/windsurf/mcp_config.json:

{
  "mcpServers": {
    "tufantunc-ssh-mcp-jmkz0wu8ed": {
      "command": "npx",
      "args": [
        "ssh-mcp",
        "-y",
        "--",
        "--host=1.2.3.4",
        "--port=22",
        "--user=root",
        "--password=pass",
        "--key=path/to/key",
        "--timeout=30000",
        "--maxChars=none"
      ]
    }
  }
}
ClineCline

В панели Cline нажмите иконку MCP Servers → Configure → Configure MCP Servers (или отредактируйте ~/.cline/mcp.json) и добавьте сервер:

{
  "mcpServers": {
    "tufantunc-ssh-mcp-jmkz0wu8ed": {
      "command": "npx",
      "args": [
        "ssh-mcp",
        "-y",
        "--",
        "--host=1.2.3.4",
        "--port=22",
        "--user=root",
        "--password=pass",
        "--key=path/to/key",
        "--timeout=30000",
        "--maxChars=none"
      ],
      "disabled": false,
      "autoApprove": []
    }
  }
}
Continue

Создайте файл в .continue/mcpServers/ (например tufantunc-ssh-mcp-jmkz0wu8ed.yaml) или добавьте блок в config.yaml. MCP работает только в режиме agent:

mcpServers:
  - name: tufantunc-ssh-mcp-jmkz0wu8ed
    command: npx
    args:
      - "ssh-mcp"
      - "-y"
      - "--"
      - "--host=1.2.3.4"
      - "--port=22"
      - "--user=root"
      - "--password=pass"
      - "--key=path/to/key"
      - "--timeout=30000"
      - "--maxChars=none"
Zed

Выполните agent: add context server или откройте настройки (zed: open settings file) и добавьте сервер в объект context_servers:

{
  "context_servers": {
    "tufantunc-ssh-mcp-jmkz0wu8ed": {
      "command": "npx",
      "args": [
        "ssh-mcp",
        "-y",
        "--",
        "--host=1.2.3.4",
        "--port=22",
        "--user=root",
        "--password=pass",
        "--key=path/to/key",
        "--timeout=30000",
        "--maxChars=none"
      ]
    }
  }
}

Похожие MCP-сервера

tumf/mcp-shell-server

tumf/mcp-shell-server

от tumf

MCP сервер для безопасного удалённого выполнения команд оболочки с белым списком, изоляцией окружения и аудитом. Поддерживает stdin, пайпы и лимиты времени/вывода. Идеален для интеграции shell-команд в MCP с контролем безопасности.

Python⭐ 201
sonirico/mcp-shell

sonirico/mcp-shell

от sonirico

MCP сервер для безопасного выполнения shell-команд через LLM с полным контролем. Secure-режим по умолчанию ограничивает утилиты белым списком read-only команд. Политики настраиваются через YAML. Идеален для Claude Desktop и агентов, где важна безопасность.

Go⭐ 108
laszlopere/mcp-tmux

laszlopere/mcp-tmux

от laszlopere

MCP-сервер для tmux: управляет сеансами, окнами, панелями, отправляет команды и читает вывод. Работает локально или по SSH. Подходит для парного программирования с ИИ — вы видите действия агента в реальном времени и можете перехватить управление. Полезен разработчикам.

Python⭐ 6
MladenSU/cli-mcp-server

MladenSU/cli-mcp-server

от mladensu

MCP сервер для безопасного выполнения команд CLI с whitelist-фильтрацией. Защищает от path traversal, ограничивает команды, флаги и длину, устанавливает таймауты. Идеален для LLM-приложений с контролируемым доступом к терминалу.

Python⭐ 177
ooples/mcp-console-automation

ooples/mcp-console-automation

от ooples

MCP сервер для автоматизации консольных приложений через AI: управляйте сессиями, мониторьте вывод и обнаруживайте ошибки. Поддерживает SSH, профили и фоновые задачи. Для разработчиков и DevOps.

TypeScript⭐ 52
ferrislucas/iterm-mcp

ferrislucas/iterm-mcp

от ferrislucas

Разработчики: MCP сервер для iTerm дает модели полный контроль над терминалом - выполнение команд, чтение вывода, управление REPL. Эффективный расход токенов, простая интеграция. Делегируйте задачи и наблюдайте за работой.

TypeScript⭐ 570
© Каталог MCP, 2026. Все права защищены.
Проект не аффилирован с Anthropic и любыми упомянутыми продуктами.
Все названия и торговые марки принадлежат их владельцам.
Контакты для связи: hi@mcp-katalog.ru

Лука Никитин