secret-warn

secret-warn is a skill for Claude Code from mycelium-hq/ai-brain-starter. It costs 121 tokens per session (1,954 once invoked), scanned B, original, MIT.

A security skill that checks files as a coding agent edits them for exposed secrets and potentially unsafe code or content. It covers items such as API keys, private keys, risky shell commands, dynamic code, and prompt-injection cues.

In plain words
What is it for?
Use it when adding or changing code, especially where files may contain credentials, user input, shell commands, downloaded content, or code-generation logic.
Why use it?
It can stop some dangerous edits immediately and warn about others while they are being made. This reduces the chance of committing credentials or accepting unsafe instructions from third-party content.

Skill for Claude Code

Written for Claude Code: PreToolUse hook event. Also seen: reads .claude/ paths; mentions CLAUDE.md; mentions Claude Code.

Part of the ai-brain-starter plugin — 38 skills, 17 commands, 3 agents, 1 hook shipped together

Good fit Use it when adding or changing code, especially where files may contain credentials, user input, shell commands, downloaded content, or code-generation logic.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/mycelium-hq/ai-brain-starter/secret-warn
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add mycelium-hq/ai-brain-starter --skill secret-warn
Clone the repo
git clone --depth 1 https://github.com/mycelium-hq/ai-brain-starter

Made for: Claude Code.

Or install ai-brain-starter, the plugin that ships this one along with the rest of its 38 skills, 17 commands, 3 agents, 1 hook.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for secret-warn

README.md
[![agentmods](https://agentmods.dev/badge/skills/mycelium-hq/ai-brain-starter/secret-warn/github.svg)](https://agentmods.dev/skills/mycelium-hq/ai-brain-starter/secret-warn)
Your own site
<a href="https://agentmods.dev/skills/mycelium-hq/ai-brain-starter/secret-warn"><img src="https://agentmods.dev/badge/skills/mycelium-hq/ai-brain-starter/secret-warn/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for secret-warn

Your own site · 80×15
<a href="https://agentmods.dev/skills/mycelium-hq/ai-brain-starter/secret-warn"><img src="https://agentmods.dev/badge/skills/mycelium-hq/ai-brain-starter/secret-warn.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 121 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,954 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 3 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 3 findings, up to high

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • high Agent Snooping · line 41
    Skill reads from agent configuration directories (.claude/, .codex/, .gemini/). These directories may contain API keys, personal settings, and other credentials that the skill has no legitimate need to access.
    Fix: Remove all code or instructions that access agent configuration directories (.claude/, .codex/, .gemini/). If configuration values are needed, pass them explicitly as parameters or environment variabl
  • high Agent Snooping · line 48
    Skill reads from agent configuration directories (.claude/, .codex/, .gemini/). These directories may contain API keys, personal settings, and other credentials that the skill has no legitimate need to access.
    Fix: Remove all code or instructions that access agent configuration directories (.claude/, .codex/, .gemini/). If configuration values are needed, pass them explicitly as parameters or environment variabl
  • high Prompt Injection · line 93
    This pattern attempts to override system instructions or ignore safety constraints. Without LLM analysis, manual review is recommended.
    Fix: Remove or rewrite any text that instructs the agent to ignore prompts, override safety rules, or trust unverified content. Ensure skill content cannot be injected to alter agent behavior.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00121 $0.01954
Opus 5 $0.00060 $0.00977
Sonnet 5 $0.00024 $0.00391
Haiku 4.5 $0.00012 $0.00195

Measured 10d ago against content hash ba650fd26a0c, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade B, and why

secret-warn scanned grade B with 3 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.

The scan reads SKILL.md. This mod also ships 4 executable files (hooks/audited_content_scan.py, hooks/secret_warn.py, install.sh, …), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Instruction-override phrasingmediumPrompt injection

Text telling the model to disregard its earlier instructions or safety rules is the shape of a prompt injection, whoever wrote it.

**Why it never fires on your own writing.** The `prompt-injection` rules carry `applies_to: ["audited-content"]`, and the edit-time hook only handles `edit` / `commit` / `bash` tools. So a vault note that merely discusse

Downgraded: this mod is about security review, or the phrase is quoted, so it is likely naming the pattern rather than instructing it.

Reads agent configuration directorieslowAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

- Merges PreToolUse + PostToolUse + Bash hook entries into `~/.claude/settings.json` (non-destructive, additive)

Downgraded: this mod is about security review, or the phrase is quoted, so it is likely naming the pattern rather than instructing it.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

| Curl/wget pipe-to-shell from a non-allowlisted host | block | Edit rejected |
skills/secret-warn/SKILL.md · 133 lines

How it starts

The opening of the file, as written. The whole thing — 133 lines — stays where its author put it; the contents beside it link to each section on GitHub.

secret-warn — real-time edit-time security guardrails

Catches secrets and unsafe patterns the moment a Claude Code agent writes them, not after the fact. Public substrate version (MIT). Free to install, free to extend.

What it does

Trigger Severity Action
API key in file (Stripe, AWS, GCP, OpenAI, Anthropic, GitHub, Slack) block (exit 2) Edit rejected
PEM-encoded private key block block Edit rejected
High-entropy assignment to a key-named variable warn (exit 1) Advisory, edit proceeds
Python dynamic-codegen on a user-input-suggesting name warn Advisory
Subprocess with shell-mode + variable expansion warn Advisory
Curl/wget pipe-to-shell from a non-allowlisted host block Edit rejected
Prompt-injection cue in audited third-party content (ignore-previous, role-override, exfil, system-impersonation, paste-and-run) warn (flag-before-read) Specimen flag via audited_content_scan.py — never an edit-time block

All patterns are stored base64-encoded in hooks/pattern_registry.json so the registry file itself doesn't trip pattern-matching tools that scan the repo. This is intentional — see Design note: self-trigger safety below.

Install

bash skills/secret-warn/install.sh

The installer:

  • Copies hooks/secret_warn.py + hooks/audited_content_scan.py to ~/.claude/secret-warn/
  • Copies hooks/pattern_registry.json to the same location
  • Merges PreToolUse + PostToolUse + Bash hook entries into ~/.claude/settings.json (non-destructive, additive)
  • Logs every catch to ~/.claude/secret-warn/audit.log

Idempotent. Safe to re-run.

Uninstall

Edit ~/.claude/settings.json and remove any hook entry whose description starts with secret-warn:. Delete ~/.claude/secret-warn/ if you want the audit log gone too.

Bypass

For an emergency one-off where you genuinely need to bypass a catch (test fixture in a controlled environment, allowlisted-but-not-yet-configured host):

Read the full file on GitHub · 133 lines

Files

What ships with it

9 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 10d ago First seen · 133 lines · 121 tokens per session scan B ba650fd26a0c

Subscribe to this mod's changes

secret-warn is a skill published in the GitHub repository mycelium-hq/ai-brain-starter (36 stars, last pushed yesterday), licensed MIT. It adds 121 tokens to every session and 1,954 once invoked, about $0.0006 per session on Opus 5. A static security scan graded it B with 3 findings (instruction-override phrasing, reads agent configuration directories, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

Hooks Automation

Automated coordination, formatting, and learning from Claude Code operations using intelligent hooks with MCP integration. Includes pre/post task hooks, session management, Git integration, memory coordination, and neural pattern training for enhanced development workflows.

jazz-max/ruflo-hub · 46 tokens

contribute-spec-fix

Fix a broken OpenAPI spec in jentic-public-apis with an OpenAPI Overlay, validate it (spectral lint + idempotency check), and contribute it back via a PR to the community catalog. Falls back to applying the same overlay to the local Jentic registry if the user can't wait for maintainer approval, and closes the loop by…

jentic/jentic-one · 138 tokens

night-watch

Autonomous maintenance (dep updates, dead code, small refactors) in isolated branch, off-hours. Triggers: night watch, autonomous maintenance, dep updates.

softspark/ai-toolkit · 36 tokens

calcom-access

Access Cal.com API via CLI with 1Password API key. Use when user wants to list bookings, create event types, manage schedules, or.

terrylica/cc-skills · 34 tokens

iterm2-layout

Configure iTerm2 workspace layouts with TOML. TRIGGERS - iTerm2 layout, workspace tabs, layout.toml, AutoLaunch.

terrylica/cc-skills · 35 tokens

spring-shell

Spring Shell for building interactive CLI applications. Covers @ShellComponent, @ShellMethod, input validation, tables, and command groups. USE WHEN: user mentions "spring shell", "@ShellComponent", "@ShellMethod", "CLI application Spring", "interactive shell", "command line tool Spring" DO NOT USE FOR: simple scripts…

claude-dev-suite/claude-dev-suite · 96 tokens