Halloween DealsAmazon USHalloween week deals: useful picks before month-endAmazon US: current deals, useful picks and tech finds.Check DealsPC HealthRecommendedCrashes, freezes, slowdowns? Check your PC nowSpot repairable issues before they interrupt work.Check PCHalloween DealsAmazon USOctober picks are moving - compare before checkoutAmazon US: current deals, useful picks and tech finds.See Picks×
FREEDOM251

Freedom251 › Blog › container security

How to Verify Docker Images with Cosign and Sigstore Before Deploying

By Freedom251 Team · · 11 min read

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Verify the exact image digest you will run, require the signer identity and OpenID Connect issuer approved by your build system, and put the same check in your deployment path. With Cosign, a successful keyless verification confirms that the signed bytes match the selected image and that the certificate chains to the configured identity and transparency evidence; it does not, by itself, prove that the image is vulnerability-free.

What Cosign verification establishes

Container tags are mutable labels. A tag such as registry.example/team/app:prod can point to a different manifest later, so verifying a tag and deploying the tag can produce two different results. The reliable unit of verification is an immutable digest reference:

As an Amazon Associate I earn from qualifying purchases.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
registry.example/team/app@sha256:IMAGE_DIGEST

Cosign’s normal claim checks compare the manifest digest recorded in the signed payload with the image reference being verified. If the digest differs, verification should fail rather than silently approving another image.

A successful signature check answers a narrow question: under your configured trust rules, did an approved signing identity sign this exact artifact? It does not answer whether the image has known vulnerabilities, whether it contains only permitted packages, or whether its build process meets every internal requirement. Those questions require vulnerability scanning, provenance or other attestations, and an explicit policy.

#1 Best Overall
Yubico - Security Key C NFC - Basic Compatibility - Multi-Factor authentication (MFA) Security Key and passkey, Connect via USB-C or NFC, FIDO Certified
  • POWERFUL SECURITY KEY: The Security Key C NFC is the essential physical passkey for protecting your digital life from phishing attacks. It ensures only you can access your accounts.
  • WORKS WITH 1000+ ACCOUNTS: Compatible with Google, Microsoft, and Apple. A single Security Key C NFC secures 100 of your favorite accounts, including email, password managers, and more.
  • FAST & CONVENIENT LOGIN: Plug in your Security Key C NFC via USB-C and tap it, or tap it against your phone (NFC) to authenticate. No batteries, no internet connection, and no extra fees required.
  • TRUSTED PASSKEY TECHNOLOGY: Uses the latest passkey standards (FIDO2/WebAuthn & FIDO U2F) but does not support One-Time Passwords. For complex needs, check out the YubiKey 5 Series.
  • BUILT TO LAST: Made from tough, waterproof, and crush-resistant materials. Manufactured in Sweden and programmed in the USA with the highest security standards.

Prerequisites and trust decisions

  • Install Cosign from a release and installation method approved by your organization. Pin the tool version in CI where reproducibility matters; command flags, bundle formats and release behavior can change.
  • Know the registry, repository and immutable digest that the deployment will use.
  • Obtain the expected signer identity and OIDC issuer from the trusted build workflow. Do not accept any identity merely because a mathematically valid signature exists.
  • Ensure the verifier can read the image and its OCI signature referrers. Cosign normally stores signatures in the same repository as the image.
  • Decide whether your organization uses keyless identity verification, an organization-managed public key, or both for different workloads.

Write these decisions into policy before adding a gate. A policy that says “has a valid signature” is weaker than one that names the permitted workflow identity, issuer, repository and digest relationship.

Step 1: Resolve and pin the image digest

Use the reference that deployment will consume

Resolve the tag in your release process, then carry the resulting digest through verification and deployment. For example, the release manifest should contain:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
image: registry.example/team/app@sha256:IMAGE_DIGEST

Do not verify :latest and later deploy a tag that may have moved. If your orchestrator accepts both a tag and digest, prefer the digest-only form or configure the release tooling to reject a changed digest.

Keep the digest immutable across stages

Promoting an image from staging to production should copy or reference the same digest, not rebuild it under a new tag. Record the digest in the change request, deployment artifact or lock file so that an operator can compare the value reviewed by security with the value sent to the cluster.

Step 2: Verify a keyless signature

Sigstore keyless signing uses an OpenID Connect identity and a short-lived code-signing certificate. The certificate contains an ephemeral public key. The signed evidence also includes a signature, a signed timestamp and proof that the event was included in Sigstore’s transparency log. For container images, Cosign attaches the signature and certificate to the image in the registry, so the basic verification command does not require a separately supplied bundle.

Run this check with the exact digest and the identity and issuer expected from your build system:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #2
Yubico - YubiKey 5C NFC - Multi-Factor authentication (MFA) Security Key and passkey, Connect via USB-C or NFC, FIDO Certified - Protect Your Online Accounts
  • POWERFUL SECURITY KEY: The YubiKey 5C NFC is the most versatile physical passkey, protecting your digital life from phishing attacks. It ensures only you can access your accounts
  • WORKS WITH 1000+ ACCOUNTS: Compatible with popular accounts like Google, Microsoft, and Apple. A single YubiKey 5C NFC secures 100+ of your favorite accounts, including email, password managers, and more
  • FAST & CONVENIENT LOGIN: Plug in your YubiKey 5C NFC via USB and tap it, or tap it against your phone (NFC), to authenticate. No batteries, no internet connection, and no extra fees required
  • MOST SECURE PASSKEY: Supports FIDO2/WebAuthn, FIDO U2F, Yubico OTP, OATH-TOTP/HOTP, Smart card (PIV), and OpenPGP. That means it’s versatile, working almost anywhere you need it
  • PRIMARY & SPARE KEYS: Just like having a spare house key, we recommend buying two YubiKeys - one for daily use and one as a spare. That way you’ll never get locked out of your accounts
cosign verify 
  --certificate-identity='EXPECTED_IDENTITY' 
  --certificate-oidc-issuer='EXPECTED_OIDC_ISSUER' 
  'registry.example/team/app@sha256:IMAGE_DIGEST'

Replace both placeholders with concrete values. An identity might represent a workflow, repository or service account, while the issuer identifies the identity provider that issued the certificate. Sigstore documentation shows issuer patterns for Google, Microsoft, GitHub and GitLab identities; use the exact issuer value emitted by your approved workflow rather than a shortened name.

Why both identity and issuer are required

The certificate identity alone is not a complete trust boundary. Different identity providers can issue certificates containing similar subject values, and an issuer can serve many unrelated projects. Requiring both values narrows acceptance to the intended workflow and provider.

Use strict matching in deployment gates

Cosign supports matching expressions, but a deployment gate should avoid permissive regular expressions such as a pattern that accepts every repository or branch. Match the precise workflow identity, organization or repository convention that your build team controls. If identities legitimately vary, enumerate the approved values in policy and review changes like code.

Step 3: Understand what a successful result means

Cosign validates the signature, certificate and transparency evidence, then checks image claims. The default claim check is important because it connects the signed payload to the digest you supplied. A successful result means:

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  • The signature is cryptographically valid for the signed payload.
  • The certificate satisfies the identity and issuer constraints you supplied.
  • The transparency evidence is acceptable to the verification process.
  • The signed image claim matches the selected image digest under the normal claim checks.

It does not mean that every package in the image is safe or that the image complies with your license, malware, configuration or provenance requirements. Treat signature verification as one control in a larger release policy.

Do not disable claim checks as a routine workaround

The --check-claims=false option disables claim validation. The verification documentation warns that claims will then not be verified. Using this flag can turn a check of “who signed this payload?” into a check that no longer answers “did that payload describe the image I selected?” If a verification fails, fix the reference, registry access or signing workflow instead of turning off claim checks.

Rank #3
Yubico - YubiKey 5 NFC - Multi-Factor authentication (MFA) Security Key and passkey, Connect via USB-A or NFC, FIDO Certified - Protect Your Online Accounts
  • POWERFUL SECURITY KEY: The YubiKey 5 NFC is the most versatile physical passkey, protecting your digital life from phishing attacks. It ensures only you can access your accounts
  • WORKS WITH 1000+ ACCOUNTS: Compatible with popular accounts like Google, Microsoft, and Apple. A single YubiKey 5 NFC secures 100+ of your favorite accounts, including email, password managers, and more
  • FAST & CONVENIENT LOGIN: Plug in your YubiKey 5 NFC via USB and tap it, or tap it against your phone (NFC), to authenticate. No batteries, no internet connection, and no extra fees required
  • MOST SECURE PASSKEY: Supports FIDO2/WebAuthn, FIDO U2F, Yubico OTP, OATH-TOTP/HOTP, Smart card (PIV), and OpenPGP. That means it’s versatile, working almost anywhere you need it
  • PRIMARY & SPARE KEYS: Just like having a spare house key, we recommend buying two YubiKeys - one for daily use and one as a spare. That way you’ll never get locked out of your accounts

Step 4: Verify with an organization-managed public key

Key-based verification is appropriate when your organization operates a stable signing key and distributes its public key through a controlled channel. The basic form is:

cosign verify --key cosign.pub 
  'registry.example/team/app@sha256:IMAGE_DIGEST'

The public key must come from a reliable organizational source, such as a version-controlled policy repository or managed trust package. Do not download an unverified key beside the image and treat it as authoritative; an attacker who can replace both the image and the key could produce a locally “valid” result.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Key-based systems require a lifecycle for private-key protection, rotation, revocation and distribution of new public keys. Organizations with internal PKI can also configure certificate-chain or custom-root verification. The trust root, intermediate certificates and rotation procedure should be documented before production rollout.

Keyless versus key-based verification

Decision area Keyless identity verification Organization-managed public key
Signer identity Certificate identity plus OIDC issuer, tied to a workload or user identity Any holder of the corresponding private key unless additional controls are added
Key custody Ephemeral signing key and short-lived certificate; the signing service handles issuance Organization must protect, back up and rotate the private key
Rotation Identity and issuer policy usually remains stable while ephemeral keys change Public-key distribution and trust-root updates are required when keys rotate
Workload integration Works naturally with CI workload identity and OIDC tokens Requires secure access to a long-lived or centrally managed signing key
Operational complexity Less key distribution, but identity-provider and transparency-log dependencies More direct control, but greater responsibility for custody, revocation and trust distribution

Neither model removes the need to constrain which repository, workflow or environment may sign. Select the model that matches your identity infrastructure and operational ability to manage trust roots.

Signatures, annotations and attestations are different controls

Signatures

cosign verify checks the image signature, certificate or key trust and image claims. This is the control that establishes that the selected digest was signed by an approved identity.

Annotations

Signatures can carry key/value annotations. A policy can require expected annotation values, such as a release channel or build environment. Annotation checks should be treated as additional claims, not as a replacement for identity and digest validation.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #4
Yubico - Security Key NFC - Basic Compatibility - Multi-Factor Authentication (MFA) Key, Connect via USB-A or NFC, FIDO Certified
  • POWERFUL SECURITY KEY: The Security Key NFC is the essential physical passkey for protecting your digital life from phishing attacks. It ensures only you can access your accounts.
  • WORKS WITH 1000+ ACCOUNTS: Compatible with Google, Microsoft, and Apple. A single Security Key NFC secures 100 of your favorite accounts, including email, password managers, and more.
  • FAST & CONVENIENT LOGIN: Plug in your Security Key NFC via USB-A and tap it, or tap it against your phone (NFC) to authenticate. No batteries, no internet connection, and no extra fees required.
  • TRUSTED PASSKEY TECHNOLOGY: Uses the latest passkey standards (FIDO2/WebAuthn & FIDO U2F) but does not support One-Time Passwords. For complex needs, check out the YubiKey 5 Series.
  • BUILT TO LAST: Made from tough, waterproof, and crush-resistant materials. Manufactured in Sweden and programmed in the USA with the highest security standards.

Attestations

cosign verify-attestation verifies an attestation attached to an artifact. Attestations can contain predicates such as build provenance, but verification alone does not define what is acceptable. Your policy must state which predicate type, builder, source repository, build parameters or review status is required.

A practical release policy might require all three layers: a signature from the production build identity, a provenance attestation from an approved builder, and a vulnerability result below a defined severity threshold. Keep each requirement explicit so a valid signature is not mistaken for a complete security review.

Put verification in the deployment pipeline

Pipeline gate

Run verification after the image is built and pushed, but before the deployment manifest is promoted. The pipeline should fail closed when Cosign exits unsuccessfully.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  1. Build the image and push it to the approved registry.
  2. Resolve the pushed tag to its digest and write that digest into the release manifest.
  3. Run cosign verify with the exact digest, expected certificate identity and expected OIDC issuer.
  4. If the policy requires them, run attestation verification and evaluate the predicates.
  5. Only after every required check succeeds, publish or apply the deployment manifest.
  6. Store the verified digest, signer identity, issuer and verification logs with the release record.

A CI job can build, push, sign and verify an image in one workflow. Keep the verification step independent enough to catch a wrong tag, wrong registry or unexpected digest rather than merely checking the value the same script just generated.

Failure behavior

Use a non-zero exit status to stop promotion. Do not convert verification errors into warnings for production. For emergency releases, use a separately approved break-glass procedure that records the exception, image digest, approver and expiry; do not silently bypass the check with --check-claims=false.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Enforce signatures at Kubernetes admission

A pipeline gate protects releases that pass through that pipeline. Admission enforcement also covers images submitted by other users, namespaces or automation paths. Sigstore’s Kubernetes Policy Controller can validate signatures and attestations at admission, apply keyless identity constraints and resolve tags so that the admitted image is the image the policy evaluated.

Best Value
Yubico - Security Key C NFC - Basic Compatibility - Multi-Factor authentication (MFA) Security Key and passkey, Connect via USB-C or NFC, FIDO Certified (Pack of 2)
  • The information below is per-pack only
  • POWERFUL SECURITY KEY: The Security Key C NFC is the essential physical passkey for protecting your digital life from phishing attacks. It ensures only you can access your accounts.
  • WORKS WITH 1000+ ACCOUNTS: Compatible with Google, Microsoft, and Apple. A single Security Key C NFC secures 100 of your favorite accounts, including email, password managers, and more.
  • FAST & CONVENIENT LOGIN: Plug in your Security Key C NFC via USB-C and tap it, or tap it against your phone (NFC) to authenticate. No batteries, no internet connection, and no extra fees required.
  • TRUSTED PASSKEY TECHNOLOGY: Uses the latest passkey standards (FIDO2/WebAuthn & FIDO U2F) but does not support One-Time Passwords. For complex needs, check out the YubiKey 5 Series.

Installation prerequisites

  • A Kubernetes cluster and permission to install admission components and create the required resources.
  • Helm 3 for the installation method recommended in the project documentation.
  • A defined policy describing accepted keys or identities, issuers, image repositories and any required attestations.
  • Operational ownership for upgrades, monitoring and incident response.

Install the controller with the official Helm chart and follow the release-specific configuration guidance. The project documentation describes the controller as under active development, so check current compatibility and upgrade notes before making it a critical production control.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Opt namespaces into policy

The overview documents namespace opt-in with the label policy.sigstore.dev/include: "true". A representative command is:

kubectl label namespace production policy.sigstore.dev/include="true"

Apply the label only after a policy is ready and tested. Start with a non-production namespace, observe rejected workloads and confirm that legitimate signed images admit successfully. Then expand coverage deliberately rather than labeling every namespace during the initial installation.

Understand tag resolution

If a manifest uses a tag, the controller can resolve that tag and evaluate the resulting image. Digest-pinned manifests remain easier to audit because the reviewed reference is already immutable. Even with admission enforcement, keep digest pinning in the release process so operators can see exactly which bytes are intended to run.

Registry compatibility and signature storage

Cosign uses the OCI 1.1 referrers specification and, by default, stores signatures in the same repository as the image. Sigstore documentation lists Docker Hub, GitHub Container Registry, AWS ECR, Google Artifact Registry, Azure Container Registry, GitLab, Harbor and Quay among registries tested with the tooling, while noting that registry-specific quirks can occur.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Before production adoption, test the complete path with the registry configuration you actually use:

  • Can the signing identity push the image and its signature referrer?
  • Can the deployment identity read both the image manifest and signature data?
  • Do repository permissions, replication, retention or proxy settings preserve OCI referrers?
  • Does the registry return the same digest from the release environment and the cluster?

Authentication failures, missing referrers and proxy behavior can look like signature failures. Capture the exact registry response and verify access separately before changing trust policy.

Troubleshooting common failures

Symptom Likely cause Corrective action
Digest or claim mismatch The tag moved, the wrong digest was copied, or the signed payload describes another image Resolve the deployed reference again, compare digests, and verify the immutable digest directly
Certificate identity does not match The workflow identity differs from the policy value, often because repository, branch or environment changed Inspect the certificate identity, then either correct the workflow or update the reviewed allowlist
OIDC issuer mismatch The certificate came from a different identity provider or issuer URL Use the exact issuer configured for the approved build system; do not broaden the match casually
No signatures found The signature was not pushed, is in another repository, or the verifier cannot read OCI referrers Check signing job output, repository permissions and registry referrer support
Verification works locally but fails in CI Different credentials, network policy, Cosign version or registry endpoint Pin the tool version, compare authenticated endpoints and grant read access to image and signature objects
Attestation verification succeeds but policy rejects The attestation is valid but its predicate does not meet the organization’s requirements Inspect predicate fields and revise the build metadata or the explicitly approved policy
Admission rejects a known-good image Namespace policy, identity constraint, tag resolution or controller version differs from testing Review controller events and policy resources, test the digest directly, and check current controller guidance

A production checklist

  • Reference: The release manifest uses the digest that will actually run.
  • Identity: The accepted certificate identity is specific to the trusted build workflow.
  • Issuer: The OIDC issuer is explicitly constrained.
  • Claims: Default claim validation remains enabled.
  • Trust model: Keyless or public-key roots are documented, distributed and reviewed.
  • Additional evidence: Required attestations and predicates are defined separately from the signature requirement.
  • Automation: CI stops promotion on verification failure and records the result.
  • Cluster control: Admission policy covers workloads that can bypass the main pipeline.
  • Registry: The production registry preserves signatures and allows the verifier to read them.
  • Operations: Tool, registry and policy-controller versions are checked against current official guidance before upgrades.

How to choose the enforcement level

Control Coverage Strength Operational ownership
Developer or operator runs Cosign manually One image or release at a time Useful for investigation and initial rollout, but easy to skip Individual operator
CI verification gate Releases that use the protected pipeline Consistent promotion control with recorded evidence Build and release team
Kubernetes admission policy All opted-in workloads reaching the cluster Blocks unsigned or unauthorized images even through alternate deployment paths Cluster security and platform team
Pipeline plus admission Both release-time and cluster-time paths Defense in depth; catches drift or bypass attempts Shared release and platform ownership

Most teams should begin with digest pinning and a CI gate, then add admission enforcement once identity policy, registry access and failure handling have been tested. The final control should match the consequences of an unauthorized image entering the cluster, not merely the convenience of the first successful demo.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

container securityCosignDockerKubernetessigstoresoftware supply chain

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Recommended PC Tool
Recommended PC Tool
PC Slower Than It Used to Be?Free scan - under a minute
Outdated Drivers Are Slowing You DownFree scan - exact matches

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.