Token导航 LogoToken导航TokenDH.com
研究检索执行命令github未标认证来源可访问许可证需确认审计通过

deep-audit深度审计

Agent Skill

用于辅助安全审计、权限检查、凭据风险、认证流程和常见漏洞排查。它适合让 Agent 梳理敏感配置、检查依赖风险、分析鉴权逻辑或生成安全复核清单。使用时不能把工具输出直接当最终结论,涉及密钥、令牌、用户数据或生产系统时,应先确认最小权限、脱敏方式和操作边界。

总安装

353

周安装

15

GitHub Stars

1,012

下载量

124
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:deep-audit(深度审计)
来源仓库:https://github.com/pedrohcgs/claude-code-my-workflow
仓库路径:skills/deep-audit
安装命令:
npx skills add https://github.com/pedrohcgs/claude-code-my-workflow --skill deep-audit
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/pedrohcgs/claude-code-my-workflow --skill deep-audit

简介

用于辅助安全审计、权限检查、凭据风险、认证流程和常见漏洞排查, 适合梳理敏感配置或生成安全复核清单。deep-audit 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

  • 使用时不能把工具输出直接当最终结论, 涉及密钥、令牌、用户数据或生产系统时, 应先确认最小权限。安装方式:通过 npx skills add 命令从指定 GitHub 仓库添加。

SKILL.md

/deep-audit — Repository Infrastructure Audit

Run a comprehensive consistency audit across the entire repository, fix all issues found, and loop until clean.

When to Use

  • After broad changes (new skills, rules, hooks, guide edits)
  • Before releases or major commits
  • When the user asks to "find inconsistencies", "audit", or "check everything"

Workflow

PHASE 0: Mechanical checks (run FIRST, cheap, deterministic)

Before spawning agents, run the mechanical parity checks:

python3 scripts/check-skill-integrity.py --verbose

This catches four classes of bug that agent-based audits have historically missed:

  1. Frontmatter allowed-tools ↔ body tool-invocation parity (e.g. body spawns Task but Task not in allowed-tools — the v1.7.0 PR #92 miss).
  2. argument-hint ↔ body flag parity (flags documented but not advertised, or vice versa).
  3. Internal markdown anchors resolve (no broken [text](path#anchor) links — the #category-11-numerical-discipline miss on PR #87).
  4. Rule paths: ↔ skill implementation parity (rule claims skill follows protocol but skill body has none of the protocol keywords — the /interview-me miss on PR #92).

If Phase 0 reports P0 or P1 findings, fix them (or tune the regex if they are false positives) before launching the 4 agents. The mechanical layer is cheaper and more precise than agent prompts for these classes.

PHASE 1: Launch 4 Parallel Audit Agents

Launch these 4 agents simultaneously using Task with subagent_type=general-purpose. Each agent's prompt must tell it to read .claude/references/audit-pet-peeves.md and explicitly check for each class of bug before reporting clean. The pet-peeves file is a living catalogue of drift patterns review bots have caught; it grows with each PR.

Agent 1: Guide Content Accuracy

Focus: guide/workflow-guide.qmd

  • All numeric claims match reality (skill count, agent count, rule count, hook count)
  • All file paths mentioned actually exist on disk
  • All skill/agent/rule names match actual directory names
  • Code examples are syntactically correct
  • Cross-references and anchors resolve
  • No stale counts from previous versions

Agent 2: Executable Code Quality

Focus: all executable code in the repo — .claude/hooks/*.py, .claude/hooks/*.sh, scripts/*.py, scripts/*.sh, .claude/scripts/*.sh. Not just .claude/hooks/ — when PR #93 added new code under scripts/, the original narrow scope meant Copilot + Codex caught 5 bugs the audit missed.

Hook-specific checks (Stop/PreToolUse/SessionStart protocols, CLAUDE_PROJECT_DIR usage, hash-length consistency) apply only to .claude/hooks/. Everything below applies to ALL executable code:

  • No remaining /tmp/ usage in anything that manages state (should use ~/.claude/sessions/)
  • Hash length consistency ([:8] across all hooks) [hooks only]
  • Proper error handling — fail-open pattern where the docstring promises it (top-level try/except with sys.exit(0)). Python read_text() must catch UnicodeError (not just OSError) if the script is promised fail-open for corrupt files. Bash set -u without set -e or explicit post-command checks does NOT catch command failures — verify.
  • Docstring-claim ↔ implementation parity. If a function's docstring describes "bidirectional parity" / "fail-open" / "exits 1 on X", the implementation must match. Common drift: one-directional implementation of a claimed-bidirectional contract; exit codes documented as one thing but returning another.
  • Config-map entries point at live targets. Keyword dicts, path maps, and rule registries should not contain dead entries (e.g. rule files that don't exist, fields the script doesn't actually read). Dead entries mislead maintainers.
  • JSON input/output correctness (stdin for input, stdout/stderr for output) [hooks only]
  • Exit code correctness. Two valid blocking protocols for Stop/PreToolUse hooks: (a) exit 2 + reason on stderr — legacy, still supported (b) exit 0 + JSON {"decision": "block", "reason": "..."} on stdout — modern; this is what log-reminder.py uses and it works correctly Non-blocking hooks always exit 0. PreCompact hooks MUST exit 0 (stdout is discarded by the harness — use stderr for diagnostics)
  • from __future__ import annotations for Python 3.8+ compatibility
  • Correct field names from hook input schema (source not type for SessionStart)
  • PreCompact hooks print to stderr (stdout is ignored)

Agent 3: Skills and Rules Consistency

Focus: .claude/skills/*/SKILL.md and .claude/rules/*.md

  • Valid YAML frontmatter in all files
  • No stale disable-model-invocation: true
  • allowed-tools values are sensible
  • allowed-tools actually covers every tool the skill body invokes. For every Task spawn, Bash command, Write/Edit call mentioned in the skill's Steps / Phases / Workflow body, verify the tool appears in the allowed-tools array. Common miss: skill body says "spawn agent-X via Task with context=fork" but Task is absent from allowed-tools — runtime permission error or silent bypass. Caught this class of bug after Codex/Copilot flagged it on PR #92 (4 skills promised Task in their Post-Flight sections but 3 of 4 had no Task permission).
  • Rule paths: scope matches skill implementation. If rule X lists skill Y in paths:, verify skill Y actually implements the protocol rule X mandates. A rule claiming a skill follows a protocol is meaningless if the skill doesn't.
  • Rule paths: reference existing directories
  • No contradictions between rules
  • CLAUDE.md skills table matches actual skill directories 1:1
  • All templates referenced in rules/guide exist in templates/

Agent 4: Cross-Document Consistency

Focus: README.md, docs/index.html, docs/workflow-guide.html

  • All feature counts agree across all 3 documents
  • All links point to valid targets
  • License section matches LICENSE file
  • Directory tree matches actual structure
  • No stale counts from previous versions

PHASE 2: Triage Findings

Categorize each finding:

  • Genuine bug: Fix immediately
  • False alarm: Discard (document WHY it's false for future rounds)

Common false alarms to watch for:

  • Quarto callout ## Title inside ::: divs — this is standard syntax, NOT a heading bug
  • allowed-tools linter warning — known linter bug (Claude Code issue #25380), field IS valid
  • Counts in old session logs — these are historical records, not user-facing docs
  • Counts in CHANGELOG.md under past version headings — those are snapshots; do NOT update
  • log-reminder.py outputting {"decision": "block"} with sys.exit(0) — this IS the modern Claude Code Stop-hook block protocol, NOT a bug

Count drift specifically: search for every phrasing variant. A common failure mode is that replace_all on one phrasing (e.g., "26 skills") misses sibling phrasings in the same repo. When checking counts, grep for ALL of:

  • "N skills", "N skill " (with space)
  • "N slash commands"
  • "N specialized" (as in "N specialized agents")
  • "template's N" (informal count in prose)
  • Commas/conjunctions: "skills," vs "skills, and" are treated as different strings by replace_all Verify zero matches for the OLD number across the whole tree before declaring clean.

PHASE 3: Fix All Issues

Apply fixes in parallel where possible. For each fix:

  1. Read the file first (required by Edit tool)
  2. Apply the fix
  3. Verify the fix (grep for stale values, check syntax)

PHASE 4: Re-render if Guide Changed

If guide/workflow-guide.qmd was modified:

quarto render guide/workflow-guide.qmd
cp guide/workflow-guide.html docs/workflow-guide.html

PHASE 5: Loop or Declare Clean

After fixing, launch a fresh set of 4 agents to verify.

  • If new issues found → fix and loop again
  • If zero genuine issues → declare clean and report summary

Max loops: 5 (to prevent infinite cycling)

Key Lessons from Past Audits

These are real bugs found across 7 rounds — check for these specifically:

Bug PatternWhere to CheckWhat Went Wrong
Stale counts ("19 skills" → "21")Guide, README, landing pageAdded skills but didn't update all mentions
Hook exit codesAll Python hooksExit 2 in PreCompact silently discards stdout
Hook field namespost-compact-restore.pySessionStart uses source, not type
State in /tmp/All Python hooksShould use ~/.claude/sessions/<hash>/
Hash length mismatchAll Python hooksSome used [:12], others [:8]
Missing fail-openPython hooks __main__Unhandled exception → exit 1 → confusing behavior
Python 3.10+ syntaxType hints like `dictNone`
Missing directoriesquality_reports/specs/Referenced in rules but never created
Always-on rule listingGuide + READMEmeta-governance omitted from listings
macOS-only commandsSkills, rulesopen without xdg-open fallback
Stale hook referencesRules, guide, CHANGELOG, settings.jsonRemoved hooks still mentioned somewhere

Output Format

After each round, report:

## Round N Audit Results

### Issues Found: X genuine, Y false alarms

| # | Severity | File | Issue | Status |
|---|----------|------|-------|--------|
| 1 | Critical | file.py:42 | Description | Fixed |
| 2 | Medium | file.qmd:100 | Description | Fixed |

### Verification
- [ ] No stale counts (grep confirms)
- [ ] All hooks have fail-open + future annotations
- [ ] Guide renders successfully
- [ ] docs/ updated

### Result: [CLEAN | N issues remaining]

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

34.01%
按下载量换算42

Claude

32.95%
按下载量换算41

Cursor

20.98%
按下载量换算26

Gemini CLI

9.35%
按下载量换算12

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

执行命令

安装流程涉及命令执行,可能通过 npx skills add https://github.com/pedrohcgs/claude-code-my-workflow --skill deep-audit 联网下载 Skill 或依赖。用户安装前应确认命令来源、仓库内容和执行环境。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills