@elliotllliu/agentshield 0.2.0 → 0.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/README.md +167 -107
  2. package/README.zh-CN.md +95 -32
  3. package/package.json +42 -3
package/README.md CHANGED
@@ -1,8 +1,25 @@
1
1
  # 🛡️ AgentShield
2
2
 
3
- Security scanner for AI agent skills, MCP servers, and plugins.
3
+ **Security scanner for AI agent skills, MCP servers, and plugins.**
4
4
 
5
- Catch data exfiltration, backdoors, privilege escalation, and supply chain vulnerabilities **before** they reach your agents.
5
+ [![npm](https://img.shields.io/npm/v/@elliotllliu/agentshield)](https://www.npmjs.com/package/@elliotllliu/agentshield)
6
+ [![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](LICENSE)
7
+
8
+ Catch data exfiltration, backdoors, privilege escalation, credential leaks, and supply chain vulnerabilities **before** they reach your AI agents.
9
+
10
+ > **We scanned the top ClawHub skill repos — the average security score was 47/100.** [Read the full report →](docs/clawhub-security-report.md)
11
+
12
+ ## Why AgentShield?
13
+
14
+ AI agents install and execute third-party skills, MCP servers, and plugins with minimal security review. A single malicious skill can:
15
+
16
+ - 🔑 **Steal credentials** — SSH keys, AWS secrets, API tokens
17
+ - 📤 **Exfiltrate data** — read sensitive files and send them to external servers
18
+ - 💀 **Open backdoors** — `eval()`, reverse shells, dynamic code execution
19
+ - ⛏️ **Mine crypto** — hijack compute for cryptocurrency mining
20
+ - 🕵️ **Bypass permissions** — claim "read-only" but execute shell commands
21
+
22
+ AgentShield catches these patterns with **16 security rules** in under 50ms.
6
23
 
7
24
  ## Quick Start
8
25
 
@@ -10,27 +27,55 @@ Catch data exfiltration, backdoors, privilege escalation, and supply chain vulne
10
27
  npx @elliotllliu/agentshield scan ./my-skill/
11
28
  ```
12
29
 
13
- ## What It Detects
14
-
15
- | Rule | Severity | Description |
16
- |------|----------|-------------|
17
- | `data-exfil` | 🔴 Critical | Reads sensitive files (SSH keys, credentials) + sends HTTP requests |
18
- | `backdoor` | 🔴 Critical | `eval()`, `new Function()`, `child_process.exec()` with dynamic input |
19
- | `reverse-shell` | 🔴 Critical | Outbound socket connections piped to shell |
20
- | `crypto-mining` | 🔴 Critical | Mining pool connections, known miners (xmrig, coinhive) |
21
- | `credential-hardcode` | 🔴 Critical | Hardcoded AWS keys, GitHub PATs, Stripe keys, private keys |
22
- | `env-leak` | 🔴 Critical | `process.env` access + outbound HTTP (environment variable exfil) |
23
- | `obfuscation` | 🔴 Critical | base64 + eval combos, hex-encoded strings, `String.fromCharCode` |
24
- | `typosquatting` | 🔴 Critical | Suspicious npm package names (e.g. `1odash` instead of `lodash`) |
25
- | `hidden-files` | 🔴 Critical | `.env` files with secrets committed to repo |
26
- | `network-ssrf` | 🟡 Warning | User-controlled URLs in fetch, AWS metadata endpoint access |
27
- | `privilege` | 🟡 Warning | SKILL.md declares `read` but code calls `exec` |
28
- | `supply-chain` | 🟡 Warning | Known CVEs in npm dependencies (`npm audit`) |
29
- | `sensitive-read` | 🟡 Warning | Accesses `~/.ssh/id_rsa`, `~/.aws/credentials`, etc. |
30
- | `excessive-perms` | 🟡 Warning | Too many or dangerous permissions in SKILL.md |
31
- | `phone-home` | 🟡 Warning | Periodic timers + HTTP requests (beacon/heartbeat pattern) |
32
- | `mcp-manifest` | 🟡 Warning | MCP server: wildcard perms, undeclared capabilities, suspicious tool descriptions |
33
- | `mcp-manifest` | 🟡 Warning | MCP server tool/resource declarations vs actual code behavior |
30
+ No installation required. Works with Node.js 18+.
31
+
32
+ ## What It Detects 16 Security Rules
33
+
34
+ ### 🔴 Critical (auto-fail)
35
+
36
+ | Rule | Detects |
37
+ |------|---------|
38
+ | `data-exfil` | Reads sensitive files + sends HTTP requests (exfiltration pattern) |
39
+ | `backdoor` | `eval()`, `new Function()`, `child_process.exec()` with dynamic input |
40
+ | `reverse-shell` | Outbound socket connections piped to `/bin/sh` |
41
+ | `crypto-mining` | Mining pool connections, xmrig, coinhive patterns |
42
+ | `credential-hardcode` | Hardcoded AWS keys (`AKIA...`), GitHub PATs (`ghp_...`), Stripe keys |
43
+ | `env-leak` | `process.env` secrets + outbound HTTP (environment variable theft) |
44
+ | `obfuscation` | `eval(atob(...))`, hex strings, `String.fromCharCode` obfuscation |
45
+ | `typosquatting` | Suspicious npm names: `1odash` `lodash`, `axois` `axios` |
46
+ | `hidden-files` | `.env` files with `PASSWORD`, `SECRET`, `API_KEY` committed to repo |
47
+
48
+ ### 🟡 Warning (review recommended)
49
+
50
+ | Rule | Detects |
51
+ |------|---------|
52
+ | `network-ssrf` | User-controlled URLs in fetch, AWS metadata endpoint access |
53
+ | `privilege` | SKILL.md permissions vs actual code behavior mismatch |
54
+ | `supply-chain` | Known CVEs in npm dependencies (`npm audit`) |
55
+ | `sensitive-read` | Access to `~/.ssh/id_rsa`, `~/.aws/credentials`, `~/.kube/config` |
56
+ | `excessive-perms` | Too many or dangerous permissions in SKILL.md |
57
+ | `phone-home` | `setInterval` + HTTP requests (beacon/C2 heartbeat pattern) |
58
+ | `mcp-manifest` | MCP server: wildcard perms, undeclared capabilities, suspicious tool descriptions |
59
+
60
+ ## Real-World Results
61
+
62
+ We scanned the **top 9 ClawHub skill repositories** (700K+ combined installs):
63
+
64
+ | Repository | Installs | Score | Risk |
65
+ |------------|----------|-------|------|
66
+ | vercel-labs/agent-skills | 157K | 🔴 0/100 | Critical — deploy scripts with `$(curl)` command substitution |
67
+ | obra/superpowers | 94K | 🔴 0/100 | Critical — dynamic code execution in render scripts |
68
+ | coreyhaines31/marketingskills | 42K | 🔴 0/100 | Critical — 122 critical findings (CRM credential patterns) |
69
+ | anthropics/skills | 36K | 🔴 35/100 | Critical — template with exec() |
70
+ | expo/skills | 11K | 🔴 5/100 | Critical — fetch script reads env vars |
71
+ | remotion-dev/skills | 140K | 🟡 80/100 | Moderate — minor warnings |
72
+ | google-labs-code/stitch-skills | 63K | ✅ 100/100 | Clean |
73
+ | supercent-io/skills-template | 106K | ✅ 100/100 | Clean |
74
+ | squirrelscan/skills | 34K | ✅ 100/100 | Clean |
75
+
76
+ **Average score: 47/100** — over half of popular skill repos have critical security findings.
77
+
78
+ [📊 Full security report →](docs/clawhub-security-report.md)
34
79
 
35
80
  ## Example Output
36
81
 
@@ -39,80 +84,47 @@ npx @elliotllliu/agentshield scan ./my-skill/
39
84
  📁 Scanned: ./my-skill/ (3 files, 44 lines)
40
85
 
41
86
  🔴 CRITICAL (3)
42
- ├─ index.ts:13 — [data-exfil] Reads sensitive data and sends HTTP request — possible exfiltration
87
+ ├─ index.ts:13 — [data-exfil] Reads sensitive data and sends HTTP request
43
88
  ├─ index.ts:20 — [backdoor] eval() with dynamic input
44
- └─ index.ts:25 — [backdoor] child_process.exec() use execFile instead
89
+ └─ backdoor.sh:6 — [backdoor] shell eval with variable
45
90
 
46
91
  🟡 WARNING (2)
47
92
  ├─ index.ts:23 — [privilege] Code uses 'exec' but SKILL.md doesn't declare it
48
93
  └─ index.ts:6 — [sensitive-read] Accesses SSH private key
49
94
 
50
- 🟢 INFO (1)
51
- └─ SKILL.md — [privilege] Detected capabilities: exec, read, web_fetch
52
-
53
95
  ✅ Score: 0/100 (Critical Risk)
96
+ ⏱ 16ms
54
97
  ```
55
98
 
56
99
  ## Usage
57
100
 
58
101
  ```bash
59
102
  # Scan a directory
60
- agentshield scan ./path/to/skill/
103
+ npx @elliotllliu/agentshield scan ./path/to/skill/
61
104
 
62
- # JSON output (for CI/CD)
63
- agentshield scan ./skill/ --json
105
+ # JSON output (for CI/CD pipelines)
106
+ npx @elliotllliu/agentshield scan ./skill/ --json
64
107
 
65
- # Fail CI if score is below threshold
66
- agentshield scan ./skill/ --fail-under 70
108
+ # Fail CI if score drops below threshold
109
+ npx @elliotllliu/agentshield scan ./skill/ --fail-under 70
67
110
 
68
111
  # Disable specific rules
69
- agentshield scan ./skill/ --disable supply-chain,phone-home
112
+ npx @elliotllliu/agentshield scan ./skill/ --disable supply-chain,phone-home
70
113
 
71
114
  # Only run specific rules
72
- agentshield scan ./skill/ --enable backdoor,data-exfil
73
-
74
- # Shorthand (directory as first arg)
75
- agentshield ./skill/
115
+ npx @elliotllliu/agentshield scan ./skill/ --enable backdoor,data-exfil
76
116
 
77
117
  # Generate config files
78
- agentshield init
118
+ npx @elliotllliu/agentshield init
79
119
 
80
- # Watch mode (re-scan on changes)
81
- agentshield watch ./skill/
120
+ # Watch mode re-scan on file changes
121
+ npx @elliotllliu/agentshield watch ./skill/
82
122
 
83
123
  # Compare two versions
84
- agentshield compare ./skill-v1/ ./skill-v2/
85
- ```
86
-
87
- ## Configuration
88
-
89
- Create `.agentshield.yml` in your project (or run `agentshield init`):
90
-
91
- ```yaml
92
- rules:
93
- disable:
94
- - supply-chain # skip npm audit
95
- - phone-home # allow periodic HTTP
96
-
97
- severity:
98
- sensitive-read: info # downgrade to info
99
-
100
- failUnder: 70 # CI threshold
124
+ npx @elliotllliu/agentshield compare ./skill-v1/ ./skill-v2/
101
125
 
102
- ignore:
103
- - "tests/**"
104
- - "*.test.ts"
105
- ```
106
-
107
- ### `.agentshieldignore`
108
-
109
- Exclude files from scanning (same syntax as `.gitignore`):
110
-
111
- ```
112
- node_modules/
113
- dist/
114
- *.test.ts
115
- __tests__/
126
+ # Generate a security badge for your README
127
+ npx @elliotllliu/agentshield badge ./skill/
116
128
  ```
117
129
 
118
130
  ## CI Integration
@@ -141,55 +153,103 @@ jobs:
141
153
  run: npx -y @elliotllliu/agentshield scan ./skills/ --fail-under 70
142
154
  ```
143
155
 
144
- ### Action Inputs
156
+ ### Action Inputs & Outputs
145
157
 
146
158
  | Input | Default | Description |
147
159
  |-------|---------|-------------|
148
160
  | `path` | `.` | Directory to scan |
149
- | `fail-under` | *(none)* | Fail if score is below threshold (0-100) |
150
- | `format` | `terminal` | Output format: `terminal` or `json` |
151
-
152
- ### Action Outputs
161
+ | `fail-under` | | Fail if score < threshold (0-100) |
162
+ | `format` | `terminal` | `terminal` or `json` |
153
163
 
154
164
  | Output | Description |
155
165
  |--------|-------------|
156
166
  | `score` | Security score (0-100) |
157
167
  | `findings` | Number of findings |
158
168
 
169
+ ## Configuration
170
+
171
+ Create `.agentshield.yml` (or run `agentshield init`):
172
+
173
+ ```yaml
174
+ rules:
175
+ disable:
176
+ - supply-chain # skip npm audit
177
+ - phone-home # allow periodic HTTP
178
+
179
+ severity:
180
+ sensitive-read: info # downgrade to info
181
+
182
+ failUnder: 70 # CI threshold
183
+
184
+ ignore:
185
+ - "tests/**"
186
+ - "*.test.ts"
187
+ ```
188
+
189
+ ### `.agentshieldignore`
190
+
191
+ ```
192
+ node_modules/
193
+ dist/
194
+ *.test.ts
195
+ __tests__/
196
+ ```
197
+
159
198
  ## Scoring
160
199
 
161
- Starts at 100, deducts per finding:
200
+ | Severity | Points Deducted |
201
+ |----------|----------------|
202
+ | 🔴 Critical | -25 |
203
+ | 🟡 Warning | -10 |
204
+ | 🟢 Info | 0 |
205
+
206
+ | Score | Risk Level | Recommendation |
207
+ |-------|------------|----------------|
208
+ | 90-100 | ✅ Low Risk | Safe to install |
209
+ | 70-89 | 🟡 Moderate | Review warnings |
210
+ | 40-69 | 🟠 High Risk | Investigate before using |
211
+ | 0-39 | 🔴 Critical | Do not install |
212
+
213
+ ## Supported Platforms
214
+
215
+ - **AI Agent Skills** — OpenClaw, Codex, Claude Code
216
+ - **MCP Servers** — Model Context Protocol tool servers
217
+ - **npm Packages** — any npm package with executable code
218
+ - **General** — any directory with JS/TS/Python/Shell code
219
+
220
+ ### Supported File Types
162
221
 
163
- | Severity | Deduction |
222
+ | Language | Extensions |
164
223
  |----------|-----------|
165
- | Critical | -25 |
166
- | Warning | -10 |
167
- | Info | 0 |
168
-
169
- | Score | Risk Level |
170
- |-------|------------|
171
- | 90-100 | Low Risk ✅ |
172
- | 70-89 | Moderate Risk 🟡 |
173
- | 40-69 | High Risk 🟠 |
174
- | 0-39 | Critical Risk 🔴 |
175
-
176
- ## Supported File Types
177
-
178
- - **JavaScript/TypeScript**: `.js`, `.ts`, `.mjs`, `.cjs`, `.tsx`, `.jsx`
179
- - **Python**: `.py`
180
- - **Shell**: `.sh`, `.bash`, `.zsh`
181
- - **Config**: `.json`, `.yaml`, `.yml`, `.toml`
182
- - **Docs**: `SKILL.md` (permission analysis)
183
-
184
- ## Roadmap
185
-
186
- - [ ] AST-based analysis (tree-sitter for multi-language support)
187
- - [ ] MCP server manifest validation
188
- - [ ] Custom rule plugins
189
- - [ ] `agentshield init` — generate security policy
190
- - [ ] Sarif output for GitHub Code Scanning
191
- - [ ] Python `pip-audit` integration
192
- - [ ] Watch mode for development
224
+ | JavaScript/TypeScript | `.js`, `.ts`, `.mjs`, `.cjs`, `.tsx`, `.jsx` |
225
+ | Python | `.py` |
226
+ | Shell | `.sh`, `.bash`, `.zsh` |
227
+ | Config | `.json`, `.yaml`, `.yml`, `.toml` |
228
+ | Docs | `SKILL.md` (permission analysis) |
229
+
230
+ ## Comparison with Other Tools
231
+
232
+ | Feature | AgentShield | npm audit | Snyk | ESLint Security |
233
+ |---------|------------|-----------|------|-----------------|
234
+ | AI skill/MCP specific rules | ✅ | ❌ | ❌ | ❌ |
235
+ | Data exfiltration detection | ✅ | ❌ | ❌ | ❌ |
236
+ | Permission mismatch (SKILL.md) | ✅ | ❌ | ❌ | ❌ |
237
+ | Credential hardcode detection | | ❌ | ✅ | ✅ |
238
+ | Supply chain CVEs | ✅ | ✅ | ✅ | ❌ |
239
+ | Zero config | ✅ | ✅ | ❌ | ❌ |
240
+ | No API key required | ✅ | ✅ | ❌ | ✅ |
241
+ | < 50ms scan time | ✅ | ❌ | ❌ | ❌ |
242
+
243
+ ## Contributing
244
+
245
+ See [CONTRIBUTING.md](CONTRIBUTING.md) for how to add new rules.
246
+
247
+ ## Links
248
+
249
+ - 📦 [npm](https://www.npmjs.com/package/@elliotllliu/agentshield)
250
+ - 📖 [Rule Documentation](docs/rules.md)
251
+ - 📊 [ClawHub Security Report](docs/clawhub-security-report.md)
252
+ - 🇨🇳 [中文 README](README.zh-CN.md)
193
253
 
194
254
  ## License
195
255
 
package/README.zh-CN.md CHANGED
@@ -1,8 +1,23 @@
1
- # 🛡️ AgentShield
1
+ # 🛡️ AgentShield — AI Agent 安全扫描器
2
2
 
3
- AI Agent 技能/插件安全扫描器
3
+ [![npm](https://img.shields.io/npm/v/@elliotllliu/agentshield)](https://www.npmjs.com/package/@elliotllliu/agentshield)
4
+ [![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](LICENSE)
4
5
 
5
- 在安装第三方 AI 技能之前,扫描数据窃取、后门、权限越界和供应链漏洞。
6
+ 专为 AI Agent 技能、MCP Server、插件设计的安全扫描工具。在安装第三方扩展之前,检测数据窃取、后门、凭证泄露和供应链漏洞。
7
+
8
+ > **我们扫描了 ClawHub 热门 skill 仓库 — 平均安全分仅 47/100。** [查看完整报告 →](docs/clawhub-security-report.md)
9
+
10
+ ## 为什么需要 AgentShield?
11
+
12
+ AI Agent 会安装并执行第三方技能和插件,安全审查几乎为零。一个恶意 skill 就能:
13
+
14
+ - 🔑 **偷凭证** — SSH 密钥、AWS Secret、API Token
15
+ - 📤 **外泄数据** — 读取敏感文件发送到外部服务器
16
+ - 💀 **植入后门** — eval()、反弹 Shell、动态代码执行
17
+ - ⛏️ **挖矿** — 利用你的算力挖加密货币
18
+ - 🕵️ **越权** — 声称只读但实际执行 Shell 命令
19
+
20
+ AgentShield 用 **16 条安全规则**在 50ms 内检出这些威胁。
6
21
 
7
22
  ## 快速开始
8
23
 
@@ -10,37 +25,77 @@ AI Agent 技能/插件安全扫描器
10
25
  npx @elliotllliu/agentshield scan ./my-skill/
11
26
  ```
12
27
 
13
- ## 检测能力
14
-
15
- | 规则 | 级别 | 说明 |
16
- |------|------|------|
17
- | `data-exfil` | 🔴 严重 | 读取敏感文件 + 发送 HTTP 请求(数据外泄) |
18
- | `backdoor` | 🔴 严重 | `eval()`、`exec()`、动态代码执行 |
19
- | `reverse-shell` | 🔴 严重 | Socket 外连 + Shell 管道(反弹 Shell) |
20
- | `crypto-mining` | 🔴 严重 | 挖矿池连接、已知挖矿程序 |
21
- | `credential-hardcode` | 🔴 严重 | 硬编码 AWS Key、GitHub PAT、Stripe Key |
22
- | `env-leak` | 🔴 严重 | 环境变量读取 + HTTP 外发 |
23
- | `obfuscation` | 🔴 严重 | base64+eval 混淆、十六进制编码 |
24
- | `typosquatting` | 🔴 严重 | npm 包名拼写仿冒(如 `1odash`) |
25
- | `hidden-files` | 🔴 严重 | `.env` 文件包含明文密钥 |
26
- | `network-ssrf` | 🟡 警告 | 用户可控 URL、SSRF、AWS 元数据端点 |
27
- | `privilege` | 🟡 警告 | SKILL.md 声明权限 vs 代码实际行为不匹配 |
28
- | `supply-chain` | 🟡 警告 | npm 依赖已知 CVE 漏洞 |
29
- | `sensitive-read` | 🟡 警告 | 读取 SSH 密钥、AWS 凭证等 |
30
- | `excessive-perms` | 🟡 警告 | 权限声明过多或过于危险 |
31
- | `phone-home` | 🟡 警告 | 定时器 + HTTP 请求(心跳/信标模式) |
28
+ 无需安装,Node.js 18+ 即可运行。
29
+
30
+ ## 16 条安全规则
31
+
32
+ ### 🔴 严重(自动判定不安全)
33
+
34
+ | 规则 | 检测内容 |
35
+ |------|----------|
36
+ | `data-exfil` | 读敏感文件 + HTTP 请求(数据外泄模式) |
37
+ | `backdoor` | `eval()`、`exec()`、动态代码执行 |
38
+ | `reverse-shell` | Socket 外连 + Shell 管道 |
39
+ | `crypto-mining` | 矿池连接、xmrig、coinhive |
40
+ | `credential-hardcode` | 硬编码 AWS Key、GitHub PAT、Stripe Key |
41
+ | `env-leak` | 环境变量 + HTTP 外发 |
42
+ | `obfuscation` | base64+eval、十六进制混淆 |
43
+ | `typosquatting` | npm 包名仿冒(`1odash` `lodash`) |
44
+ | `hidden-files` | `.env` 明文密钥 |
45
+
46
+ ### 🟡 警告(建议审查)
47
+
48
+ | 规则 | 检测内容 |
49
+ |------|----------|
50
+ | `network-ssrf` | 用户可控 URL、SSRF |
51
+ | `privilege` | SKILL.md 声明 vs 代码实际行为不匹配 |
52
+ | `supply-chain` | npm 依赖已知 CVE |
53
+ | `sensitive-read` | 读取 SSH 密钥、AWS 凭证 |
54
+ | `excessive-perms` | 权限声明过多 |
55
+ | `phone-home` | 定时器 + HTTP 心跳 |
56
+ | `mcp-manifest` | MCP Server 通配权限、可疑工具描述 |
57
+
58
+ ## 真实扫描数据
59
+
60
+ 我们扫了 ClawHub **Top 9 热门 skill 仓库**(总安装量 70 万+):
61
+
62
+ | 仓库 | 安装量 | 分数 | 风险 |
63
+ |------|--------|------|------|
64
+ | vercel-labs/agent-skills | 157K | 🔴 0/100 | deploy 脚本有 `$(curl)` 命令替换 |
65
+ | obra/superpowers | 94K | 🔴 0/100 | 渲染脚本有动态代码执行 |
66
+ | coreyhaines31/marketingskills | 42K | 🔴 0/100 | 122 个 critical(CRM 凭证模式) |
67
+ | anthropics/skills | 36K | 🔴 35/100 | 模板有 exec() |
68
+ | google-labs-code/stitch-skills | 63K | ✅ 100/100 | 干净 |
69
+ | supercent-io/skills-template | 106K | ✅ 100/100 | 干净 |
70
+
71
+ **平均分:47/100** — 超半数热门 skill 有严重安全隐患。
32
72
 
33
73
  ## 使用方法
34
74
 
35
75
  ```bash
36
76
  # 扫描目录
37
- npx @elliotllliu/agentshield scan ./path/to/skill/
77
+ npx @elliotllliu/agentshield scan ./skill/
38
78
 
39
- # JSON 输出(适用于 CI/CD)
79
+ # JSON 输出
40
80
  npx @elliotllliu/agentshield scan ./skill/ --json
41
81
 
42
- # CI 门禁:分数低于阈值则失败
82
+ # CI 门禁
43
83
  npx @elliotllliu/agentshield scan ./skill/ --fail-under 70
84
+
85
+ # 禁用特定规则
86
+ npx @elliotllliu/agentshield scan ./skill/ --disable supply-chain
87
+
88
+ # 初始化配置
89
+ npx @elliotllliu/agentshield init
90
+
91
+ # 实时监控
92
+ npx @elliotllliu/agentshield watch ./skill/
93
+
94
+ # 版本对比
95
+ npx @elliotllliu/agentshield compare ./v1/ ./v2/
96
+
97
+ # 生成安全徽章
98
+ npx @elliotllliu/agentshield badge ./skill/
44
99
  ```
45
100
 
46
101
  ## GitHub Actions 集成
@@ -52,14 +107,22 @@ npx @elliotllliu/agentshield scan ./skill/ --fail-under 70
52
107
  fail-under: '70'
53
108
  ```
54
109
 
55
- ## 安全评分
110
+ ## 与其他工具对比
56
111
 
57
- | 分数 | 风险等级 |
58
- |------|----------|
59
- | 90-100 | 低风险 ✅ |
60
- | 70-89 | 中等风险 🟡 |
61
- | 40-69 | 高风险 🟠 |
62
- | 0-39 | 严重风险 🔴 |
112
+ | 功能 | AgentShield | npm audit | Snyk | ESLint |
113
+ |------|------------|-----------|------|--------|
114
+ | AI Skill/MCP 专用规则 | ✅ | ❌ | ❌ | ❌ |
115
+ | 数据外泄检测 | | | ❌ | ❌ |
116
+ | 权限不匹配检测 | | | ❌ | ❌ |
117
+ | 零配置 | | | ❌ | ❌ |
118
+ | < 50ms 扫描 | ✅ | ❌ | ❌ | ❌ |
119
+
120
+ ## 链接
121
+
122
+ - 📦 [npm](https://www.npmjs.com/package/@elliotllliu/agentshield)
123
+ - 📖 [规则文档](docs/rules.md)
124
+ - 📊 [ClawHub 安全报告](docs/clawhub-security-report.md)
125
+ - 🇬🇧 [English README](README.md)
63
126
 
64
127
  ## 许可证
65
128
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elliotllliu/agentshield",
3
- "version": "0.2.0",
3
+ "version": "0.2.1",
4
4
  "description": "Security scanner for AI agent skills, MCP servers, and plugins",
5
5
  "type": "module",
6
6
  "bin": {
@@ -12,7 +12,34 @@
12
12
  "test": "node --import tsx --test tests/**/*.test.ts",
13
13
  "prepublishOnly": "npm run build"
14
14
  },
15
- "keywords": ["security", "ai-agent", "skill", "mcp", "scanner", "audit", "openclaw"],
15
+ "keywords": [
16
+ "security",
17
+ "scanner",
18
+ "ai-agent",
19
+ "skill",
20
+ "mcp",
21
+ "plugin",
22
+ "vulnerability",
23
+ "audit",
24
+ "backdoor",
25
+ "data-exfiltration",
26
+ "credential-leak",
27
+ "static-analysis",
28
+ "codex",
29
+ "claude",
30
+ "openai",
31
+ "github-action",
32
+ "cli",
33
+ "npm",
34
+ "ai-safety",
35
+ "supply-chain",
36
+ "reverse-shell",
37
+ "typosquatting",
38
+ "ssrf",
39
+ "openclaw",
40
+ "clawhub",
41
+ "model-context-protocol"
42
+ ],
16
43
  "author": "Elliot Liu",
17
44
  "license": "MIT",
18
45
  "dependencies": {
@@ -29,5 +56,17 @@
29
56
  "engines": {
30
57
  "node": ">=18"
31
58
  },
32
- "files": ["dist", "README.md", "LICENSE"]
59
+ "files": [
60
+ "dist",
61
+ "README.md",
62
+ "LICENSE"
63
+ ],
64
+ "repository": {
65
+ "type": "git",
66
+ "url": "https://github.com/elliotllliu/agentshield.git"
67
+ },
68
+ "bugs": {
69
+ "url": "https://github.com/elliotllliu/agentshield/issues"
70
+ },
71
+ "homepage": "https://github.com/elliotllliu/agentshield#readme"
33
72
  }