-
Notifications
You must be signed in to change notification settings - Fork 46
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Update SLSA verifier to support a global signing key for GCB V1…
… which… (#509) * Update SLSA verifier to support a global signing key for GCB V1 which creates the signature in a DSSE-conformant PAE format - new public key for "global PAE signing key" - test data and unit tests Signed-off-by: Kevin Halk <khalk@google.com> * Update SLSA verifier to support a global signing key for GCB V1 which creates the signature in a DSSE-conformant PAE format - new public key for "global PAE signing key" - test data and unit tests Signed-off-by: Kevin Halk <khalk@google.com> * Update SLSA verifier to support a global signing key for GCB V1 which creates the signature in a DSSE-conformant PAE format - new public key for "global PAE signing key" - test data and unit tests Signed-off-by: Kevin Halk <khalk@google.com> * Update SLSA verifier to support a global signing key for GCB V1 which creates the signature in a DSSE-conformant PAE format - new public key for "global PAE signing key" - test data and unit tests Signed-off-by: Kevin Halk <khalk@google.com> * Update SLSA verifier to support a global signing key for GCB V1 which creates the signature in a DSSE-conformant PAE format - new public key for "global PAE signing key" - test data and unit tests Signed-off-by: Kevin Halk <khalk@google.com> * Update SLSA verifier to support a global signing key for GCB V1 which creates the signature in a DSSE-conformant PAE format - new public key for "global PAE signing key" - test data and unit tests Signed-off-by: Kevin Halk <khalk@google.com> * Update SLSA verifier to support a global signing key for GCB V1 which creates the signature in a DSSE-conformant PAE format - new public key for "global PAE signing key" - test data and unit tests Signed-off-by: Kevin Halk <khalk@google.com> --------- Signed-off-by: Kevin Halk <khalk@google.com>
- Loading branch information
Showing
7 changed files
with
452 additions
and
18 deletions.
There are no files selected for viewing
This file contains 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 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
-----BEGIN PUBLIC KEY----- | ||
MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEdMcJUyKbmarf6dydhfmAjgmK6c42 | ||
oCCNRR1se3Bi3VO65KcGk6qyci6/bsu2s4u+dLKWrsUQomEw4v3FtVctoA== | ||
-----END PUBLIC KEY----- |
This file contains 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 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
114 changes: 114 additions & 0 deletions
114
verifiers/internal/gcb/testdata/gcloud-container-global-pae-signing-key-successful.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,114 @@ | ||
{ | ||
"image_summary": { | ||
"digest": "sha256:f54a58bc1aac5ea1a25d796ae155dc228b3f0e11d046ae276b39c4bf2f13d8c4", | ||
"fully_qualified_digest": "us-central1-docker.pkg.dev/argo-local-khalk/khalk-docker-ar/tagged-world-trigger-964a2eba-62f0-4a53-87d3-4e6dddcc70b3@sha256:f54a58bc1aac5ea1a25d796ae155dc228b3f0e11d046ae276b39c4bf2f13d8c4", | ||
"registry": "us-central1-docker.pkg.dev", | ||
"repository": "khalk-docker-ar" | ||
}, | ||
"provenance_summary": { | ||
"provenance": [ | ||
{ | ||
"build": { | ||
"intotoStatement": { | ||
"_type": "https://in-toto.io/Statement/v0.1", | ||
"predicateType": "https://slsa.dev/provenance/v0.1", | ||
"slsaProvenance": { | ||
"builder": { | ||
"id": "https://cloudbuild.googleapis.com/GoogleHostedWorker@v0.3" | ||
}, | ||
"materials": [ | ||
{ | ||
"digest": { | ||
"sha1": "75c21a6224914056801d5be2316d89de3ff24811" | ||
}, | ||
"uri": "git+https://github.com/khalkie/gcb-repo-staging" | ||
} | ||
], | ||
"metadata": { | ||
"buildFinishedOn": "2023-02-28T15:23:37.764882Z", | ||
"buildInvocationId": "964a2eba-62f0-4a53-87d3-4e6dddcc70b3", | ||
"buildStartedOn": "2023-02-28T15:23:26.521812356Z" | ||
}, | ||
"recipe": { | ||
"arguments": { | ||
"@type": "type.googleapis.com/google.devtools.cloudbuild.v1.Build", | ||
"id": "964a2eba-62f0-4a53-87d3-4e6dddcc70b3", | ||
"name": "projects/265426041527/locations/us-west1/builds/964a2eba-62f0-4a53-87d3-4e6dddcc70b3", | ||
"options": { | ||
"dynamicSubstitutions": true, | ||
"logging": "LEGACY", | ||
"pool": {}, | ||
"requestedVerifyOption": "VERIFIED", | ||
"substitutionOption": "ALLOW_LOOSE" | ||
}, | ||
"sourceProvenance": {}, | ||
"steps": [ | ||
{ | ||
"args": [ | ||
"tag", | ||
"hello-world", | ||
"us-central1-docker.pkg.dev/argo-local-khalk/khalk-docker-ar/tagged-world-trigger-964a2eba-62f0-4a53-87d3-4e6dddcc70b3" | ||
], | ||
"name": "gcr.io/cloud-builders/docker", | ||
"pullTiming": { | ||
"endTime": "2023-02-28T15:23:34.662245150Z", | ||
"startTime": "2023-02-28T15:23:34.654151260Z" | ||
}, | ||
"status": "SUCCESS", | ||
"timing": { | ||
"endTime": "2023-02-28T15:23:35.584468354Z", | ||
"startTime": "2023-02-28T15:23:34.654151260Z" | ||
} | ||
} | ||
], | ||
"substitutions": { | ||
"BRANCH_NAME": "main", | ||
"COMMIT_SHA": "75c21a6224914056801d5be2316d89de3ff24811", | ||
"REF_NAME": "main", | ||
"REPO_NAME": "gcb-repo-staging", | ||
"REVISION_ID": "75c21a6224914056801d5be2316d89de3ff24811", | ||
"SHORT_SHA": "75c21a6", | ||
"TRIGGER_BUILD_CONFIG_PATH": "cloudbuild.yaml", | ||
"TRIGGER_NAME": "github-trigger-staging" | ||
} | ||
}, | ||
"entryPoint": "cloudbuild.yaml", | ||
"type": "https://cloudbuild.googleapis.com/CloudBuildYaml@v0.1" | ||
} | ||
}, | ||
"subject": [ | ||
{ | ||
"digest": { | ||
"sha256": "f54a58bc1aac5ea1a25d796ae155dc228b3f0e11d046ae276b39c4bf2f13d8c4" | ||
}, | ||
"name": "https://us-central1-docker.pkg.dev/argo-local-khalk/khalk-docker-ar/tagged-world-trigger-964a2eba-62f0-4a53-87d3-4e6dddcc70b3" | ||
}, | ||
{ | ||
"digest": { | ||
"sha256": "f54a58bc1aac5ea1a25d796ae155dc228b3f0e11d046ae276b39c4bf2f13d8c4" | ||
}, | ||
"name": "https://us-central1-docker.pkg.dev/argo-local-khalk/khalk-docker-ar/tagged-world-trigger-964a2eba-62f0-4a53-87d3-4e6dddcc70b3:latest" | ||
} | ||
] | ||
} | ||
}, | ||
"createTime": "2023-02-28T15:23:39.650659Z", | ||
"envelope": { | ||
"payload": "eyJfdHlwZSI6Imh0dHBzOi8vaW4tdG90by5pby9TdGF0ZW1lbnQvdjAuMSIsInByZWRpY2F0ZSI6eyJidWlsZGVyIjp7ImlkIjoiaHR0cHM6Ly9jbG91ZGJ1aWxkLmdvb2dsZWFwaXMuY29tL0dvb2dsZUhvc3RlZFdvcmtlckB2MC4zIn0sIm1hdGVyaWFscyI6W3siZGlnZXN0Ijp7InNoYTEiOiI3NWMyMWE2MjI0OTE0MDU2ODAxZDViZTIzMTZkODlkZTNmZjI0ODExIn0sInVyaSI6ImdpdCtodHRwczovL2dpdGh1Yi5jb20va2hhbGtpZS9nY2ItcmVwby1zdGFnaW5nIn1dLCJtZXRhZGF0YSI6eyJidWlsZEZpbmlzaGVkT24iOiIyMDIzLTAyLTI4VDE1OjIzOjM3Ljc2NDg4MloiLCJidWlsZEludm9jYXRpb25JZCI6Ijk2NGEyZWJhLTYyZjAtNGE1My04N2QzLTRlNmRkZGNjNzBiMyIsImJ1aWxkU3RhcnRlZE9uIjoiMjAyMy0wMi0yOFQxNToyMzoyNi41MjE4MTIzNTZaIn0sInJlY2lwZSI6eyJhcmd1bWVudHMiOnsiQHR5cGUiOiJ0eXBlLmdvb2d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YxM2Q4YzQifSwibmFtZSI6Imh0dHBzOi8vdXMtY2VudHJhbDEtZG9ja2VyLnBrZy5kZXYvYXJnby1sb2NhbC1raGFsay9raGFsay1kb2NrZXItYXIvdGFnZ2VkLXdvcmxkLXRyaWdnZXItOTY0YTJlYmEtNjJmMC00YTUzLTg3ZDMtNGU2ZGRkY2M3MGIzOmxhdGVzdCJ9XX0=", | ||
"payloadType": "application/vnd.in-toto+json", | ||
"signatures": [ | ||
{ | ||
"keyid": "projects/verified-builder/locations/global/keyRings/attestor/cryptoKeys/provenanceSigner/cryptoKeyVersions/1", | ||
"sig": "MEUCIQCJQRkaJuajYy_KKV71VYS13QLdp57pAdQMVXucy3Ev-wIgBCcaPtO16_WWhRrPWVpxrTxtypNVLAqIVeywNYk2-Xk=" | ||
} | ||
] | ||
}, | ||
"kind": "BUILD", | ||
"name": "projects/argo-local-khalk/occurrences/26a014ac-3779-4a0b-98da-2d804f257f3d", | ||
"noteName": "projects/argo-qa/notes/intoto_964a2eba-62f0-4a53-87d3-4e6dddcc70b3", | ||
"resourceUri": "https://us-central1-docker.pkg.dev/argo-local-khalk/khalk-docker-ar/tagged-world-trigger-964a2eba-62f0-4a53-87d3-4e6dddcc70b3@sha256:f54a58bc1aac5ea1a25d796ae155dc228b3f0e11d046ae276b39c4bf2f13d8c4", | ||
"updateTime": "2023-02-28T15:23:39.650659Z" | ||
} | ||
] | ||
} | ||
} |
Oops, something went wrong.