Related MCP Server Resources

Explore more AI models, providers, and integration options:

  • Explore AI Models
  • Explore AI Providers
  • Explore MCP Servers
  • LangDB Pricing
  • Documentation
  • AI Industry Blog
  • MCP SSH Server
  • Azure Cosmos DB MCP Server
  • Zenn MCP Server
  • Kubectl MCP Tool
  • MongoDB MCP Server for LLMs
Back to MCP Servers
mcpcommand-linetool

mcpcommand-linetool

Public
gengzi/mcp_command-line_tool

Enables execution of local and remote commands via SSH using Java 17+, supporting password and private key authentication with selective command interception for secure Model Context Protocol operations.

javascript
0 tools
May 30, 2025
Updated Jun 4, 2025

Supercharge Your AI with mcpcommand-linetool

MCP Server

Unlock the full potential of mcpcommand-linetool through LangDB's AI Gateway. Get enterprise-grade security, analytics, and seamless integration with zero configuration.

Unified API Access
Complete Tracing
Instant Setup
Get Started Now

Free tier available • No credit card required

Instant Setup
99.9% Uptime
10,000+Monthly Requests

mcp_command-line_tool

使用spring ai框架,实现的mcp服务:用于在当前电脑执行本地命令,也可以连接远程ssh,执行远程命令

先决条件

MCP 服务器需要 Java 17 或更高版本。

安装

克隆此存储库: https://github.com/gengzi/mcp_command-line_tool

./mvn clean install

特别注意

执行命令时,仅仅拦截了rm 删除等操作,其他命令都未拦截。 如果操作不可撤销的命令时,请谨慎操作,由于是大模型来操作工具,可能操作不可撤销的命令。(有些命令不允许执行,只能手动执行)

mcp服务配置

Cherry studio config:

{ "name": "命令行工具", "type": "stdio", "description": "", "isActive": true, "command": "java", "args": [ "-jar", "本地路径/mcp_command-line_tool-0.0.1-SNAPSHOT.jar" ] }

ssh配置: 支持私钥登录,也支持密码登录

  • --ssh.passwd=密码
  • --ssh.privatekeypath=私钥文件路径"
{ "name": "命令行工具", "type": "stdio", "description": "", "isActive": true, "command": "java", "args": [ "-jar", "/Users/gengshuaijia/work/project/mcp/mcp_command-line_tool/target/mcp_command-line_tool-0.0.1-SNAPSHOT.jar", "--ssh.host=ssh.xxx地址", "--ssh.username=用户名", "--ssh.privatekeypath=私钥文件路径", "--ssh.port=22" ] }

提供的工具

!img

使用示例:

  • 本地命令行

!img !img

  • 远程命令行 !img
Publicly Shared Threads0

Discover shared experiences

Shared threads will appear here, showcasing real-world applications and insights from the community. Check back soon for updates!

Share your threads to help others
Related MCPs5
  • MCP SSH Server
    MCP SSH Server

    Secure Model Context Protocol (MCP) SSH server enabling remote command execution, file and directory...

    Added May 30, 2025
  • Azure Cosmos DB MCP Server
    Azure Cosmos DB MCP Server

    Enables seamless, secure interaction between AI language models and Azure Cosmos DB by translating n...

    Added May 30, 2025
  • Zenn MCP Server
    Zenn MCP Server

    An unofficial Model Context Protocol server for Zenn that enables fetching lists of articles and boo...

    Added May 30, 2025
  • Kubectl MCP Tool
    Kubectl MCP Tool

    Enables AI assistants to interact with Kubernetes clusters via natural language using the Model Cont...

    Added May 30, 2025
  • MongoDB MCP Server for LLMs
    MongoDB MCP Server for LLMs

    Enables LLMs to seamlessly interact with MongoDB databases via Model Context Protocol, offering sche...

    Added May 30, 2025