Skip to content
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

fix: Bump Cosign to latest v2.2.3 #3355

Merged
merged 7 commits into from
Mar 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/builder_container-based_slsa3.yml
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ jobs:
with:
repository: "${{ needs.detect-env.outputs.repository }}"
ref: "${{ needs.detect-env.outputs.ref }}"
go-version: "1.20"
go-version: "1.21"
# Note: This must be the non-randomized binary name, so that it can be downloaded from the release assets.
binary: "${{ env.BUILDER_BINARY }}"
compile-builder: "${{ inputs.compile-builder }}"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/builder_go_slsa3.yml
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ jobs:
with:
repository: "${{ needs.detect-env.outputs.repository }}"
ref: "${{ needs.detect-env.outputs.ref }}"
go-version: "1.20"
go-version: "1.21"
# Note: This must be the non-randomized binary name, so that it can be downloaded from the release assets.
binary: "${{ env.BUILDER_BINARY }}"
compile-builder: "${{ inputs.compile-builder }}"
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/generator_container_slsa3.yml
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ jobs:
with:
repository: "${{ needs.detect-env.outputs.repository }}"
ref: "${{ needs.detect-env.outputs.ref }}"
go-version: "1.20"
go-version: "1.21"
binary: "${{ env.BUILDER_BINARY }}"
compile-builder: "${{ inputs.compile-generator }}"
# NOTE: We are using the generic generator.
Expand All @@ -165,9 +165,9 @@ jobs:
service_account: ${{ inputs.gcp-service-account }}

- id: cosign-install
uses: sigstore/cosign-installer@1fc5bd396d372bee37d608f955b336615edf79c8 # v3.2.0
uses: sigstore/cosign-installer@e1523de7571e31dbe865fd2e80c5c7c23ae71eb4 # v3.4.0
with:
cosign-release: v2.2.1
cosign-release: v2.2.3
continue-on-error: true

# TODO(#2974): consolidate this code into a script
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/generator_generic_slsa3.yml
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ jobs:
with:
repository: "${{ needs.detect-env.outputs.repository }}"
ref: "${{ needs.detect-env.outputs.ref }}"
go-version: "1.20"
go-version: "1.21"
binary: "${{ env.BUILDER_BINARY }}"
compile-builder: "${{ inputs.compile-generator }}"
directory: "${{ env.BUILDER_DIR }}"
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/pre-submit.actions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ jobs:
uses: ./__BUILDER_CHECKOUT_DIR__/.github/actions/secure-project-checkout-go
with:
path: __PROJECT_CHECKOUT_DIR__
go-version: "1.20"
go-version: "1.21"

secure-project-checkout-node:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -499,7 +499,7 @@ jobs:
repository: "slsa-framework/slsa-github-generator"
ref: "main"
compile-builder: true
go-version: "1.20"
go-version: "1.21"
binary: "slsa-generator-generic-linux-amd64"
directory: "internal/builders/generic"

Expand All @@ -516,7 +516,7 @@ jobs:
repository: ${{ steps.detect.outputs.repository }}
ref: ${{ steps.detect.outputs.ref }}
builder-ref: "refs/tags/v1.6.0"
go-version: "1.20"
go-version: "1.21"
binary: "slsa-generator-generic-linux-amd64"
directory: "internal/builders/generic"
# NOTE: compile-builder explicitly set to false.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
actions: read # For the entry point.
uses: ./.github/workflows/builder_go_slsa3.yml
with:
go-version: "1.20"
go-version: "1.21"
config-file: .github/workflows/configs-go/config-ldflags-main-dir.yml
evaluated-envs: "VERSION:${{needs.args.outputs.version}},COMMIT:${{needs.args.outputs.commit}},BRANCH:${{needs.args.outputs.branch}}"
compile-builder: true
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/pre-submit.lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ jobs:
with:
go-version-file: "go.mod"
- env:
GOLANGCI_LINT_VERSION: "1.53.2"
GOLANGCI_LINT_CHECKSUM: "2298f73b9bc03b88b91fee06c5d519fc7f9d7f328e2c388615bbd7e85a9d6cae"
GOLANGCI_LINT_VERSION: "1.57.0"
GOLANGCI_LINT_CHECKSUM: "fc7a9f73d2e3de6aa0ef8d8586906e0067fed577f704b3b0bc29cdd6ad0b74d8"
run: |
set -euo pipefail

Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ jobs:
actions: read # For the entrypoint.
uses: slsa-framework/slsa-github-generator/.github/workflows/builder_go_slsa3.yml@main
with:
go-version: "1.20"
go-version: "1.21"
config-file: .github/workflows/configs-container/config-release.yml
compile-builder: true

Expand All @@ -75,7 +75,7 @@ jobs:
actions: read # For the entrypoint.
uses: slsa-framework/slsa-github-generator/.github/workflows/builder_go_slsa3.yml@main
with:
go-version: "1.20"
go-version: "1.21"
config-file: .github/workflows/configs-generic/config-release.yml
compile-builder: true

Expand All @@ -88,7 +88,7 @@ jobs:
actions: read # For the entrypoint.
uses: slsa-framework/slsa-github-generator/.github/workflows/builder_go_slsa3.yml@main
with:
go-version: "1.20"
go-version: "1.21"
config-file: .github/workflows/configs-go/config-release.yml
compile-builder: true

Expand All @@ -101,6 +101,6 @@ jobs:
actions: read # For the entrypoint.
uses: slsa-framework/slsa-github-generator/.github/workflows/builder_go_slsa3.yml@main
with:
go-version: "1.20"
go-version: "1.21"
config-file: .github/workflows/configs-docker/config-release.yml
compile-builder: true
1 change: 1 addition & 0 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
run:
concurrency: 2
deadline: 5m
timeout: 5m
issues:
# TODO(github.com/slsa-framework/slsa-github-generator/issues/450): revive `package-comments` and `exported` rules.
include:
Expand Down
6 changes: 3 additions & 3 deletions github/oidctest.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ func NewTestOIDCServer(t *testing.T, now time.Time, token *OIDCToken) (*httptest

// FIXME: Fix creating a test server that can return tokens that can be verified.
var issuerURL string
s, c := newTestOIDCServer(t, now, func(w http.ResponseWriter, r *http.Request) {
s, c := newTestOIDCServer(t, now, func(w http.ResponseWriter, _ *http.Request) {
// Allow the token to override the issuer for verification testing.
issuer := issuerURL
if token.Issuer != "" {
Expand Down Expand Up @@ -116,7 +116,7 @@ func NewTestOIDCServer(t *testing.T, now time.Time, token *OIDCToken) (*httptest
}

func newRawTestOIDCServer(t *testing.T, now time.Time, status int, raw string) (*httptest.Server, *OIDCClient) {
return newTestOIDCServer(t, now, func(w http.ResponseWriter, r *http.Request) {
return newTestOIDCServer(t, now, func(w http.ResponseWriter, _ *http.Request) {
// Respond with a very basic 3-part JWT token.
w.WriteHeader(status)
fmt.Fprintln(w, raw)
Expand Down Expand Up @@ -144,7 +144,7 @@ func newTestOIDCServer(t *testing.T, now time.Time, f http.HandlerFunc) (*httpte
}
c := OIDCClient{
requestURL: requestURL,
verifierFunc: func(ctx context.Context) (*oidc.IDTokenVerifier, error) {
verifierFunc: func(_ context.Context) (*oidc.IDTokenVerifier, error) {
return oidc.NewVerifier(s.URL, &testKeySet{}, &oidc.Config{
Now: func() time.Time { return now },
SkipClientIDCheck: true,
Expand Down