This report was generated in Chinese. Some content may be in Chinese.
Suspicious — Risk Score 40/100
Last scan:4 hr ago Rescan
40 /100
wip-readme-format
Reformat any repo's README to follow the WIP Computer standard. Agent-first, human-readable.
README格式化工具存在文档-行为差异:声明filesystem权限为NONE但实际执行WRITE操作,同时动态导入child_process模块执行git命令检查文件状态。
Skill Namewip-readme-format
Duration45.9s
Enginepi
ClawHub Wip Readme Format v1.9.68 by parkertoddbrooks
📥 605
ClawHub Verdict Suspicious dangerous_exec
Use with caution
补充声明filesystem:WRITE和可能的shell:READ权限;考虑使用显式导入替代动态导入child_process;添加依赖模块wip-universal-installer的来源验证。

Findings 4 items

Severity Finding Location
Medium
未声明的文件系统写入权限 Priv Escalation
SKILL.md声明filesystem为NONE,但format.mjs执行writeFileSync写入README-init-*.md、README.md和TECHNICAL.md,另有mkdirSync创建ai/_trash目录、unlinkSync删除临时文件。
writeFileSync(initPath(repoPath, section), sections[section] + '\n');
→ 在SKILL.md的capabilities或allowed-tools中声明Write权限,说明工具会生成和修改README文件
format.mjs:310
Medium
动态导入child_process模块 Obfuscation
format.mjs第322行使用await import('node:child_process')动态导入模块,在DEPLOY模式下执行git status命令检查文件状态。动态导入可能意图规避静态分析。
const { execSync } = await import('node:child_process');
→ 使用静态import声明或将git检查逻辑改为Node.js原生API实现
format.mjs:322
Low
外部依赖模块来源未声明 Supply Chain
format.mjs从../wip-universal-installer/detect.mjs导入detectInterfaces和detectToolbox函数。该模块的功能和安全性未在SKILL.md中说明。
import { detectInterfaces, detectToolbox } from '../wip-universal-installer/detect.mjs';
→ 在SKILL.md的requires.dependencies中声明此依赖,或说明其用途和来源可信性
format.mjs:27
Low
shields.io外部URL引用 Doc Mismatch
代码生成shields.io badge URLs用于README,包含外部链接。预扫描标记为medium risk。
const badge = `https://img.shields.io/badge/interface-${label}-black`;
→ 确认这些URL仅用于生成静态链接,非主动请求。当前实现仅生成URL无HTTP请求,风险可接受
format.mjs:82
ResourceDeclaredInferredStatusEvidence
Filesystem NONE WRITE ✗ Violation format.mjs:310 writeFileSync写入README-init-*.md, format.mjs:370 writeFileSync写入RE…
Shell NONE READ ✗ Violation format.mjs:322 await import('node:child_process'), format.mjs:334 execSync('git …
Network NONE READ ✓ Aligned 仅生成shields.io badge URLs,无实际HTTP请求
Skill Invoke NONE NONE 导入外部模块detectInterfaces但仅用于检测接口类型
2 findings
🔗
Medium External URL 外部 URL
https://img.shields.io/badge/interface-$
format.mjs:82
🔗
Medium External URL 外部 URL
https://img.shields.io/badge/Universal_Interface_Spec-black?style=flat&color=black
format.mjs:506

File Tree

4 files · 24.4 KB · 745 lines
JavaScript 1f · 597L Markdown 2f · 133L JSON 1f · 15L
├─ 📜 format.mjs JavaScript 597L · 20.6 KB
├─ 📋 package.json JSON 15L · 461 B
├─ 📝 README.md Markdown 49L · 1.5 KB
└─ 📝 SKILL.md Markdown 84L · 1.9 KB

Dependencies 4 items

PackageVersionSourceKnown VulnsNotes
wip-universal-installer/detect.mjs unknown local sibling module No 内部依赖,来源为同仓库tools目录
node:fs bundled node built-in No Node.js标准库,用于文件读写
node:path bundled node built-in No Node.js标准库,用于路径处理
node:child_process bundled node built-in No 动态导入,用于git status命令执行

Security Positives

✓ 代码结构清晰,主要功能为纯文本处理和文件生成
✓ 包含dry-run和--check模式,允许预览和验证而不实际写入
✓ DEPLOY模式有安全检查:阻止未审查的init文件直接部署
✓ 自动备份旧文件到ai/_trash/目录,防止数据丢失
✓ 无凭证读取、无数据外传、无网络主动请求
✓ 依赖简单(Node.js标准库为主),攻击面较小