Skip to content

Commit d5393c2

Browse files
authored
[CI] Upgrade cosign; Wait 30s between signing and verifying signature (#1412)
1 parent e6dc718 commit d5393c2

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

.github/workflows/dss-publish.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,7 @@ jobs:
2525

2626
steps:
2727
- name: Install Cosign
28-
uses: sigstore/cosign-installer@v3.9.1
29-
28+
uses: sigstore/cosign-installer@cad07c2e89fa2edd6e2d7bab4c1aa38e53f76003 # v4.1.1
3029
- name: Job information
3130
run: |
3231
echo "Job information"

build/build.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,9 @@ else
5656
echo "Signing docker image ${TAG} (digest: ${DIGEST})..."
5757
cosign sign --yes "${DIGEST}"
5858

59-
echo "Verifying signature of docker image ${TAG} (digest: ${DIGEST})..."
60-
cosign verify "${DIGEST}" --certificate-identity="${CERT_IDENTITY}" --certificate-oidc-issuer="${CERT_ISSUER}"
59+
echo "Verifying signature of docker image ${TAG} (digest: ${DIGEST}) after a 30 seconds wait..."
60+
sleep 30 # the signature may not be returned immediately after being published, so as a mitigation we wait for 30 seconds before verifying
61+
cosign verify --certificate-identity="${CERT_IDENTITY}" --certificate-oidc-issuer="${CERT_ISSUER}" "${DIGEST}"
6162

6263
echo "Signed and verified signature of docker image ${TAG} (digest: ${DIGEST})..."
6364

0 commit comments

Comments
 (0)