-
Notifications
You must be signed in to change notification settings - Fork 10
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
verify ec and sboms from private registry #94
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -120,6 +120,13 @@ fi | |
|
||
jq -r '.components[].containerImage' <<< "$IMAGES" | while read -r image; do | ||
echo "Getting attestation for $image" | ||
|
||
image_registry="${image/\/*/}" | ||
# If the repo is not publicly accessible we need to authenticate so ec can access it | ||
prepare-registry-user-pass $image_registry | ||
echo "cosign login to registry $image_registry" | ||
cosign login --username="$IMAGE_REGISTRY_USER" --password="$IMAGE_REGISTRY_PASSWORD" $image_registry | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Looks like this is happening once per image. Since all the images are likely from the same registry, it would be more efficient to just do it once. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. (Discussed on slack. Conclusion: Not a big deal, and actually we might in theory have images in different registries.) |
||
|
||
mkdir -p "$WORKDIR/$image" | ||
cosign_verify_multiple_attestation_types \ | ||
--type slsaprovenance02 \ | ||
|
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.
...authenticate so it can be accessed