Skill Detail

Git Secret Scanner with Gitleaks

Scans Git repositories for leaked secrets using Gitleaks, TruffleHog, and custom regex patterns. Detects API keys, AWS credentials, private keys, and database connection strings across commit history.

Security & VerificationClaude Code
Security & Verification Claude Code Security Reviewed
Tool match: stripe โญ 26.1k GitHub stars
INSTALL WITH ANY AGENT
npx skills add agentskillexchange/skills --skill git-secret-scanner-gitleaks Copy
Works best when you want a reusable capability, not another fragile one-off prompt.
At a glance
Tools required
Git
Install & setup
brew install gitleaks
Author
Gitleaks
Last updated
Mar 24, 2026
Quick brief

This skill performs thorough secret detection across Git repository history using multiple scanning engines. It runs Gitleaks with both default and custom rule configurations to scan all commits, branches, and tags for exposed credentials. TruffleHog provides entropy-based detection for high-randomness strings that may be secrets without matching known patterns. The skill scans for AWS access keys and secret keys, Google Cloud service account JSON files, GitHub personal access tokens, Stripe API keys, database connection strings with embedded passwords, and SSH private keys. It analyzes .gitignore and .gitleaksignore configurations for gaps, checks pre-commit hook configurations for secret prevention, and validates that detected secrets are actually live by testing them against their respective APIs (with read-only operations). Reports include commit SHA, author, file path, and line number for each finding, with severity classification and remediation instructions including git filter-branch or BFG Repo-Cleaner commands for history rewriting.