secret-warn

Detect and block secrets and unsafe commands in Claude Code tool-calls.

31|20|Updated Apr 9, 2026
One-click install
npx skills add https://github.com/mycelium-hq/ai-brain-starter --skill secret-warn
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: secret-warn
Source: https://github.com/mycelium-hq/ai-brain-starter/tree/main/skills/secret-warn
Command: npx skills add https://github.com/mycelium-hq/ai-brain-starter --skill secret-warn

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

secret-warn provides real-time guardrails that detect secrets, sensitive patterns, and unsafe shell constructs the moment they appear in Claude Code tool-calls, preventing leaks before they land in drafts or CI.

Core Features & Use Cases

  • Real-time detection of API keys, private keys, and high-entropy strings in edit-time and shell commands.
  • PreToolUse and PostToolUse hooks plus a Bash guard to enforce safety across Claude Code workflows.
  • Maintains a base64-encoded registry of 11+ rules with allowlist and bypass options for controlled environments, plus an audit log for traceability.
  • Use case: during code review or drafting, it blocks or warns on secret exposures and unsafe commands, ensuring secure development sessions.

Quick Start

Run the installer to activate secret-warn in Claude Code and then run the quick_test.sh script to verify installation.

Frequently Asked Questions about secret-warn

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I detect and block secrets in real time during Claude Code tool calls?

Real-time secret detection in Claude Code tool calls is handled by PreToolUse and PostToolUse hooks that scan edit-time workflows and Bash command streams, blocking sensitive patterns before exposure.

What types of sensitive patterns can real-time secret detection catch in shell commands?

Real-time secret detection catches API keys, private keys, high-entropy strings, and unsafe shell constructs using a base64-encoded registry of 11+ regex rules applied to Bash command streams.

Can I configure allowlists or bypass options for secret detection rules in specific environments?

Allowlists and bypass options for secret detection rules are supported, allowing controlled overrides for specific environments while maintaining an audit log for traceability and compliance.

Does secret detection work with PreToolUse and PostToolUse hooks in Claude Code development sessions?

Secret detection works directly with PreToolUse and PostToolUse hooks plus a Bash guard, enforcing safety across Claude Code workflows and preventing leaks before they reach drafts or CI.

How do I verify that real-time guardrails are installed correctly in my engineering pipeline?

Verify real-time guardrail installation by running the provided portable install script to activate the hooks, then execute the quick_test.sh script to confirm detection rules are enforced.

What is the best way to prevent API keys and high-entropy strings from leaking into code drafts?

Preventing API keys and high-entropy strings from leaking into drafts requires modular hook architecture that intercepts edit-time workflows, scanning content against regex rules before exposure occurs.