跳过主要内容
J

mcp-hub

jiale-cheng-ning/mcp-hub

通过单独安装的 mcp-hub Rust 程序,在 DeepSeek Harness 对话中跨客户端发现 MCP 配置、检查静态安全规则并验证指定服务的连通性。

安装

dsh plugin --profile web add github:jiale-cheng-ning/mcp-hub

README

mcp-hub

One TUI to manage all your MCP servers.

doctor and bench support modern MCP 2026-07-28 and legacy stdio/Streamable HTTP servers, with JSON and request-scoped SSE replies. Configuration migration preserves transport fields and redacts exported credentials. See the compatibility guide for supported formats, limits and tests.

sync and import refuse unreadable or malformed destination configs. Writes use a temporary file and atomic replacement, with a uniquely named <config>.<process>.<id>.bak backup of each existing destination. Backups can contain credentials; keep them private and remove older copies when no longer needed.

License: MIT Rust

You installed MCP servers in Claude Desktop, Cursor, VS Code, and Claude Code. They're scattered across different config files. Some are broken. Some have security issues. You can't see them all at once.

mcp-hub fixes that. One terminal dashboard. All your servers. 15 security rules. Zero dependencies.

mcp-hub TUI demo

What it does

FeatureDescription
TUI DashboardBrowse, inspect and filter MCP servers; switch Dark / Light themes with t
Auto-DiscoveryScans Claude Desktop, Claude Code, Cursor, Windsurf, and DeepSeek Harness ($DSH_HOME/cordis.patch.yml + profiles) configs automatically
Security Audit15 rules — typosquatting, CVE detection, postinstall scripts, shell injection, secrets, and more
MCP DoctorReal MCP protocol health checks — spawns servers, validates handshake, counts tools
BenchmarkPerformance testing — spawn time, init latency, tools/list response time per server
Registry SearchSearch the official MCP Registry and install servers with one command
Export/ImportExport configs to Git-friendly JSON, import to any client. Secrets auto-redacted.
Single BinaryOne Rust binary. No runtime. No dependencies. cargo install and go.

Install

DeepSeek Harness plugin

The repository also provides three DSH conversation tools: mcp_hub_scan, mcp_hub_audit, and mcp_hub_doctor. They use a separately installed Rust binary from this checkout and display bounded reports without raw configuration values. See DSH plugin installation and usage.

# Linux / macOS
curl -fsSL https://raw.githubusercontent.com/jiale-cheng-ning/mcp-hub/master/install.sh | sh

# Windows (PowerShell)
iwr -useb https://raw.githubusercontent.com/jiale-cheng-ning/mcp-hub/master/install.ps1 | iex

Download from GitHub Releases

Prebuilt binaries for Linux, macOS (Intel + Apple Silicon), and Windows:

Download latest release

From source (requires Rust)

cargo install --git https://github.com/jiale-cheng-ning/mcp-hub

Usage

mcp-hub              # Launch TUI dashboard
mcp-hub scan         # List all servers in a table
mcp-hub scan --json  # JSON output for scripting
mcp-hub audit        # Run security audit
mcp-hub audit --json # JSON output for CI pipelines
mcp-hub doctor       # Check real MCP protocol connectivity
mcp-hub doctor --json # JSON output for monitoring
mcp-hub bench        # Benchmark server performance (3 rounds)
mcp-hub bench --rounds 5 --server github  # Custom benchmark
mcp-hub search postgres                  # Search the MCP Registry
mcp-hub search postgres --install --target cursor  # Search and install
mcp-hub export       # Export all configs to mcp-hub.json (secrets redacted)
mcp-hub import mcp-hub.json --target cursor  # Import configs to a client
mcp-hub preset list                  # Show available preset bundles
mcp-hub preset install web-dev --target cursor  # Install a preset to a client
mcp-hub preset install web-dev --target dsh     # Install a preset to DeepSeek Harness
mcp-hub sync --from claude-desktop --to cursor  # Sync configs between clients
mcp-hub sync --from cursor --to dsh             # Sync into DeepSeek Harness

TUI keybindings

Press t on either tab to switch between Dark and Light. Text, backgrounds, selected rows, borders and severity badges use the same theme. The choice is remembered on normal exit in the OS config directory under mcp-hub/theme. Missing or invalid preferences default to Dark. Use mcp-hub --theme light or mcp-hub --theme dark to override the saved theme for one session. While searching, t is entered as normal search text.

Servers tab:

KeyAction
j / ↓Move down
k / ↑Move up
TabSwitch to Audit tab
tSwitch Dark / Light theme
q / EscQuit

Audit tab:

KeyAction
j / ↓Next finding
k / ↑Previous finding
1Toggle Critical severity
2Toggle Warning severity
3Toggle Info severity
gJump to first finding
GJump to last finding
TabSwitch to Servers tab
tSwitch Dark / Light theme
q / EscQuit

Audit rules (15)

Critical

RuleWhat it catches
TYPOSQUATTINGPackage name suspiciously similar to a known MCP server (e.g., postgress vs postgres)
POSTINSTALL_SCRIPTnpm package may run postinstall/preinstall scripts during installation
KNOWN_CVEPackage matches a known CVE (e.g., CVE-2025-6514 in mcp-remote)
DANGEROUS_COMMANDServer args contain curl|bash, rm -rf, eval, or other dangerous patterns
WORLD_READABLE_SECRETConfig file containing secrets has overly permissive file permissions

Warning

RuleWhat it catches
ENV_PLAINTEXT_SECRETAPI keys / tokens stored as plaintext in config
PERM_ROOT / PERM_HOMEFilesystem servers with unrestricted access
DEPRECATED_SERVERUsing a deprecated MCP server or package
SHELL_INJECTIONArgs contain $(), backticks, &&, `

Info

RuleWhat it catches
NO_VERSION_PINnpm packages without pinned versions
LATEST_VERSIONPinned version is 0.x — may be outdated or unstable
DUPLICATE_SERVERSame server configured in multiple clients
CONFIG_FILE_PERMSConfig file permissions are not restricted to owner-only
LICENSE_RISKPackage uses a copyleft license (AGPL/GPL)

Example: mcp-hub audit

🔴 CRITICAL (1)
  ├─ pg: Package '@modelcontextprotocol/server-postgress' looks like a typosquat of '@modelcontextprotocol/server-postgres'
  │  Fix: Verify this is the intended package. Did you mean '@modelcontextprotocol/server-postgres'?

🟡 WARNING (2)
  ├─ filesystem: Server 'filesystem' has unrestricted access to root filesystem
  │  Fix: Restrict directory scope with a specific path
  ├─ github: Potential secret 'GITHUB_PERSONAL_ACCESS_TOKEN' stored in plaintext config
  │  Fix: Use environment variable reference or secret manager

ℹ️  INFO (2)
  ├─ filesystem: Unpinned package version: '@modelcontextprotocol/server-filesystem'
  │  Fix: Pin to a specific version (e.g., @scope/pkg@1.2.0)
  ├─ github: Server 'github' duplicates 'github-cursor' (same command in Claude Desktop and Cursor)
  │  Fix: Consider using a shared configuration or removing the duplicate

Total findings: 5

Preset bundles

mcp-hub preset list                           # See all presets
mcp-hub preset install web-dev --target cursor # Install to Cursor
PresetDescriptionServers
minimalStarter packfilesystem, github
web-devWeb developmentfilesystem, github, playwright, brave-search
backendBackend / APIfilesystem, github, postgres
fullstackEverythingall of the above

GitHub Action

Audit MCP configs in CI — fail the build on security issues:

# .github/workflows/mcp-audit.yml
name: MCP Security Audit
on: [push, pull_request]

jobs:
  audit:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: jiale-cheng-ning/mcp-hub@v0.1.0
        with:
          fail-on-critical: true
InputDefaultDescription
fail-on-criticaltrueFail if critical findings detected
fail-on-warningfalseFail if warnings detected
config-pathautoCustom config file path
versionlatestmcp-hub version to use

Supported clients

ClientConfig location
Claude Desktop%APPDATA%\Claude\claude_desktop_config.json
Claude Code~/.claude.json and project .mcp.json
VS CodeOS config directory Code/User/mcp.json and project .vscode/mcp.json
Cursor~/.cursor/mcp.json
Windsurf~/.codeium/windsurf/mcp_config.json
DeepSeek Harness$DSH_HOME/cordis.patch.yml and profile patch files (default home ~/.dsh)

Roadmap

  • Auto-discovery of MCP configs across 4 clients
  • TUI dashboard with server list and detail panel
  • Security audit with 15 rules (typosquatting, CVE, shell injection, secrets, ...)
  • Health checks (process detection)
  • Severity-based filtering in TUI
  • JSON output for CI integration
  • Export/import configurations (Git-friendly, secrets auto-redacted)
  • Real MCP protocol health checks (mcp-hub doctor)
  • MCP Registry search and one-click install (mcp-hub search)
  • Server performance benchmarks (mcp-hub bench)
  • Preset server bundles (mcp-hub preset install web-dev)
  • Config sync between clients (mcp-hub sync --from claude-desktop --to cursor)
  • Real-time log viewer
  • Resource monitoring (CPU/memory)

Contributing

Contributions welcome. Open an issue first to discuss what you'd like to change.

License

MIT — see LICENSE.

相关插件