A TUI-first secret leak tripwire for developers. Blocks new secrets before they land in git.
- TUI-First Experience: Interactive terminal UI to review, ignore, or fix leaks.
- Git Integration: Scans
git diff --cached(staged files) for speed. - Deep Scan: Recursive directory scanning with
.gitignoresupport. - Auto-Repair: Automatically fix secrets by replacing them with placeholders.
- Heuristics: Uses entropy, keywords, and format detection to score findings.
- Baseline: Supports a
.sieve.baseline.jsonto ignore legacy secrets. - Safe: Redacts secrets in all outputs (UI and JSON).
This installs the pre-compiled binary for your OS (Windows, Linux, macOS).
npm install -g sieve-secretsNote: The npm package runs a small postinstall step that only downloads the prebuilt Rust binary from the GitHub release. If you are in a locked-down environment, set
SIEVE_SKIP_POSTINSTALL=1to skip it and build from source instead.
Run immediately without installing:
npx sieve-secrets check --fullcargo install --path .Scans only staged files (git diff --cached). Ideal for git hooks.
sieve checkRecursively scans the current directory, respecting .gitignore.
sieve check --fullAutomatically replaces all found secrets with REDACTED_SECRET.
sieve check --full --repairRunning sieve check automatically launches the interactive TUI if secrets are found. If no secrets are detected, the tool exits silently (success).
TUI Controls:
- Navigation:
Up/DownArrow keys - Actions:
r: Repair (Auto-fix the selected finding with placeholders)g: Ignore (Add to baseline/allowlist)c: Copy finding details to clipboards: Switch mode (Strict/Normal)q: Quit
For build pipelines, disable the TUI and output JSON.
sieve check --full --no-tui --format jsonAdd this to .git/hooks/pre-commit:
#!/bin/sh
# Redirect input to TTY to allow TUI interaction
exec < /dev/tty
sieve checkMake it executable:
chmod +x .git/hooks/pre-commitSieve looks for .sieve.baseline.json in the current directory.
Default ignores: node_modules, target, dist, .git, vendor.
cargo run -- check --fullThis project uses GitHub Actions for automated releases.
- Update the version in
Cargo.tomlandnpm/package.json. - Push a new tag starting with
v(e.g.,v0.1.0). - The CI workflow will:
- Build binaries for Linux, Windows, and macOS (x64 and ARM64).
- Package them into
tar.gzarchives. - Create a GitHub Release and upload the assets.
- The npm package's
install.jsscript downloads the appropriate binary from these release assets.