Skip to content

enh(secu): stop persisting checkout credentials in scan workflows - #71

Merged
sc979 merged 4 commits into
mainfrom
SECU-checkout-harden-persist-credentials
Sep 29, 2026
Merged

sc979 merged 4 commits into
mainfrom
SECU-checkout-harden-persist-credentials

Conversation

@sc979

@sc979 sc979 commented Sep 21, 2026 •

Copy link
Copy Markdown
Contributor

Fixes: SECU-1231

Description

What are your needs or what are you planning to do in this PR?

Harden the checkout step of both reusable workflows (dependency-analysis.yml, gitleaks-analysis.yml): rename to Checkout sources, keep actions/checkout@3d3c42e5 # v7.0.1 (aligned with #70 / standardised everywhere), and set persist-credentials: false so the GITHUB_TOKEN is not left in the runner git config after checkout. gitleaks keeps fetch-depth: 0.

Regression check vs #64 (SECU-gitleaks-custom):

To keep persist-credentials: false everywhere without regression, #64's refetch() should re-authenticate the fetch via http.extraheader with github.token. Options tracked in the PR discussion / SECU-1231.

🤖 Generated with Claude Code

sc979 and others added 3 commits September 21, 2026 15:18
Harden the checkout step of the dependency-analysis and gitleaks-analysis
reusable workflows: rename to "Checkout sources", pin actions/checkout to
de0fac2e # v6.0.2, and set `persist-credentials: false` so the GITHUB_TOKEN is
not left in the runner git config after checkout. gitleaks keeps fetch-depth: 0.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Per decision to standardise on checkout v7.0.1 everywhere: pin the hardened
"Checkout sources" step to 3d3c42e5 # v7.0.1 (instead of v6.0.2) in both
reusable workflows. persist-credentials: false and the rename are unchanged.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Signed-off-by: Stéphane Chapron <34628915+sc979@users.noreply.github.com>
@sc979
sc979 marked this pull request as ready for review September 29, 2026 14:22
@sc979
sc979 requested a review from a team as a code owner September 29, 2026 14:22
Comment thread .github/workflows/dependency-analysis.yml Outdated
Signed-off-by: Stéphane Chapron <34628915+sc979@users.noreply.github.com>
@sc979
sc979 merged commit 64afec4 into main Sep 29, 2026
5 checks passed
@sc979
sc979 deleted the SECU-checkout-harden-persist-credentials branch September 29, 2026 14:23
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