-
Notifications
You must be signed in to change notification settings - Fork 0
ci(release): sign binaries with cosign, attest SLSA L3 provenance #270
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
Merged
Merged
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🔒 Security & Privacy | 🟠 Major | ⚡ Quick win
🧩 Analysis chain
🏁 Script executed:
Repository: getappz/agentflare
Length of output: 156
🏁 Script executed:
Repository: getappz/agentflare
Length of output: 1788
🏁 Script executed:
Repository: getappz/agentflare
Length of output: 1795
🌐 Web query:
slsa-github-generator reusable workflow reference by tag slsa-verifier trusted builder commit SHA release.yml💡 Result:
When using slsa-github-generator, you must reference reusable workflows by a specific semantic version tag (e.g.,
@vX.Y.Z) rather than by commit SHA or shorter tags (like@vXor@vX.Y) [1][2][3]. This requirement is intentional and necessary for slsa-verifier to successfully verify the reference of the trusted builder or generator [1][4]. While this approach deviates from general GitHub Actions best practices—which typically recommend pinning by commit SHA—it is a mandatory constraint due to current technical limitations in GitHub Actions [1][4][5]. Regarding verification, slsa-verifier works by verifying the cryptographic signatures on the generated provenance to confirm it was created by the expected builder [6][7]. It also validates properties such as the builder ID and the source code repository [6][7]. When you need to verify a specific commit SHA, you should use the --print-provenance flag with slsa-verifier to inspect the commit SHA of the config source or materials, rather than specifying the commit SHA directly as an input to the verification flags [6][7]. Summary of Key Practices: - Always reference slsa-github-generator reusable workflows using the full semantic version tag (@vX.Y.Z) [1][8]. - Do not use commit SHAs or short tags for these specific reusable workflow references [2][4][3]. - Use slsa-verifier to check the generated provenance against your expected builder identity and source [6][9]. - For commit SHA validation, inspect the output of slsa-verifier --print-provenance [6][7].Citations:
🏁 Script executed:
Repository: getappz/agentflare
Length of output: 2750
🏁 Script executed:
Repository: getappz/agentflare
Length of output: 3720
🌐 Web query:
site:github.com/slsa-framework/slsa-github-generator README reusable workflow tag commit SHA slsa-verifier verify-artifact💡 Result:
When using
slsa-verifierto verify artifacts generated byslsa-github-generatorreusable workflows, you must reference the reusable workflow using a semantic version tag (e.g.,@vX.Y.Z) rather than a commit SHA or a shorter tag (e.g.,@vXor@vX.Y) [1][2][3]. This requirement is intentional and necessary forslsa-verifierto successfully perform verification [4][5]. Specifically,slsa-verifierneeds to confirm the identity of the trusted builder or generator used to create the provenance [1][6]. Because GitHub Actions does not provide information about the associated branch or tag when a workflow is called by its commit SHA,slsa-verifiercannot distinguish between commits on a trusted branch (likemain) and commits from untrusted sources (such as forks or PRs) [7]. Consequently, referencing by tag is currently the only supported method to ensure the provenance is verifiable [1][4]. While referencing third-party actions by digest is generally considered a best practice in GitHub Actions for security hardening, this specific requirement forslsa-github-generatorworkflows is a known limitation due to how GitHub Actions handles metadata for reusable workflows [4][5]. The technical community tracks this issue (e.g., issue#12in theslsa-verifierrepository) as a point of ongoing development [1][4].Citations:
🏁 Script executed:
Repository: getappz/agentflare
Length of output: 2750
🌐 Web query:
"slsa-github-generator" reusable workflow tag commit SHA slsa-verifier README "full release tag"💡 Result:
When using slsa-github-generator, you must reference the reusable workflow by a full version tag (e.g.,
@v2.1.0) rather than a commit SHA or a short tag (e.g.,@v2) [1][2]. This is a security requirement that allows slsa-verifier to cryptographically verify that the provenance was generated by a trusted, specific version of the generator workflow [3][2]. Referencing by commit SHA is not supported for these reusable workflows because it prevents the verifier from distinguishing between trusted commits and untrusted commits (such as those from pull requests or forks) [3]. Regarding verification with slsa-verifier: 1. Tag Verification: You should not specify a tag in the --source-uri flag [4][5][6]. Instead, if you need to perform source versioning validation, use the --source-tag flag to verify the specific release tag [4][5][6]. 2. Commit SHA Verification: The slsa-verifier does not have a direct flag for commit SHA validation in the same way it does for tags [5][6]. To verify a specific commit SHA, you should use the --print-provenance flag to output the provenance details and then inspect the commit SHA of the config source or materials within that output [4][5][6]. In summary, the generator requires explicit tagging to ensure trust, and the verifier expects you to use specialized flags (--source-tag) for tags or manual inspection (--print-provenance) for commit SHAs [4][2][6].Citations:
Use the
v2.1.0tag hereslsa-github-generatorreusable workflows need a full release tag soslsa-verifiercan validate provenance; the SHA pin breaks that. Switch to@v2.1.0and add a targetedzizmor: ignore[unpinned-uses].Suggested change
📝 Committable suggestion
🤖 Prompt for AI Agents