gateway-monitor-installer
功能完整的 OpenClaw Gateway 监控安装工具,安装逻辑清晰、无恶意行为,但存在文档-实现差异(未声明 API 服务器和配置恢复功能)及 restore-config 端点可修改系统配置的隐患。
为什么得出这个结论
1/4 个维度触发发现 3 项声明之外的能力或越权行为。
提取到 3 个一般风险产物,需要结合上下文判断。
没有形成明确的恶意路径。
没有完整依赖信息,供应链判断需要保留弹性。
风险分是怎么被拉高的
SKILL.md 仅声明安装/卸载,实际包含完整 API 服务器(gateway-monitor-server.js)、配置恢复等未声明功能
/api/restore-config 可通过 HTTP 请求覆盖 ~/.openclaw/openclaw.json,无额外鉴权机制
服务器监听 0.0.0.0:18990 而非仅 localhost,扩展网络攻击面
最关键的证据
SKILL.md 未声明 API 服务器功能
SKILL.md 仅描述 install/uninstall/update 功能,但 gateway-monitor-server.js 实现完整的本地 API 服务器(监听 18990 端口),提供日志流、网关状态、会话上下文等 API 端点,属于明显的文档-行为差异。
SKILL.md:1 /api/restore-config 可修改系统配置文件
restore-config 端点允许通过 GET ?confirm=true 覆盖 ~/.openclaw/openclaw.json。虽然仅限于备份文件,但攻击者(如 XSS、本地网络窃听)可触发配置恢复,可能影响 Gateway 行为。
assets/bin/gateway-monitor-server.js:580 读取 MiniMax 凭证配置文件
代码从 ~/.openclaw/agents/main/agent/auth-profiles.json 读取 API key 用于外部请求。凭证仅发送至 minimaxi.com,但端点响应中 keyMasked 会暴露脱敏 key。
assets/bin/gateway-monitor-server.js:215 API 服务器监听 0.0.0.0 扩展攻击面
gateway-monitor-server.js 绑定 0.0.0.0:18990 而非 127.0.0.1,使同一网络内其他设备可访问本地 API。
assets/bin/gateway-monitor-server.js:700 声明能力 vs 实际能力
install.sh:22-24, gateway-monitor-server.js:restore-config install.sh:50-54 launchctl commands gateway-monitor-server.js:MINIMAX_REMAINS_URL fetch gateway-monitor-server.js:MINIMAX_CP_KEY env read gateway-monitor-server.js:MINIMAX_AUTH_PROFILE_PATH read 可疑产物与外联
http://127.0.0.1:18990 SKILL.md:40
https://www.minimaxi.com/v1/api/openplatform/coding_plan/remains assets/bin/gateway-monitor-server.js:28
http://127.0.0.1:18990/api/summary scripts/status.sh:25
依赖与供应链
没有结构化依赖告警。
文件构成
assets/bin/gateway-monitor-server.js SKILL.md scripts/status.sh