Fix: pin ruyaml with uv lockfile and 4-day cooldown#611
Merged
Conversation
Replace `pip install ruyaml` with `uv run` backed by a locked `pyproject.toml` / `uv.lock` and a 4-day `exclude-newer` cooldown. This prevents a compromised latest ruyaml from being pulled into workflows that run with contents:write, which could otherwise be exploited to modify actions.yml and inject malicious allowed actions. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Member
Author
|
This is important to review and merge as this solves an existing security risk with the action itself @dfoulks1 @gmcdonald @raboof |
Member
Author
|
This might get exploited in attack similar to |
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.
Summary
pip install ruyamlin workflows withcontents:writepermission (update_actions,update_dummy,remove_expired) fetched the latest version from PyPI on every run. A compromised ruyaml release could exploit this to modifyactions.ymland inject malicious allowed actions into the ASF organization-wide allowlist.pyproject.tomlwithuv.lockand a 4-dayexclude-newercooldown. All gateway workflows now usepipx install uv+uv runinstead ofpip install ruyaml, ensuring only locked, vetted versions are used.uvpackage ecosystem todependabot.yml(with 4-day cooldown) to keepuv.lockupdated via PRs.Test plan
update_actionsworkflow runs successfully on PRremove_expiredworkflow runs successfullyupdate_dummyworkflow runs successfullypytestworkflow passesuvecosystem🤖 Generated with Claude Code