Repository navigation
Ship an SBOM with each binary and check for vulnerabilities - #4
Merged
Merged
Conversation
GoReleaser now makes a CycloneDX SBOM for each binary with Syft, from the binary's build information, named like the binary and listed in SHA256SUMS. CI installs Syft, so the snapshot build checks this on every pull request. A govulncheck job fails CI when the code calls a function with a known vulnerability. Its first run found eight standard-library vulnerabilities in what Go 1.27.0 builds, which v0.1.0 and v0.1.1 were built with; Go 1.27.2 fixes them. CI and releases now build with the newest Go release, and go.mod asks for at least 1.27.2, so that "go install" users get the fixes too. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01NTEjHbdKp83qgQgmqR1BJ6
Merged
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
SBOMs. Each release binary now gets a CycloneDX SBOM beside it, such as
rypt-linux-amd64.cdx.json:ryptSDK, andx/crypto,x/sys,x/term.SHA256SUMS. The Homebrew cask is unchanged.govulncheck. A new
vulncheckCI job fails when the code calls a function with a known vulnerability, in a module or in the standard library.Newest Go for builds. govulncheck's first run found something:
net/http,net/http/internal/http2,crypto/tlsandnet/textproto.So:
go-version: stable,check-latest: true), asx6c-co/ryptdoes.go.modnow saysgo 1.27.2, sogo installusers also get a toolchain with the fixes.The one remaining govulncheck note is an
x/cryptoadvisory that has no fix yet and that the CLI never calls.Testing
goreleaser release --snapshot --cleanlocally with GoReleaser v2.18.3 and Syft v1.54.1. It made six SBOMs, named after their binaries and listed inSHA256SUMS, each listingstdlib@1.27.2and the four modules.govulncheck ./...with Go 1.27.2 reports no vulnerabilities affecting the code.make vet testpasses.After merging
Releasing v0.2.0 replaces the affected binaries.
🤖 Generated with Claude Code
https://claude.ai/code/session_01NTEjHbdKp83qgQgmqR1BJ6