agentleFS
Arcanea-LabsArcanea-Labs/Starlight-Intelligence-System/skills/safety/secret-detector/SKILL.md

safety/secret-detector

Skill10 starsChanged 2 months agoMITView on GitHub

Scan any export, file, or vault batch for credentials, API keys, tokens, and sensitive data before they leave the local machine. Fires automatically on all Claw export operations. Default skill for Starlight Sentinel and Attestation Claw.

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

7 rules. About 0 are common, 6 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈6

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Default for: Starlight Sentinel

    line 17
  2. Distinctive:

    Run pattern detection against the full content:

    line 28
  3. Very specific:

    If BLOCK patterns found: halt export, generate SECRET_SCAN_REPORT.md, present to user

    line 40
  4. Distinctive:

    If WARN patterns found: present to user with option to proceed or redact

    line 41
  5. Distinctive:

    If clean: return APPROVED for export

    line 42
  6. Distinctive:

    Add to local allowlist for this session (not persisted globally)

    line 55
  7. Distinctive:

    Vaults: No vault access needed — operates purely on content in transit

    line 60

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Secret Detector

Nothing sensitive exits the local machine without explicit human awareness.

When This Skill Activates

  • Any content is about to be written outside ~/.starlight/ to an external destination
  • Any vault export is generated for a platform adapter
  • Any content is passed to an external MCP server
  • Keywords: "export", "publish", "send", "upload", "share", "transmit"
  • Default for: Starlight Sentinel

What This Skill Does

Scans content for credential patterns, personal identifiers, and sensitive data before it leaves the local machine. Blocks export if secrets are found. Never auto-redacts — always surfaces findings to the user for an explicit decision.

Procedures

Procedure 1: Pre-Export Scan

  1. Receive content blob pending export
  2. Run pattern detection against the full content:

    PatternExampleAction on match
    API keyssk-..., pk_..., ghp_..., xoxb-...BLOCK + report
    Private keys-----BEGIN PRIVATE KEY-----BLOCK + report
    Passwords in configpassword=, passwd=, secret=BLOCK + report
    Email addressesuser@domain.com in unexpected contextWARN + report
    Phone numbers+1-555-..., formatted phone patternsWARN + report
    Credit card patterns16-digit sequences with separatorsBLOCK + report
    Government IDsSSN patterns, national ID formatsBLOCK + report
  3. If BLOCK patterns found: halt export, generate SECRET_SCAN_REPORT.md, present to user
  4. If WARN patterns found: present to user with option to proceed or redact
  5. If clean: return APPROVED for export

Procedure 2: Scan Report Generation

  1. Create /security/SECRET_SCAN_REPORT.md
  2. Include: content source, patterns detected, line references (not the secrets themselves)
  3. Present options: [redact and retry] / [cancel export] / [I confirm this is safe, proceed]
  4. Log the decision with user action

Procedure 3: False Positive Handling

  1. User declares a detected pattern is not sensitive
  2. Record the declaration with timestamp + user confirmation
  3. Add to local allowlist for this session (not persisted globally)
  4. Proceed with export

Integration Points

  • Vaults: No vault access needed — operates purely on content in transit
  • Agents: Starlight Sentinel
  • Skills: Composes with private-public-split for structural classification; permission-gate for the approval flow
  • Claws: Called by every Claw that generates exports (Memory, Creator, Attestation, Reclamation)

Quality Criteria

  • Zero false negatives on common credential patterns
  • False positives surface clearly as warnings, not blocks (where safe)
  • User is always in control — no silent redaction or silent pass
  • Scan report is human-readable, not a raw regex dump

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.