Skip to main content
Glama

SSH MCP Server

SSH MCP サーバー

SSH機能を提供するモデルコンテキストプロトコル(MCP)サーバー実装。このサーバーは、MCPプロトコルを介した安全なリモートアクセスと実行を可能にします。

特徴

  • MCPプロトコルを使用したSSHサーバーの実装
  • データの永続性のためのSQLiteデータベース統合
  • 型安全性と開発エクスペリエンスの向上を実現する TypeScript 実装

前提条件

  • Node.js(v16以上を推奨)
  • npm または yarn パッケージマネージャー
  • 開発のためのTypeScriptの知識

インストール

Smithery経由でインストール

Smithery経由で Claude Desktop 用の SSH サーバーを自動的にインストールするには:

npx -y @smithery/cli install @KinoThe-Kafkaesque/ssh-mcp-server --client claude

手動インストール

  1. リポジトリをクローンします。
git clone <repository-url> cd ssh-server
  1. 依存関係をインストールします:
npm install
  1. プロジェクトをビルドします。
npm run build

使用法

構成

サーバーはSSH認証情報を保存するためにSQLiteデータベース( ssh.db )を使用します。データベースファイルはサーバーの起動時に自動的に作成されます。

ツール

サーバーは次のツールを提供します。

ssh_exec

SSH 経由でコマンドを実行します。

入力パラメータ:

  • host : 接続先のホスト。(必須)
  • command : 実行するコマンド。(必須)
  • username : SSH接続に使用するユーザー名。(必須)
  • privateKeyPath : 秘密鍵ファイルへのパス。(必須)

使用例:

{ "tool_name": "ssh_exec", "arguments": { "host": "example.com", "command": "ls -l", "username": "user", "privateKeyPath": "/path/to/private/key" } }

注意: privateKeyPathは、秘密鍵ファイルへの有効なパスである必要があります。

資格情報の追加

新しい SSH 資格情報を追加します。

入力パラメータ:

  • name : 資格情報の名前。(必須)
  • host : 接続先のホスト。(必須)
  • username : SSH接続に使用するユーザー名。(必須)
  • privateKeyPath : 秘密鍵ファイルへのパス。(必須)

使用例:

{ "tool_name": "add_credential", "arguments": { "name": "my_credential", "host": "example.com", "username": "user", "privateKeyPath": "/path/to/private/key" } }

注意: privateKeyPathは、秘密鍵ファイルへの有効なパスである必要があります。

資格情報のリスト

保存されているすべての SSH 資格情報を一覧表示します。

入力パラメータ:

  • なし

使用例:

{ "tool_name": "list_credentials", "arguments": {} }
資格情報を削除する

保存された SSH 資格情報を削除します。

入力パラメータ:

  • name : 削除する資格情報の名前。(必須)

使用例:

{ "tool_name": "remove_credential", "arguments": { "name": "my_credential" } }

サーバーの起動

npm start

サーバーは設定されたポートで実行を開始します (デフォルト設定はソース コードで変更できます)。

プロジェクト構造

  • src/ - ソースコードディレクトリ
  • build/ - コンパイルされたJavaScript出力
  • node_modules/ - プロジェクトの依存関係

依存関係

  • @modelcontextprotocol/sdk : MCP プロトコルの実装
  • sqlite3 : SQLite データベース ドライバー
  • typescript : TypeScript サポートの開発依存関係

発達

プロジェクトに変更を加えるには:

  1. src/ディレクトリに変更を加えます
  2. プロジェクトを再構築します。
npm run build
  1. 変更をテストするにはサーバーを起動します。
npm start

ライセンス

ISC

貢献

  1. リポジトリをフォークする
  2. 機能ブランチを作成する
  3. 変更をコミットする
  4. ブランチにプッシュする
  5. 新しいプルリクエストを作成する

You must be authenticated.

A
security – no known vulnerabilities
F
license - not found
A
quality - confirmed to work

hybrid server

The server is able to function both locally and remotely, depending on the configuration or use case.

SSH 資格情報を管理および使用する機能を備え、SSH 経由での安全なリモート コマンド実行を可能にするモデル コンテキスト プロトコル サーバーの実装。

  1. 特徴
    1. 前提条件
      1. インストール
        1. Smithery経由でインストール
        2. 手動インストール
      2. 使用法
        1. 構成
        2. ツール
        3. サーバーの起動
      3. プロジェクト構造
        1. 依存関係
          1. 発達
            1. ライセンス
              1. 貢献

                Related MCP Servers

                • A
                  security
                  A
                  license
                  A
                  quality
                  A secure terminal execution server that enables controlled command execution with security features and resource limits via the Model Context Protocol (MCP).
                  Last updated -
                  1
                  12
                  1
                  JavaScript
                  MIT License
                  • Apple
                • -
                  security
                  F
                  license
                  -
                  quality
                  A secure SSH server implementation for Model Context Protocol that enables remote command execution and file operations, supporting both password and key-based authentication.
                  Last updated -
                  8
                  TypeScript
                • -
                  security
                  A
                  license
                  -
                  quality
                  A Model Context Protocol server that enables seamless execution of commands, Python code, web content fetching, and reusable task management with secure credentials handling.
                  Last updated -
                  2
                  Python
                  MIT License
                  • Apple
                • -
                  security
                  A
                  license
                  -
                  quality
                  A Model Context Protocol server that enables remote execution of shell commands across different operating systems, automatically handling platform-specific differences between Windows and Unix-like systems.
                  Last updated -
                  JavaScript
                  MIT License
                  • Linux

                View all related MCP servers

                MCP directory API

                We provide all the information about MCP servers via our MCP API.

                curl -X GET 'https://glama.ai/api/mcp/v1/servers/KinoThe-Kafkaesque/ssh-mcp-server'

                If you have feedback or need assistance with the MCP directory API, please join our Discord server