MCP SSH Server
Servidor SSH MCP
Una potente implementación de servidor SSH para el Protocolo de Contexto de Modelo (MCP). Este servidor permite la ejecución remota segura de comandos y operaciones con archivos mediante el protocolo SSH, compatible con la autenticación basada en contraseña y clave.
Características
✨ Gestión segura de conexiones SSH
🔑 Autenticación basada en contraseñas y claves
💻 Ejecución remota de comandos
📁 Operaciones con archivos (carga/descarga)
📊 Seguimiento del progreso de las transferencias de archivos
🔐 Gestión de permisos
📂 Operaciones de directorio
Transferencias masivas de archivos
📝 Registro detallado
Related MCP server: SSH MCP Server
Instalación
Instalar el paquete:
npm install mcp-sshAgregue a su configuración de escritorio de Claude (
claude_desktop_config.json):
{
"mcpServers": {
"ssh": {
"command": "node",
"args": ["%APPDATA%/npm/node_modules/mcp-ssh/dist/server.js"],
"env": {
"SSH_PORT": "8889",
"SSH_LOG_LEVEL": "info"
}
}
}
}
Uso
Autenticación de contraseña
$body = @{
id = "test"
host = "example.com"
port = 22
username = "user"
password = "pass123"
} | ConvertTo-Json
Invoke-RestMethod -Uri "http://localhost:8889/connect" -Method Post -Body $body -ContentType "application/json"Autenticación de clave
$body = @{
id = "test"
host = "example.com"
port = 22
username = "user"
privateKey = Get-Content ~/.ssh/id_rsa | Out-String
passphrase = "optional-key-passphrase" # if your key is protected
} | ConvertTo-Json
Invoke-RestMethod -Uri "http://localhost:8889/connect" -Method Post -Body $body -ContentType "application/json"Ejecutar comandos
$execBody = @{
id = "test"
command = "ls -la"
} | ConvertTo-Json
Invoke-RestMethod -Uri "http://localhost:8889/exec" -Method Post -Body $execBody -ContentType "application/json"Operaciones con archivos
# Upload file
$uploadForm = @{
file = Get-Item -Path "localfile.txt"
remotePath = "/remote/path/file.txt"
}
Invoke-RestMethod -Uri "http://localhost:8889/upload/test" -Method Post -Form $uploadForm
# Download file
Invoke-RestMethod -Uri "http://localhost:8889/download/test?remotePath=/remote/path/file.txt" -Method Get -OutFile "downloaded.txt"Operaciones de directorio
# List directory
Invoke-RestMethod -Uri "http://localhost:8889/ls/test?path=/remote/path" -Method Get
# Get connection status
Invoke-RestMethod -Uri "http://localhost:8889/status/test" -Method GetDesarrollo
Clonar el repositorio:
git clone https://github.com/shaike1/mcp-server-ssh.git
cd mcp-server-sshInstalar dependencias:
npm installConstruir:
npm run buildIniciar servidor:
npm startVariables de entorno
SSH_PORT: Puerto del servidor (predeterminado: 8889)SSH_LOG_LEVEL: Nivel de registro (predeterminado: información)
Contribuyendo
Bifurcar el repositorio
Crea tu rama de funciones (
git checkout -b feature/amazing-feature)Confirme sus cambios (
git commit -m 'Add some amazing feature')Empujar a la rama (
git push origin feature/amazing-feature)Abrir una solicitud de extracción
Licencia
Instituto Tecnológico de Massachusetts (MIT)
This server cannot be deployed
Maintenance
Related MCP Connectors
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
Scoped, audited SSH exec, sessions, and SFTP on your saved servers without exposing credentials
Enable secure connectivity between Sentry issues and debugging data, and LLM clients, using a Model Context Protocol (MCP) server.
A Model Context Protocol server for Wix AI tools
Related MCP Servers
- AlicenseAqualityCmaintenanceA Model Context Protocol server implementation that enables secure remote command execution via SSH, with features for managing and using SSH credentials.5110MIT
- AlicenseBqualityCmaintenanceA server that enables remote command execution over SSH through the Model Context Protocol (MCP), supporting both password and private key authentication.112MIT
- FlicenseAqualityDmaintenanceA local Model Context Protocol server that allows LLMs to securely execute shell commands on remote Linux and Windows systems via SSH connections.6252-
- AlicenseAqualityAmaintenanceA Model Context Protocol server that allows LLMs to securely execute shell commands on remote Linux and Windows systems via SSH. It supports password and key-based authentication, command timeouts, and sudo elevation for administrative tasks.117,828714MIT