History leak scan
Claude Code skills for running models cost-effectively: security gates (secret scanner, commit-gate), model-quality tooling (eval harness, token-squeeze, compact-io, opus-workers), review/advisory (trusted-advisor, audit, skill-vet, research-brief), and a read-only reorg-proposal advisor.
npx -y skills add Evan-Daruwalla/claude-skill-suite --skill history-leak-scanAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
2 things to look at
- 28 days oldThe repository was created 28 days ago. New is not bad, but a brand new repository carrying a familiar-sounding name is the shape a typosquat arrives in, and there has been no time for anyone else to find a problem with it.
- 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
What its author says it does
Copied from the file, not written here
Deterministic secret scanner for git repositories — no dependencies, no API key. Scans full git history (every version ever committed) or the staged diff for leaked credentials: per-provider keys (AWS, GitHub incl. fine-grained PATs, Slack, Google, Stripe, Alpaca, Anthropic, OpenAI, npm, HuggingFace, SendGrid, Twilio, Resend), private-key blocks, JWTs, sensitive filenames (.env, .pem, id_rsa, *_keys.env), high-entropy assignments, and weak/short passwords. Use when the user says "scan for secrets", "leak scan", "check for leaked keys/credentials", "did I commit a secret", "history-leak-scan", or after any repo goes public / any suspected exposure. The same scanner backs commit-gate (staged mode). Reads .claude/secrets-inventory.md for what credentials exist.
SKILL.md
3.6 KB, 714 tokens by cl100k_base, as published. Nobody here has run it
history-leak-scan — deterministic secret scanner
The engine is pm-secretscan.js (portable Node, zero deps). It streams
git log -p --all (history) or git diff --cached (staged) and flags added
lines against per-provider regexes (16 rules) + a sensitive-filename rule
(.env*, .pem/.p12/.pfx, id_rsa, *_keys.env — a file of that NAME should never
be committed, whatever it contains; example/sample/template/fixture names
exempt) + a generic high-entropy-assignment detector + a weak-password rule,
with token-level placeholder suppression.
Commands
- Full-history scan (one or more repos):
node pm-secretscan.js --history <repo> [<repo>...]Exit 1 if any finding, 0 if clean. Redacts matched tokens in output. - Staged scan (what commit-gate runs):
node pm-secretscan.js --staged <repo> - Self-test (part of the definition of done):
node pm-secretscan.js --canaryPlants real-format secrets + placeholders in a throwaway repo, asserts ≥7 real caught and 0 false positives. MUST printPASSbefore you trust a scan result — an unverified gate is theater.
When invoked
- Run
--canaryfirst if the scanner was touched since last use; paste the PASS line. Never report a "clean" scan from an unverified scanner. - Enumerate the repos to scan (
find <root> -name .git -type d). Scan all with--history. - Triage every finding by READING the actual line — distinguish a live credential from a guarded dev-default or an example. Do NOT auto-rotate; report, and on a real leak point at secret-rotation + the secrets-inventory.
- Report outcome-first: repos clean vs. findings, each finding as file@commit + rule + redacted snippet, and the honest severity.
Known limits
- Catches secrets that were COMMITTED. Files that were always gitignored
(
.env, key files) are correctly out of history — verify they were never committed by a clean history scan, not by their current absence. - Entropy detection can miss bespoke low-entropy formats — that's why the
per-provider regexes exist; extend
RULESwhen a new provider appears (and add a canary fixture for every new rule — a rule without a canary is unverified). - No live credential verification (TruffleHog-style API checks) BY DESIGN: that would transmit candidate secrets to provider endpoints. Triage of live-vs-dev-default stays a human/model judgment step.
- Heuristic exemption also covers rendered-doc twins under
docs/*.html(a generated HTML render of an exempt.md); strong provider/private-key rules still apply there. Diff headers with special-char filenames (git C-quotes them, e.g. an em-dash path) are unquoted before the filename rules run — otherwise every rule keyed on the filename would silently no-op. - Redaction shows first-4 + last-2 of long tokens; still treat output as sensitive.
What ships with it: 1 file
11.4 KB alongside SKILL.md, 1 of them executable
- pm-secretscan.jsruns11.4 KB
Gives 0 of the 12 instructions most pr commit review skills give in 714 tokens
Counted across 888 of the 1,342 authors here whose files we hold, read 2026-08-07
- Use conventional commits formatin 127 of 888, across 115 files
- Keep subject line under 72 charactersin 62 of 888, across 48 files
- Delete branches after mergein 51 of 888, across 38 files
- Use imperative mood in subject linein 51 of 888, across 42 files
- Use imperative mood in commit messagesin 44 of 888
- Verify directory is ignored before creating worktreein 43 of 888, across 12 files
- Generate a conventional commit messagein 43 of 888
- Add unignored worktree directories to gitignorein 42 of 888, across 10 files
- Make atomic commitsin 39 of 888, across 27 files
- Run tests before committingin 36 of 888, across 25 files
- Verify clean test baselinein 35 of 888, across 9 files
- Split unrelated changes into separate commitsin 35 of 888, across 30 files
Said here and by no other author read
- run the canary self-test before scanning
- paste the canary PASS line
- enumerate local git repositories
- scan all repositories with the history flag
- read the actual matched line to triage findings
- distinguish live credentials from dev-defaults or examples
Grouped from the skills themselves: near-identical wordings counted once, and counted by distinct author, so one author publishing three of these counts once. Length counted with cl100k_base; the agent that loads this file may tokenize it differently.