Skip to content

Harden PR Builder Dependabot PR builder check#769

Merged
JackPGreen merged 1 commit intohazelcast:masterfrom
JackPGreen:Harden-PR-Builder-Dependabot-PR-builder-check
Mar 23, 2026
Merged

Harden PR Builder Dependabot PR builder check#769
JackPGreen merged 1 commit intohazelcast:masterfrom
JackPGreen:Harden-PR-Builder-Dependabot-PR-builder-check

Conversation

@JackPGreen
Copy link
Copy Markdown
Contributor

The PR builder checks the github.actor to determine if it's a Dependabot PR, and if so allows execution.

This check is flawed - the actor is the user triggering the event, not necessarily the author of the PR - as such it's possible to create an event where the triggering actor is dependabot but the codebase is not. Instead, we should check if dependabot authored the PR.

References:

The PR builder checks the `github.actor` to determine if it's a Dependabot PR, and if so allows execution.

This check is flawed - the `actor` is the user triggering the event, not necessarily the author of the PR - as such it's possible to create an event where the triggering actor is `dependabot` but the codebase is not. Instead, we should check if `dependabot` _authored_ the PR.

References:
- https://www.synacktiv.com/publications/github-actions-exploitation-dependabot
- https://docs.zizmor.sh/audits/#bot-conditions#
- [GitHub first-party usage](https://github.com/github/docs/blob/7cbca58400edbc80b22512947ec96563bc984bf1/.github/workflows/triage-unallowed-contributions.yml#L17-L22)
Copy link
Copy Markdown
Contributor

@nishaatr nishaatr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@JackPGreen JackPGreen merged commit c0226e4 into hazelcast:master Mar 23, 2026
3 checks passed
@JackPGreen JackPGreen deleted the Harden-PR-Builder-Dependabot-PR-builder-check branch March 23, 2026 16:49
JackPGreen added a commit to hazelcast/hazelcast-wm that referenced this pull request Mar 23, 2026
JackPGreen added a commit to hazelcast/dependabot-automerge that referenced this pull request Mar 24, 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.

2 participants