SSH Commander

by kinothe-kafkaesque

2 stars
Not rated
GitHub

About

Enables secure remote server management by executing SSH commands using stored credentials in a SQLite database, providing tools for command execution and credential management without leaving the conversation interface.

Details

Author
kinothe-kafkaesque
Repository
KinoThe-Kafkaesque/ssh-mcp-server
GitHub stars
2
License
MIT License
Categories
Productivity, Design, Developer Tools, AI, Project Management, Infrastructure, Database

- SSH server implementation using MCP protocol
- SQLite database integration for data persistence
- TypeScript implementation for type safety and better development experience

Setting up with Highlight

This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:

  1. Download and install Highlight from highlightai.com/download
  2. Navigate to the plugins tab and select "Add Custom Plugin"
  3. Configure the plugin with the settings below
    Plugin Name SSH Commander
    Command (node, npx, python, etc.) npx
    Arguments
    • Argument 1 -y
    • Argument 2 @highlight/mcp-server

    Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.

  4. Enable "Start Automatically" if you want the plugin to start when Highlight launches

From the repository

The server uses a SQLite database (ssh.db) to store SSH credentials. The
database file will be created automatically when the server starts.

To install SSH Server for Claude Desktop automatically via Smithery:

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

1. Clone the repository:

git clone <repository-url>
cd ssh-server

2. Install dependencies:

npm install

3. Build the project:

npm run build

add_credential

Save a new SSH credential with the specified name, host, username, and private key path.

list_credentials

List all stored SSH credential records.

remove_credential

Delete an SSH credential by its name.

ssh_exec

Run a shell command using the specified credential name, command, and timeout.

ssh_exec_raw

Run a command as an argv-style command array using the specified credential name.

scp_copy

Copy a file over SFTP using the specified credential name, local path, remote path, and direction.

rsync_copy

Copy directories or larger trees using rsync with the same transfer shape.

ssh_session_start

Start an interactive SSH session.

ssh_session_send

Send data in an active SSH session.

ssh_session_read

Read data from an active SSH session.

ssh_session_end

End an interactive SSH session.

ssh_session_list

List all active SSH sessions.

ssh_tunnel_start

Start a local or remote port-forwarding tunnel.

ssh_tunnel_list

List all active SSH tunnels.

ssh_tunnel_stop

Stop an active SSH tunnel.

The server stores named credentials, then every remote action refers to a
credentialName. privateKeyPath must point to an existing private key.

- add_credential: save { "name", "host", "username", "privateKeyPath" }.
- list_credentials: list stored credential records.
- remove_credential: delete { "name" }.
- ssh_exec: run a shell command with { "credentialName", "command", "timeout" }.
- ssh_exec_raw: run an argv-style command array, for example { "credentialName": "prod", "command": ["grep", "-E", "foo|bar", "/var/log/app.log"] }.
- scp_copy: copy one file over SFTP with { "credentialName", "localPath", "remotePath", "direction" }.
- rsync_copy: copy directories or larger trees with rsync and the same transfer shape.
- ssh_session_start, ssh_session_send, ssh_session_read, ssh_session_end, ssh_session_list: manage interactive SSH sessions.
- ssh_tunnel_start, ssh_tunnel_list, ssh_tunnel_stop: manage local or remote port-forwarding tunnels.

Claude Desktop / Cursor

Paste into your MCP client config file to install this server.

{
    "mcpServers": {
        "ssh commander": {
            "env": {},
            "args": [
                "-y",
                "@highlight/mcp-server"
            ],
            "command": "npx"
        }
    }
}

Linux

{
    "env": [],
    "args": [
        "-y",
        "@highlight/mcp-server"
    ],
    "command": "npx"
}

Macos

{
    "env": [],
    "args": [
        "-y",
        "@highlight/mcp-server"
    ],
    "command": "npx"
}

Windows

{
    "env": [],
    "args": [
        "/c",
        "npx",
        "-y",
        "@highlight/mcp-server"
    ],
    "command": "cmd"
}

SSH MCP Server

smithery badge

A Model Context Protocol (MCP) server implementation that provides SSH
capabilities. This server allows for secure remote access and execution through
the MCP protocol.

Features

- SSH server implementation using MCP protocol
- SQLite database integration for data persistence
- TypeScript implementation for type safety and better development experience

Prerequisites

- Node.js 18 or higher
- npm or yarn package manager
- TypeScript knowledge for development

Installation

Installing via Smithery

To install SSH Server for Claude Desktop automatically via Smithery:

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

Manual Installation

1. Clone the repository:
git clone <repository-url>
cd ssh-server

2. Install dependencies:

npm install

3. Build the project:

npm run build

Usage

Configuration

The server uses a SQLite database (ssh.db) to store SSH credentials. The
database file will be created automatically when the server starts.

Tools

The server stores named credentials, then every remote action refers to a
credentialName. privateKeyPath must point to an existing private key.

- add_credential: save { "name", "host", "username", "privateKeyPath" }.
- list_credentials: list stored credential records.
- remove_credential: delete { "name" }.
- ssh_exec: run a shell command with { "credentialName", "command", "timeout" }.
- ssh_exec_raw: run an argv-style command array, for example { "credentialName": "prod", "command": ["grep", "-E", "foo|bar", "/var/log/app.log"] }.
- scp_copy: copy one file over SFTP with { "credentialName", "localPath", "remotePath", "direction" }.
- rsync_copy: copy directories or larger trees with rsync and the same transfer shape.
- ssh_session_start, ssh_session_send, ssh_session_read, ssh_session_end, ssh_session_list: manage interactive SSH sessions.
- ssh_tunnel_start, ssh_tunnel_list, ssh_tunnel_stop: manage local or remote port-forwarding tunnels.

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.