Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix matcher bug with blossom-ci #3382

Open
wants to merge 1 commit into
base: release/8.6
Choose a base branch
from

Conversation

AdnaneKhan
Copy link

It is possible to bypass the first check for users approved to run the blossom CI by creating a username that is a partial match. Per GitHub documentation, if the search param in contains is a string, it returns true upon a partial match. https://docs.github.com/en/actions/learn-github-actions/expressions#contains

See #3063 for an example where I used an account that partially matched @samurdhikaru 's name.

The resulting workflow failed at the next check, so there isn't security impact (and why I am making a PR instead of disclosing privately). Updating the check to use an array will prevent someone from bypassing the actor check in this manner.

… the github.actor instead of string contains.

Signed-off-by: Adnan Khan <[email protected]>
@AdnaneKhan
Copy link
Author

@rajeevsrao @samurdhikaru, any interest in fixing this, or should I just close the PR?

@rajeevsrao
Copy link
Collaborator

@samurdhikaru please advise on next steps.

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.

None yet

2 participants