
overklassniy/ssh-mcp
Developer toolsこのページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る
SSH MCP サーバー: コマンドを実行し、ファイルを転送し、MCP 経由でリモートサーバーでポートを転送します.
概要
MCP (Model Context Protocol) サーバは、AI アシスタントをセキュアに、スコープ付き SSH を 1 つ以上のリモートサーバへアクセスします。 ssh-mcp は stdio 上で動作し、任意の MCP 互換クライアントと動作します。: Claude デスクトップ、Claude コード、カーソル、Devin、VS コード、Cline。 コマンド実行、SFTPファイル転送、ディレクトリの同期、ポート転送、リモートシステムステータスコレクションの8つのツールを公開します。 リモートサーバ上で動作する必要があるAIアシスタントは、通常、生のシェル(unsafe, unscoped)を取得するか、SSHアクセスが全くない。 ssh-mcp は、エージェントに小さな、監査可能なツールセット、オプションのコマンドホワイトリスト/ブラックリストとパスの制限によってゲートされるので、オペレーターはエージェントができることを正確に制御します。 - - - 実行前に、ホワイトリストとブラックリストの正規表現パターンゲート。 ホワイトリストがなければ、すべてのコマンドが許可され、起動時に警告が記録されます.
概要(AI 翻訳)
AI アシスタントをセキュアにしてくれる MCP (Model Context Protocol) サーバー スコープ付きSSHは、複数のリモートサーバへアクセス可能です。
[ssh-mcp は stdio 上で実行し、任意の MCP 互換クライアントで動作します。
クロードデスクトップ、クロードコード、カーソル、デビン、VSコード、Cline。 それは、
コマンド実行、SFTPファイル転送、ディレクトリの8つのツールを公開
同期、ポート転送、リモートシステムステータス収集。
なぜ違うのか
リモートサーバ上で動作する必要があるAIアシスタントは、通常、どちらか
生シェル(unsafe、unscoped)を取得するか、SSHアクセスが全くない。
[ssh-mcp の間に座っています: エージェントに小さい、監査可能なセットを与えます
ツール、オプションのコマンドホワイトリスト/ブラックリストとパスによってゲートされる各
制限があるので、オペレータはエージェントができることを正確に制御します。
-Command policy - [whitelistと[blacklist])正規表現パターンゲート
実行前のすべてのコマンド。 ホワイトリストがなければ、すべてのコマンドは
起動時に警告が記録されます。
-Pathの制限 - [allowed_local_pathsと[allowed_remote_paths]
特定のディレクトリにSFTP転送を合成し、パスを拒否する
トラバーサル。
- ** env vars** - パスワード、パスフレーズ、および2FAコードによる秘密
このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。
README
以下は原文 README の抜粋です。原文を見る。
ssh-mcp
An MCP (Model Context Protocol) server that gives AI assistants secure, scoped SSH access to one or more remote servers.
ssh-mcp runs over stdio and works with any MCP-compatible client:
Claude Desktop, Claude Code, Cursor, Devin, VS Code, and Cline. It
exposes eight tools for command execution, SFTP file transfer, directory
sync, port forwarding, and remote system status collection.
Why it is different
AI assistants that need to operate on remote servers typically either
get a raw shell (unsafe, unscoped) or have no SSH access at all.
ssh-mcp sits in between: it gives the agent a small, auditable set of
tools, each gated by an optional command whitelist/blacklist and path
restrictions, so the operator controls exactly what the agent can do.
- Command policy –
whitelistandblacklistregex patterns gate every command before execution. Without a whitelist, all commands are allowed and a warning is logged at startup. - Path restrictions –
allowed_local_pathsandallowed_remote_pathsconfine SFTP transfers to specific directories and reject path traversal. - Secrets via env vars – password, passphrase, and 2FA code are passed via environment variables, never on the command line.
- Hot-reload – when started with
--config, the config file is watched for changes and reloaded without restarting the server. Add, remove, or modify servers and the change takes effect within seconds.
Tools at a glance
| Tool | Description |
|---|---|
execute-command |
Run a command on a remote server |
upload |
Upload a local file via SFTP |
download |
Download a remote file via SFTP |
list-remote |
List a remote directory via SFTP |
dir-sync |
Recursively sync a directory between local and remote |
インストール
This server does not publish a one-line install command.
Open the repository installation guide MCP 初心者?mcpskill.org のガイドから始めましょう →設定
{
"mcpServers": {
"ssh-mcp": {
"command": "go",
"args": [
"run",
"github.com/overklassniy/ssh-mcp/cmd/ssh-mcp@latest",
"--host", "192.168.1.1",
"--port", "22",
"--user", "root",
"--transport", "exec"
],
"env": {
"SSH_MCP_PASSWORD": "your-password"
}
}
}
}