Skip to content

ci(gitleaks): allowlist uploads signed-URL integration test - #220

Closed
lilyshen0722 wants to merge 1 commit into
mainfrom
fix/gitleaks-allowlist-uploads-signedurl-test
Closed

ci(gitleaks): allowlist uploads signed-URL integration test#220
lilyshen0722 wants to merge 1 commit into
mainfrom
fix/gitleaks-allowlist-uploads-signedurl-test

Conversation

@lilyshen0722

Copy link
Copy Markdown
Contributor

Summary

  • Secret Scan has been failing on main since dd1b310918 (PR feat(uploads): ADR-002 Phase 1b-a — signed-URL mint + ACL + audit log #216, ADR-002 Phase 1b-a)
  • Gitleaks flags process.env.JWT_SECRET = 'test-jwt-secret-adr002-integration' at backend/__tests__/integration/uploads.signedurl.integration.test.js:47 as a generic-api-key leak
  • It's a test fixture constant, not a real secret — same situation as integrations-e2e.test.js, which is already in the allowlist
  • Fix: add the new integration test file to the existing [allowlist] paths block in .gitleaks.toml

Why not delete the line

The gitleaks workflow scans full branch history (--log-opts="--branches --remotes=origin/main ..."), so deleting the line in a follow-up commit doesn't clear the finding — the commit it was introduced in would still hit. An allowlist entry is the standard fix for test fixtures and matches existing convention in this file.

Test plan

  • Secret Scan passes on this PR
  • Secret Scan passes on main after merge

🤖 Generated with Claude Code

Gitleaks flagged process.env.JWT_SECRET = 'test-jwt-secret-adr002-integration'
in backend/__tests__/integration/uploads.signedurl.integration.test.js as a
generic-api-key leak. It's a test fixture constant, not a real secret —
same pattern as integrations-e2e.test.js which is already allowlisted.

Fixes Secret Scan failures on main since commit dd1b310.
lilyshen0722 added a commit that referenced this pull request Apr 21, 2026
Gitleaks flagged process.env.JWT_SECRET = 'test-jwt-secret-adr002-integration'
in backend/__tests__/integration/uploads.signedurl.integration.test.js as a
generic-api-key leak. It's a test fixture constant, not a real secret —
same pattern as integrations-e2e.test.js which is already allowlisted.

Fixes Secret Scan failures on main since commit dd1b310.
@lilyshen0722

Copy link
Copy Markdown
Contributor Author

Squash-merged to main as 79eafe4.

@lilyshen0722
lilyshen0722 deleted the fix/gitleaks-allowlist-uploads-signedurl-test branch April 21, 2026 01:15
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