Give the gitleaks job the token it needs on pull requests - #5
Merged
Conversation
The action exits before scanning a pull_request event without GITHUB_TOKEN, so the job was green on push and red on every pull request. Being a required check, it blocked all three this repository has had -- among them the bump of this same action.
Both are deliberate and neither was written down, which is how a reduction starts reading as an oversight. A vendor name in the body of a message passes: the allowlist reads the trailer block and nothing else. That is the trade. Catching attribution by key works against any tool, including one that ships tomorrow, where a name list only ever catches what someone already thought to write down. Nothing scans the working tree either. The hand-written hooks under .git/hooks/ that used to are inert wherever they survive, because core.hooksPath makes git ignore that directory. They are not coming back: the same scan matched nothing across the full history of every repository here, and it walked build artefacts, so a full validation run could leave a clean tree unpushable.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The
gitleaksjob exits before scanning onpull_requestevents withoutGITHUB_TOKEN:It is not needed on
push, so the job was green onmainand red on every pull request. Sincegitleaksis a required status check, that combination blocked all three pull requests this repository has had — including #2, which would have upgraded this same action.This PR is also the first real run of the job on a
pull_requestevent, so its result is the verification.