Agentguard
No description available
Install / Use
/learn @Metatransformer/AgentguardREADME
🛡️ AgentGuard
Security scanner and trust layer for AI agent skills and plugins.
Think npm audit for the agent ecosystem. AgentGuard scans agent skills, plugins, and tools for malicious patterns before they can access your system.
Why AgentGuard?
The AI agent ecosystem is exploding — but there's no security layer. Skills and plugins are essentially unsigned binaries running with access to your filesystem, credentials, and network. One malicious skill can:
- 🔑 Steal your SSH keys, AWS credentials, API tokens
- 💉 Inject shell commands via eval/exec
- 📡 Exfiltrate data to external servers
- 🎭 Hide payloads behind base64/hex obfuscation
AgentGuard catches these patterns before they run.
Works with any agent platform — ClawdHub, Moltbook, LangChain, CrewAI, or your own skill registry.
Install
npm install -g agentguard
Usage
Scan a skill for security issues
agentguard scan ./my-skill/
Example output:
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🛡️ AgentGuard Security Report
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Path: /path/to/skill
Files: 3 scanned
Time: 12ms
🚨 CRITICAL (3)
CRED-002 SSH key path access
└ index.ts:8
const sshDir = `${home}/.ssh`;
CRED-003 AWS credentials access
└ index.ts:14
const awsCreds = fs.readFileSync(`${home}/.aws/credentials`, 'utf-8');
INJ-001 eval() usage
└ index.ts:35
eval(String.fromCharCode(99, 111, 110, 115, 111, 108, 101));
🔴 HIGH (2)
CRED-006 Outbound HTTP with sensitive data
└ index.ts:22
const req = https.request({
INJ-002 exec/spawn with dynamic input
└ index.ts:30
exec('crontab -l | { cat; echo "*/5 * * * * curl ...
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🚫 Trust Score: 0/100
3 critical · 2 high · 2 medium · 0 low
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
JSON output for CI/CD
agentguard scan ./my-skill/ --json
Fail on specific severity
agentguard scan ./my-skill/ --fail-on HIGH
Verify skill integrity
# Generate hash
agentguard verify ./my-skill/
# Compare against known hash
agentguard verify ./my-skill/ --hash abc123def456...
What It Detects
| Category | Examples | Severity | |----------|----------|----------| | Credential Exfiltration | Reading ~/.ssh, ~/.aws, process.env, cookie files | CRITICAL-HIGH | | Code Injection | eval(), exec(), spawn(), new Function() | CRITICAL-HIGH | | Permission Escalation | sudo, filesystem writes outside workspace, network listeners | CRITICAL-MEDIUM | | Obfuscation | Base64 payloads, hex-encoded strings, dynamic require/import | HIGH-MEDIUM | | Known Bad Patterns | Reverse shells, crypto miners, DNS exfiltration, credential harvesters | CRITICAL |
Roadmap
- Phase 1 ✅ — CLI scanner with pattern detection and hash verification
- Phase 2 — Community trust scores, skill reputation registry, signed skills
- Phase 3 — Agent review swarm — AI agents that audit other agents' skills
Contributing
PRs welcome! To add detection patterns, edit src/scanner/patterns.ts.
git clone https://github.com/rondorkerin/agentguard
cd agentguard
npm install
npm test
npm run build
License
MIT
Built by metatransformer — a human-AI synthesis accelerating the agent ecosystem.
Related Skills
node-connect
353.3kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
111.7kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
353.3kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
353.3kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
