← 返回 Skills 市场
4ier

mihomo Proxy Manager

作者 傅洋 · GitHub ↗ · v0.2.0 · MIT-0
cross-platform ⚠ suspicious
115
总下载
0
收藏
0
当前安装
2
版本数
在 OpenClaw 中安装
/install claw-use-mihomo
功能描述
Manage mihomo proxy - install, configure from subscriptions, monitor health, auto-switch nodes. Supports vmess/ss/trojan/vless protocols.
使用说明 (SKILL.md)

claw-use-mihomo

Manage mihomo proxy: install, configure from subscriptions, monitor health, auto-switch nodes.

When to use

  • User asks to set up a proxy/VPN on their machine
  • User provides a subscription URL, vmess://, ss://, trojan://, or vless:// link
  • Proxy stops working and needs diagnosis/fix
  • User wants to switch proxy nodes or check status

Prerequisites

  • Node.js >= 18
  • Network access to download mihomo binary

Setup

npx mihomod install

Commands

Install mihomo

npx mihomod install

Configure from subscription

npx mihomod config "https://example.com/subscribe?token=xxx"

Config is validated (YAML parse + structure check) before writing. Old config is backed up to .bak.

Add single node

npx mihomod add "vmess://eyJ..."
npx mihomod add "ss://..."
npx mihomod add "trojan://..."
npx mihomod add "vless://..."

Start/stop mihomo

npx mihomod start
npx mihomod stop

Check status

npx mihomod status --json

Returns: {"running":true,"node":"...","delay":150,"alive":42,"total":50}

List nodes

npx mihomod nodes --json

Switch node

npx mihomod switch              # auto-select best
npx mihomod switch "node-name"  # specific node

Start watchdog

npx mihomod watch

Monitors endpoints, auto-switches on failure. Outputs JSON events to stdout. Handles SIGTERM/SIGINT gracefully.

Config

Located at ~/.config/mihomod/config.json. Created automatically on first run. Edit to set mihomo API URL, watchdog endpoints, node priorities, etc.

Safety

  • Config writes are atomic: write to .tmp → validate YAML + structure → rename (old config backed up to .bak)
  • Subscription content is validated before writing — malformed YAML is rejected
  • All network calls have timeouts (API: 5s, subscriptions: 30s, downloads: 120s)
  • Subscription downloads capped at 10MB

All output is JSON

All commands output structured JSON (human-readable on TTY). Exit codes: 0=success, 1=error, 2=config error, 3=network error.

安全使用建议
This skill appears to do what it says: it downloads the mihomo release from GitHub, writes config files under your home config directory, and can install a systemd/launchd service (it may prompt for sudo). Consider these before installing: (1) installing will place and execute a downloaded binary — verify the upstream project/release and checksum if possible; (2) the installer may attempt to write a system service and request sudo, and the service unit requests network capabilities (CAP_NET_ADMIN/CAP_NET_RAW) which are powerful; (3) run the installer in a controlled environment (VM/container) or inspect the downloaded asset first if you distrust the upstream binary; (4) SKILL.md does not mention the sudo/systemd actions explicitly, so expect privilege escalation during installation. If you want minimal risk, use the skill only to generate config files (config/add) and avoid running the install/start commands that install/execute the mihomo binary.
功能分析
Type: OpenClaw Skill Name: claw-use-mihomo Version: 0.2.0 The skill manages the Mihomo proxy and includes high-risk capabilities such as downloading and executing binaries from GitHub (src/install.js) and installing system-level persistence via systemd or launchd (src/install.js, src/service.js). While these actions are aligned with the stated purpose of a proxy manager and the code includes safety measures like atomic configuration writes and YAML validation (src/configure.js), the automated execution of remote payloads and requests for elevated privileges (sudo) are inherently risky. No evidence of intentional malice, data exfiltration, or obfuscation was found.
能力评估
Purpose & Capability
Name/description match implementation: code implements installing mihomo, parsing subscriptions (vmess/ss/trojan/vless), generating YAML configs, starting/stopping the daemon and running a watchdog. No unrelated credentials, binaries, or config paths are requested.
Instruction Scope
SKILL.md instructions accurately reflect runtime behavior (install, config, add, start/stop, watch). One omission: SKILL.md does not explicitly say that installing may require sudo or will create system services/launch agents; the code attempts to write systemd unit files (via sudo tee) and/or user launch agents.
Install Mechanism
No OpenClaw install spec, but the package code downloads binaries from GitHub releases (https://api.github.com/repos/MetaCubeX/mihomo/releases/latest) and extracts them locally — GitHub releases is a standard host, but this involves extracting and placing executables on disk and running shell tools (gunzip/unzip/mv).
Credentials
The skill requests no special environment variables or secrets. It uses standard OS config paths (XDG_CONFIG_HOME/APPDATA) and home directory. It does reference process.env values for locating config dirs but does not require unrelated credentials.
Persistence & Privilege
The skill does not force permanent inclusion (always:false). However, the installer can create system-level services (writes to /etc/systemd/system via sudo) or user launch agents and may set service capabilities (AmbientCapabilities in the unit). Installing as a service or extracting an executable requires elevated actions and is therefore privileged in effect.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install claw-use-mihomo
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /claw-use-mihomo 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v0.2.0
v0.2.0: Hardening release — atomic config writes, YAML validation, timeouts, shell injection fixes, graceful shutdown. 15 issues fixed.
v0.1.0
Initial release of claw-use-mihomo. - Install and configure mihomo proxy from subscription or single node links. - Supports vmess, ss, trojan, and vless protocols. - Start, stop, and monitor mihomo proxy status with JSON output. - Automatic node switching with watchdog for improved reliability. - All commands provide structured JSON responses and clear exit codes.
元数据
Slug claw-use-mihomo
版本 0.2.0
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 2
常见问题

mihomo Proxy Manager 是什么?

Manage mihomo proxy - install, configure from subscriptions, monitor health, auto-switch nodes. Supports vmess/ss/trojan/vless protocols. 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 115 次。

如何安装 mihomo Proxy Manager?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install claw-use-mihomo」即可一键安装,无需额外配置。

mihomo Proxy Manager 是免费的吗?

是的,mihomo Proxy Manager 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

mihomo Proxy Manager 支持哪些平台?

mihomo Proxy Manager 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 mihomo Proxy Manager?

由 傅洋(@4ier)开发并维护,当前版本 v0.2.0。

💬 留言讨论