Skip to content

Pinning Trivy GH Action to commit hash for v0.35.0#1519

Merged
lreading merged 1 commit intomainfrom
chore/trivy-action-version-update
Mar 23, 2026
Merged

Pinning Trivy GH Action to commit hash for v0.35.0#1519
lreading merged 1 commit intomainfrom
chore/trivy-action-version-update

Conversation

@lreading
Copy link
Copy Markdown
Collaborator

Summary:

Relates to #1518

Updates all Trivy GH Actions to v0.35.0 - but using the commit hash instead of a version tag.

Our Trivy actions are failing because the tags they reference are no longer available. All tags were removed as part of the containment effort by AcquaSecurity (the makers of Trivy) related to a recent compromise.

Unlike tags, commit hashes are immutable. Even if the git history is rewritten, the commit becomes orphaned rather than overwritten.

Description for the changelog:

Pin Trivy GitHub action to specific commit

Declaration:

Thanks for submitting a pull request, please make sure:

  • content meets the license for this project
  • appropriate unit tests have been created and/or modified
  • you have considered any changes required for the functional tests
  • you have read the contribution guide and agree to the Code of Conduct
  • either no AI-generated content has been used in this pull request
  • or any use of AI in this pull request has been disclosed below:
    • AI Tools: [e.g. GitHub CoPilot, ChatGPT, JetBrains Junie, etc]
    • LLMs and versions: [e.g. GPT-4.1, Claude Haiku 4.5, Gemini 2.5 Pro, etc]
    • Prompts: [Summarize the key prompts or instructions given to the AI tools]

Other info:

This is the exact recommendation from AquaSecurity: https://www.aquasec.com/blog/autonomous-runtime-security-turning-runtime-intelligence-into-agentic-response-2/

I think there needs to be a larger discussion around GH Actions / dependency pinning. Aggressive pinning like this does increase maintenance overhead, and it is also less readable than a tag which is usually a semantic version. However, due to the immutable nature of commit hashes, this is significantly more secure from a dependency management / supply chain hardening perspective.

@lreading lreading self-assigned this Mar 22, 2026
@lreading lreading requested a review from jgadsden as a code owner March 22, 2026 15:27
@lreading lreading added security github_actions Pull requests that update GitHub Actions code Community & Trust Strategic pillar from Threat Dragon's roadmap labels Mar 22, 2026
@lreading
Copy link
Copy Markdown
Collaborator Author

To check for successful credential rotation, I manually ran the CI pipeline: https://github.com/OWASP/threat-dragon/actions/runs/23407258044

No other keys were rotated, so I think we are good.

Copy link
Copy Markdown
Collaborator

@jgadsden jgadsden left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that seemed to do it, thanks @lreading for the investigation

@lreading lreading merged commit 557537e into main Mar 23, 2026
30 of 32 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Community & Trust Strategic pillar from Threat Dragon's roadmap github_actions Pull requests that update GitHub Actions code security

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants