Skip to content

fix(security): scope TruffleHog hook to staged files only#35

Open
williaby wants to merge 1 commit into
mainfrom
fix/trufflehog-staged-scope
Open

fix(security): scope TruffleHog hook to staged files only#35
williaby wants to merge 1 commit into
mainfrom
fix/trufflehog-staged-scope

Conversation

@williaby
Copy link
Copy Markdown
Contributor

@williaby williaby commented May 8, 2026

Summary

Replace trufflehog git file://. --since-commit HEAD with a staged-files form.

Why

Resolves observation #4 from the skill observation log; part of the fleet-wide
TruffleHog rollout. See .claude/rules/pre-commit.md PC-HOOK-STAGED-SCOPE.

Generated with Claude Code

Replace `trufflehog git file://. --since-commit HEAD` with a staged-files
scan via `git diff --cached | xargs trufflehog filesystem`. The git-history
mode also traverses fetched remote branches in the local object store, which
produces false positives from placeholder credentials in unmerged branches.

See `.claude/rules/pre-commit.md` invariant `PC-HOOK-STAGED-SCOPE` for the
general principle (pre-commit hooks must scope to staged files only;
full-history scanning belongs in CI).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@williaby williaby enabled auto-merge (squash) May 8, 2026 17:30
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 8, 2026

Warning

Rate limit exceeded

@williaby has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 19 minutes and 25 seconds before requesting another review.

You’ve run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 1be30d50-22c7-4871-aea1-57a9dedba2e4

📥 Commits

Reviewing files that changed from the base of the PR and between c0eb24a and e937b25.

📒 Files selected for processing (1)
  • .pre-commit-config.yaml
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/trufflehog-staged-scope

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud Bot commented May 8, 2026

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant