fix: pin pypa/gh-action-pypi-publish to a commit SHA#115
Merged
Conversation
Resolves the SonarQube security hotspot (githubactions:S7637): external GitHub Actions should be pinned to a full commit SHA rather than a mutable tag/branch ref. Pin pypa/gh-action-pypi-publish to the v1.14.0 commit SHA. Signed-off-by: jor2 <jordanwilliams997@hotmail.com>
Collaborator
|
✅ SonarQube Quality Gate: PASSED |
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.
Follow-up to #109 to resolve the SonarQube security hotspot.
Hotspot:
githubactions:S7637— Using external GitHub actions and workflows without a commit reference is security-sensitive. Flagged on.github/workflows/release.ymlline 57.A mutable ref like
@release/v1can be repointed at any time, so a compromise of that branch would run untrusted code with ourid-token: write/contents: writepermissions during a release. Pinning to a full commit SHA makes the action immutable.Change:
The SHA is the commit behind the v1.14.0 release tag. The trailing
# v1.14.0comment keeps it human-readable and is the convention Dependabot understands for future bumps.The
actions/checkoutandactions/setup-pythonuses are first-party GitHub-owned actions and are not flagged by the rule, so they're left as-is.