Check for secret material¶
betterleaks¶
Configuration¶
- Docs: Configuration
betterleaks.toml- config file docs
- config file sample
pre-commit hooks¶
repos:
- repo: https://github.com/betterleaks/betterleaks
rev: v2.0.0-rc.16
hooks:
- id: betterleaks
Ignore secrets / files¶
.betterleaksignore¶
Generate SHA256 of a password:
Add the SHA to .betterleaksignore
Usage¶
Scan file system:
Trufflehog¶
- GitHub
- Docs
- Go
- Megalinter integration
- Custom Regex Detector (alpha)
- pre-commit
- pre-commit hook config
- pre-commit docs
- Source install only, Pre-commit hook is very slow to install
Install:
Scan local file:
secretlint¶
- GitHub
- Megalinter integration
- Configuration
- Not available in Arch/AUR, Mason, Mise
Install:
Run using podman:
alias secretlint="podman run -v `pwd`:`pwd` -w `pwd` --rm -it docker.io/secretlint/secretlint secretlint '**/*'"
kingfisher¶
Unmaintained¶
- gitleaks
- Superseeded by
bettersecrets
- Superseeded by
- git-secrets
- Last tag 2019
ripsecrets¶
- GitHub
- Rust, fast
- No config file
- Last release 2025-05
- Focussed on pre-commit
- AUR package ripsecrets
- Issues:
- Didn't catch all secrets detected by betterleaks
- pre-commit hook should use pre-built binaries instead of requiring cargo install
Install:
Pre-commit config:
- repo: https://github.com/sirwart/ripsecrets
rev: v0.1.11
hooks:
# Native rust-based hook not implemented yet in prek
# - id: ripsecrets
- id: ripsecrets-system
Usage:
Ignoring:
In addition to the .secretsignore file, ripsecrets is compatible with detect-secrets style allowlist comments on the same line as the detected secret:
talisman¶
- GitHub
- Last release 2025-05
- No ad-hoc cli scanning
If you are sure you want to ignore detected secret material: