Skip to content

Fix: GitHub workflow script injection #1920

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

Closed
wants to merge 1 commit into from

Conversation

joycebrum
Copy link
Contributor

Hi! I'm Joyce from Google's Open Source Security Team(GOSST) and I'm here to suggest this small fix to prevent from script injection attacks through the GitHub workflows.

You can see further explanation about this kind of threat in this blogpost Keeping your GitHub Actions and workflows secure Part 2: Untrusted input.

Changes

  • Parse both github.head_ref and github.event.pull_request.head.ref to envvars to prevent potential script injection.

Any questions, let me know!

@joycebrum joycebrum requested a review from a team as a code owner November 13, 2024 17:39
Copy link
Contributor

github-actions bot commented Nov 13, 2024

MLCommons CLA bot All contributors have signed the MLCommons CLA ✍️ ✅

@joycebrum
Copy link
Contributor Author

recheck

@joycebrum joycebrum closed this Nov 14, 2024
@github-actions github-actions bot locked and limited conversation to collaborators Nov 14, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant