skywalkskills

CatalogueSecurity & Compliance

A2Ready

Secrets & Credential Exposure Scan

Reads the repository and its full git history for keys, tokens, and passwords, including ones a later commit tried to delete.

What it examines

  • Live credentials in code, env files, config, Dockerfiles, and infrastructure templates
  • Secrets hardcoded in CI, or printed into build logs
  • Secrets that remain recoverable after the file was deleted
  • Credentials written to logs or bundled into client-side JavaScript
  • Keys with no expiry and no rotation
  • Whether a pre-commit or CI scan would have caught the next one

What you get back

A findings file. Each item has the evidence, how serious it is, and a fix.

Dependencies

  • An AI coding agent that reads SKILL.md files, such as Claude Code, Codex or Gemini CLI
  • Read access to the repository
  • The full git history. A clean working tree proves nothing, because a secret removed in a later commit is still recoverable.
  • Python 3 with the jsonschema package, to check findings.json before fixing anything
  • Optional: gitleaks or detect-secrets, if you want to add a scanner as a fix

How it works

The audit is read-only. It looks for live credentials in code, config files, Dockerfiles, infrastructure templates and CI definitions, then scans the whole git history, not just the latest commit.

It also checks for secrets written to logs or bundled into client-side code, for long-lived keys with no rotation, and for missing pre-commit and CI secret scanning.

It reports where a secret is, never the secret itself. The remediate skill reads findings.json. Rotating a leaked key is always your job, because the skill cannot do it for you.

Setup

  1. Unzip the download. Copy the audit and remediate folders into your agent's skills folder (for Claude Code, .claude/skills/) in the repository you want to check.
  2. Clone the repository in full, with history, so deleted files and old commits can be scanned.
  3. Open the repository in your agent and ask it to run the a2-secrets-credential-exposure-audit skill.
  4. Check the result with the validator: pip install jsonschema, then python3 schema/validate.py findings.json.
  5. Ask your agent to run the a2-secrets-credential-exposure-remediate skill using findings.json. Fix some findings and leave the rest open if you like.

Run it with your agent

Copy the prompt, fill in the parts in square brackets, and paste it into your agent.

Audit prompt

Run the a2-secrets-credential-exposure-audit skill on this repository. Scan the full git history, not just the working tree. Never print a secret value; report only where it is. Mode: audit only. Do not change any code. Write findings.json and findings.md in the repository root.

Fix prompt, after you have findings.json

Run the a2-secrets-credential-exposure-remediate skill using findings.json. Work through the findings I choose, and leave the rest open.

Seen on ClaimsPortalA key the working tree no longer tells the truth aboutRead the finding

What is inside

The files that make up this skill, as your agent reads them.

packages/a2-secrets-credential-exposure

audit › SKILL.md

Sign in to download

Use the email and password you signed up with.