当前位置: 首页 > Skill >

skill-auditor-plus

skill-auditor-plus

skill-auditor-plus

Security, performance, and quality auditing for AgentSkills. Use when reviewing skills before installation, auditing during development, checking installed skills for risks, optimizing performance, or ensuring best practices compliance. Automated scanning for dangerous operations, credential leaks, token bloat, and quality issues.

1.0.0 2026.11.18 205
获取Skill文件查看使用说明
作 者:陆舟 许可证: 更新时间:2026.11.18
本文目录展开

Skill Auditor Plus

Transform skill development from "hope it works" to "confidently secure and optimized". This skill provides automated auditing for AgentSkills across three dimensions: security, performance, and quality.

Why Skill Auditing Matters

  • Security: Skills run with Codex's permissions - a vulnerable skill can delete files, leak credentials, or execute arbitrary commands
  • Performance: Large skills consume context window, reducing Codex's effectiveness for the actual task
  • Quality: Well-structured skills are easier to maintain, more reliable, and provide better user experience

Core Capabilities

1. Security Audit

Automatically scans for:

  • Dangerous operations: File deletion (rm -rf), system commands (eval, exec), code execution
  • Credential leaks: Hardcoded API keys, secrets, tokens, passwords
  • Network requests: External API calls that may be unsafe
  • Suspicious patterns: Pastebin links, URL shorteners, risky file paths
  • Injection vulnerabilities: Unsafe user input handling

Severity levels:

  • 🔴 High: File deletion, credential leaks, system command execution
  • 🟡 Medium: Network requests, code execution, risky file paths
  • 🟢 Low: Suspicious URLs, file writes

2. Performance Audit

Analyzes skill efficiency:

  • Token usage: Frontmatter (<100 tokens), body (<5000 tokens), line count (<500 lines)
  • Context optimization: Duplicate content, unreferenced files, large reference files
  • Script efficiency: Execute permissions, code duplication
  • Recommendations: Split into references/, use scripts for repeated code

Key metrics:

  • Frontmatter token count (target: <100)
  • Body token count (target: <5000)
  • Line count (target: <500)
  • Reference file sizes (target: <10k tokens each)

3. Quality Audit

Checks best practices compliance:

  • SKILL.md structure: Proper frontmatter, complete description
  • File organization: No unnecessary files (README.md, INSTALLATION_GUIDE.md, etc.)
  • Documentation: Clear usage instructions, examples, error handling
  • Progressive disclosure: Efficient context loading with references/

Quick Start

Audit a skill before installation

# Clone or download the skill
cd skill-auditor-plus

# Run security audit
python3 scripts/security_audit.py /path/to/skill-to-audit

# Run performance audit
python3 scripts/performance_audit.py /path/to/skill-to-audit

During skill development

# After making changes, audit your skill
python3 scripts/security_audit.py /path/to/your-skill
python3 scripts/performance_audit.py /path/to/your-skill

# Fix issues, then re-audit
# Iterate until no high/medium severity issues remain

Batch audit installed skills

# Audit all skills in a directory
for skill in /path/to/skills/*; do
    echo "Auditing $skill"
    python3 scripts/security_audit.py "$skill"
    python3 scripts/performance_audit.py "$skill"
done

Understanding Audit Reports

Security Audit Report

{
  "total_issues": 5,
  "high_severity": 1,
  "medium_severity": 2,
  "low_severity": 2,
  "issues": [
    {
      "category": "credential_leaks",
      "severity": "high",
      "file": "scripts/api_client.py",
      "line": 15,
      "pattern": "api_key\s*=\s*["'][\w-]+["']",
      "matched_text": "api_key = "sk-1234567890"",
      "context": "api_key = "sk-1234567890""
    }
  ]
}

What to do:

  1. Review each issue by severity (high → medium → low)
  2. For credential leaks: Use environment variables
  3. For dangerous operations: Add warnings or safety checks
  4. For network requests: Document purpose and add error handling

Performance Audit Report

{
  "skill_md_stats": {
    "frontmatter_tokens": 85,
    "body_tokens": 7500,
    "total_tokens": 7585,
    "line_count": 520
  },
  "issues": [
    {
      "severity": "high",
      "category": "body_too_long",
      "message": "Body is too long (7500 tokens, should be < 5000)",
      "suggestion": "Split content into references/ files and link from SKILL.md"
    }
  ]
}

What to do:

  1. Frontmatter too long: Move detailed descriptions to body
  2. Body too long: Split into references/ files, link from SKILL.md
  3. Too many lines: Break into smaller sections, use references/
  4. Large reference files: Split further or add grep patterns for searching

Best Practices

See best-practices.md for comprehensive guidelines on:

  • Security best practices (credential management, input validation, safe operations)
  • Performance optimization (token efficiency, progressive disclosure, script usage)
  • Quality standards (documentation, file organization, structure)

Advanced Usage

Custom Security Patterns

Edit scripts/security_audit.py to add custom patterns:

DANGEROUS_PATTERNS = {
    'custom_risk': [
        r'your_custom_regex_pattern',
    ],
}

Performance Thresholds

Edit scripts/performance_audit.py to adjust thresholds:

if stats['body_tokens'] > 5000:  # Change this value
    issues.append({...})

Integration with CI/CD

Add to your CI pipeline:

# .github/workflows/skill-audit.yml
name: Skill Audit
on: [push, pull_request]
jobs:
  audit:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - name: Security Audit
        run: |
          python3 skill-auditor-plus/scripts/security_audit.py .
      - name: Performance Audit
        run: |
          python3 skill-auditor-plus/scripts/performance_audit.py .

Resources

scripts/

  • security_audit.py: Automated security scanning for dangerous operations, credential leaks, and suspicious patterns
  • performance_audit.py: Performance analysis for token usage, context optimization, and best practices compliance

references/

  • best-practices.md: Comprehensive guide to AgentSkill development best practices, including security, performance, and quality standards

Troubleshooting

"Module not found" errors

Install required dependencies:

pip install pyyaml  # if needed

False positives in security audit

If the scanner flags safe code:

  1. Review the pattern match
  2. Add comments explaining why it's safe
  3. Consider refactoring to avoid the pattern

Performance audit shows large body

This is normal for complex skills. Split content into references/:

  1. Move detailed sections to references/feature-name.md
  2. In SKILL.md, add: "See FEATURE for details"
  3. Keep only overview and navigation in SKILL.md

Contributing

Found a bug or want to add features? This skill is open source. Contributions welcome!

License

MIT License - See LICENSE file for details

推荐文章

更多
PHP时间戳与日期字符串相互转换方法详解

本文介绍PHP中时间数值(Unix时间戳)与日期字符串之间的相互转换方法。通过strtotime和date函数,实现将当前时间、指定日期转换为时间戳,以及将时间戳格式化为可读的日期时间字符串,并提供相关在线计算工具推荐。

2025.11.30 1,034
PHP日期转时间戳时区偏差怎么解决

在 PHP 中将日期字符串转换为时间戳时,若未显式指定时区,默认使用脚本配置的 date.timezone 或系统时区。当服务器时区与业务逻辑预期(如 UTC )不一致时,会产生偏差。解决核心是确保输入字符串携带明确时区信息,或在转换前统一设置时区上下文。

2026.10.24 1,031
PHP跨域配置:怎么安全地允许指定域名而非使用通配符

在 PHP 中安全地允许指定域名跨域,核心是解析请求头中的 Origin ,验证其是否在白名单内,然后动态设置 Access-Control-Allow-Origin 响应头。不要使用通配符 * ,也不要硬编码单一域名。

2025.03.29 1,018
JavaScript中利用replace结合正则实现replaceAll效果

JavaScript原生仅支持replace()进行单次或全局替换,缺乏类似Java的replaceAll()便捷方法。本文总结四种在JS中实现全量替换的方案:使用带g标志的正则、带gm标志的正则、扩展String原型以及split后join。通过对比代码示例,展示各方法的实现细节与适用场景,帮助开发者根据需求选择最优解。

2025.04.29 1,017
OpenAI的Jalapeno芯片未落地,教你分辨300兆瓦算力消息

OpenAI计划在SB Energy租赁的数据中心部署约300兆瓦自研Jalapeno推理芯片,但目前双方仍处于洽谈阶段,交易细节与上线时间表均未公布。本文带你按报道原文核实项目所处阶段,厘清芯片发布、电力功率与实际推理算力的边界,并将融资意向与签约、开工、投运节点分开追踪,避免误将规划容量计入现有算力。

2026.12.02 1,013
PHP实现基础文件上传:HTML表单与$_FILES处理流程

在 HTML 表单中设置 enctype="multipart/form-data" ,并在 PHP 后端通过 $_FILES 数组接收文件,调用 move_uploaded_file() 将临时文件移动到目标目录即可完成上传。

2026.09.07 1,013
Skill 文件
  • SKILL.md
    • Skill Auditor Plus
    • Why Skill Auditing Matters
    • Core Capabilities
      • 1. Security Audit
      • 2. Performance Audit
      • 3. Quality Audit
    • Quick Start
      • Audit a skill before installation
      • During skill development
      • Batch audit installed skills
    • Understanding Audit Reports
      • Security Audit Report
      • Performance Audit Report
    • Best Practices
    • Advanced Usage
      • Custom Security Patterns
      • Performance Thresholds
      • Integration with CI/CD
    • Resources
      • scripts/
      • references/
    • Troubleshooting
      • "Module not found" errors
      • False positives in security audit
      • Performance audit shows large body
    • Contributing
    • License
  • 项目或源文件

相关 Skill

更多
skill-creator-enhanced skill-creator-enhanced Enhanced skill creator with templates, validation, publishing workflow, and quality gates. Guides through skill creation process with best practices, common patterns, and ClawHub integration.
NextJS Frontend Development + Integration NextJS Frontend Development + Integration Generate production-ready Next.js projects with TypeScript, Tailwind CSS, shadcn/ui, and API integration. Use when the user asks to build, create, develop, or scaffold a Next.js application, web app, full-stack project, or frontend with backend integration. Prioritizes modern stack (Next.js 14+, TypeScript, shadcn/ui, axios, react-query) and best practices. Also triggers on requests to add features, integrate APIs, or extend existing Next.js projects.
Two Factor Authentication Best Practices Two Factor Authentication Best Practices 该技能为使用 Better Auth 的 twoFactor 插件实施安全的双因素认证(2FA)提供指导和强制规则。
docker-plus docker-plus Enhanced Docker with Dockerfile templates, multi-stage builds, security hardening, production best practices, Docker Compose patterns, and troubleshooting guides.
HR每日精选日报 HR每日精选日报 Generate a professional HR daily briefing report as a beautifully designed HTML page. Use when the user requests an HR daily report, HR industry news digest, human resources trend analysis, HR best practices compilation, or HR case study review. Covers insights from top consulting firms (McKinsey, Deloitte, BCG, Mercer, WTW), deep dives into HR functional modules (recruitment, performance, compensation, talent development, employee relations, HR planning) and the three-pillar model (HRBP, COE, S