Pin unpinned-action references across 3 workflows#184
Open
CodeOpsAI wants to merge 3 commits into
Open
Conversation
This PR addresses 17 workflow findings: - [low] unpinned-action in .github/workflows/lint.yml: Unpinned action version: actions/checkout@v4 - [low] unpinned-action in .github/workflows/lint.yml: Unpinned action version: actions/setup-go@v5 - [medium] unpinned-action in .github/workflows/lint.yml: Unpinned action version: golangci/golangci-lint-action@v7 - [low] unpinned-action in .github/workflows/release.yml: Unpinned action version: actions/checkout@v4 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/metadata-action@v3 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/setup-qemu-action@v1 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/setup-buildx-action@v1 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/login-action@v1 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/login-action@v1 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/build-push-action@v2 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: peter-evans/dockerhub-description@v3 - [low] unpinned-action in .github/workflows/release.yml: Unpinned action version: actions/setup-go@v5 - [low] unpinned-action in .github/workflows/test.yml: Unpinned action version: actions/checkout@v2 - [low] unpinned-action in .github/workflows/test.yml: Unpinned action version: actions/setup-go@v5 - [low] unpinned-action in .github/workflows/test.yml: Unpinned action version: actions/upload-artifact@v4 - [low] unpinned-action in .github/workflows/test.yml: Unpinned action version: actions/checkout@v2 - [medium] unpinned-action in .github/workflows/test.yml: Unpinned action version: fgrosse/go-coverage-report@v1.1.1 These workflows handle CI/CD with elevated privileges; the affected configurations expand attack surface or grant tokens broader access than needed. See the PR description for per-finding rationale and citations.
This PR addresses 17 workflow findings: - [low] unpinned-action in .github/workflows/lint.yml: Unpinned action version: actions/checkout@v4 - [low] unpinned-action in .github/workflows/lint.yml: Unpinned action version: actions/setup-go@v5 - [medium] unpinned-action in .github/workflows/lint.yml: Unpinned action version: golangci/golangci-lint-action@v7 - [low] unpinned-action in .github/workflows/release.yml: Unpinned action version: actions/checkout@v4 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/metadata-action@v3 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/setup-qemu-action@v1 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/setup-buildx-action@v1 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/login-action@v1 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/login-action@v1 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/build-push-action@v2 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: peter-evans/dockerhub-description@v3 - [low] unpinned-action in .github/workflows/release.yml: Unpinned action version: actions/setup-go@v5 - [low] unpinned-action in .github/workflows/test.yml: Unpinned action version: actions/checkout@v2 - [low] unpinned-action in .github/workflows/test.yml: Unpinned action version: actions/setup-go@v5 - [low] unpinned-action in .github/workflows/test.yml: Unpinned action version: actions/upload-artifact@v4 - [low] unpinned-action in .github/workflows/test.yml: Unpinned action version: actions/checkout@v2 - [medium] unpinned-action in .github/workflows/test.yml: Unpinned action version: fgrosse/go-coverage-report@v1.1.1 These workflows handle CI/CD with elevated privileges; the affected configurations expand attack surface or grant tokens broader access than needed. See the PR description for per-finding rationale and citations.
This PR addresses 17 workflow findings: - [low] unpinned-action in .github/workflows/lint.yml: Unpinned action version: actions/checkout@v4 - [low] unpinned-action in .github/workflows/lint.yml: Unpinned action version: actions/setup-go@v5 - [medium] unpinned-action in .github/workflows/lint.yml: Unpinned action version: golangci/golangci-lint-action@v7 - [low] unpinned-action in .github/workflows/release.yml: Unpinned action version: actions/checkout@v4 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/metadata-action@v3 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/setup-qemu-action@v1 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/setup-buildx-action@v1 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/login-action@v1 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/login-action@v1 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: docker/build-push-action@v2 - [medium] unpinned-action in .github/workflows/release.yml: Unpinned action version: peter-evans/dockerhub-description@v3 - [low] unpinned-action in .github/workflows/release.yml: Unpinned action version: actions/setup-go@v5 - [low] unpinned-action in .github/workflows/test.yml: Unpinned action version: actions/checkout@v2 - [low] unpinned-action in .github/workflows/test.yml: Unpinned action version: actions/setup-go@v5 - [low] unpinned-action in .github/workflows/test.yml: Unpinned action version: actions/upload-artifact@v4 - [low] unpinned-action in .github/workflows/test.yml: Unpinned action version: actions/checkout@v2 - [medium] unpinned-action in .github/workflows/test.yml: Unpinned action version: fgrosse/go-coverage-report@v1.1.1 These workflows handle CI/CD with elevated privileges; the affected configurations expand attack surface or grant tokens broader access than needed. See the PR description for per-finding rationale and citations.
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.
About codeopsai
codeopsai analyzes public GitHub Actions workflows for security and reliability issues and opens fixes for maintainer review. Every PR carries citations to the relevant standard (CWE, GitHub docs) and a structural verification trail; if our evidence bar isn't met, we don't open the PR.
Mistake, or unwelcome? Comment here or open an issue at github.com/codeopsai/feedback. We read every one and adjust.
Why these matter
Why pin to a SHA (
unpinned-action)Each unpinned action reference can be force-moved to attacker-controlled code by the action's owner or anyone who compromises their account — exactly what happened in the tj-actions/changed-files attack (CVE-2025-30066, Mar 2025). Pinning to a 40-character commit SHA freezes the exact reviewed code.
Reference: CWE-829 · GitHub/OWASP guidance · Real-world precedent: tj-actions/changed-files supply-chain attack (CVE-2025-30066, Mar 2025)
.github/workflows/lint.ymlgolangci/golangci-lint-action(joblint)actions/checkout(joblint)actions/setup-go(joblint)Diff
.github/workflows/release.ymldocker/metadata-action(jobdocker)docker/setup-qemu-action(jobdocker)docker/setup-buildx-action(jobdocker)docker/login-action(jobdocker)docker/login-action(jobdocker)docker/build-push-action(jobdocker)peter-evans/dockerhub-description(jobdocker)actions/checkout(jobdocker)actions/setup-go(jobdocker)Diff
.github/workflows/test.ymlfgrosse/go-coverage-report(jobcode_coverage)actions/checkout(jobtest)actions/setup-go(jobtest)actions/upload-artifact(jobtest)actions/checkout(jobcode_coverage)Diff
Have other repositories you'd like analysed? Request a scan at codeopsai.com.
AI-generated. Review the diff before merging.