Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
31a2b1f
chore: add self-scan config excluding test fixtures
pixincreate Aug 25, 2026
60de57a
fix(detectors): raise Base64Detector entropy threshold to 4.2
pixincreate Aug 25, 2026
ad8aca0
feat(scan): add --staged mode scanning only added lines of the staged…
pixincreate Aug 25, 2026
4284ef2
perf(scan): single-pass Aho-Corasick keyword prefilter
pixincreate Aug 25, 2026
4a47aa1
fix(scan): never scan the --baseline file itself
pixincreate Aug 25, 2026
57c6fff
feat(config): walk up ancestors for config discovery, bounded by trust
pixincreate Aug 25, 2026
5b42995
feat(hooks): pre-commit hook delegates to scan --staged
pixincreate Aug 25, 2026
0d78694
refactor: prefer match over if/else chains in report output
pixincreate Aug 25, 2026
9f01a70
fix(detectors): allowlist $PWD working-directory references in Passwo…
pixincreate Aug 25, 2026
c1163fa
docs: document staged scanning, config discovery, and hook behavior
pixincreate Aug 25, 2026
7692e0c
style: apply cargo fmt and allow 'caf' in typos config
pixincreate Aug 25, 2026
326c433
feat(baseline): auto-discover .keywatch-baseline.json and add update …
pixincreate Aug 25, 2026
3549d48
fix(baseline): exclude the baseline file by canonical path
pixincreate Aug 25, 2026
7f4326e
chore: dogfood a committed baseline instead of inline ignore comments
pixincreate Aug 25, 2026
76b1bc7
refactor: address review feedback in scanner and hooks
pixincreate Aug 25, 2026
e57d649
fix: do not panic when stdout is closed
pixincreate Aug 25, 2026
5cb7ccb
docs: condense the unreleased changelog to one line per change
pixincreate Aug 25, 2026
66f745c
fix: match baseline and exclude paths regardless of separator
pixincreate Aug 25, 2026
c391a60
fix: close two detection bypasses found in review
pixincreate Aug 25, 2026
6508181
fix(detectors): stop flagging code identifiers as credentials
pixincreate Aug 26, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: CI-push
on:
push:
branches:
- main
- master
merge_group:
types:
- checks_requested
Expand Down
51 changes: 51 additions & 0 deletions .github/workflows/update-baseline.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: Update baseline

# Manually triggered on purpose: automatically re-baselining on every push
# would silently accept newly introduced secrets. This regenerates
# .keywatch-baseline.json and opens a pull request so each newly baselined
# finding gets human review. (Neither gitleaks nor ggshield auto-update
# their baselines for the same reason.)
on:
workflow_dispatch:

permissions:
contents: write
pull-requests: write

jobs:
update-baseline:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v7

- name: Install Rust
uses: dtolnay/rust-toolchain@master
with:
toolchain: stable

- name: Build key-watch
run: cargo build --release --locked

- name: Regenerate baseline
run: ./target/release/key-watch scan . --update-baseline

- name: Open pull request if the baseline changed
env:
GH_TOKEN: ${{ github.token }}
run: |
if [ -z "$(git status --porcelain -- .keywatch-baseline.json)" ]; then
echo "Baseline unchanged; nothing to do."
exit 0
fi
branch="chore/update-baseline-${{ github.run_id }}"
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"
git checkout -b "$branch"
git add .keywatch-baseline.json
git commit -m "chore: update keywatch baseline"
git push origin "$branch"
gh pr create \
--title "chore: update keywatch baseline" \
--body "Regenerated by the update-baseline workflow. Review every newly baselined finding before merging: each entry is a finding KeyWatch will stop reporting." \
--base "${{ github.ref_name }}"
Loading