Verifying LiteLLM Docker image signatures with cosign

Verifying LiteLLM image signatures with cosign confirms that the image you run came from LiteLLM's published build, and Sigstore Policy Controller can block pods that fail the check. This page covers the signed variants, the setup sequence and the limits to confirm.

On this page

Why verify the LiteLLM Docker image signature before it runs

Before a platform team admits a LiteLLM image into a cluster that holds provider keys and handles prompts, it should confirm that the image was built and published by LiteLLM and not altered on the way. LiteLLM Docker image signature verification does this with cosign: the signature on the image is checked against a public key that you pin from LiteLLM's published material, so a match proves the image digest is the one LiteLLM signed. A tag such as main-stable or a mirrored copy can be replaced without anyone noticing, and a signature check is the step that catches it.

Teams usually need this in three situations: regulated environments where the change record must show where each deployed artifact came from, security reviews that ask how the gateway supply chain is controlled, and air-gapped networks where images are copied through an internal registry or mirror. In each case the verification result becomes evidence, and it should be repeated whenever an image is re-pulled or re-mirrored, not only once at first install. The sections that follow explain which image variants LiteLLM signs, how to run the check, and how to enforce it in Kubernetes.

Before you start, confirm with LiteLLM which public key and commit hash apply to the release line you plan to run, because the verification step depends on pinning both. Also decide who owns the key reference in your configuration, since a key that is updated without review would weaken the control. The LiteLLM Docker image security documentation is the reference for these details.

Verification options and when each fits

This table compares three places to run the signature check: manually before promotion, in CI before images reach your registry, and at admission in Kubernetes. Read each row to see what the option verifies, where it runs, what it stops and who keeps it working. The main takeaway is that the options layer: CI and manual checks catch problems early, while admission enforcement is the only one that stops an unverified image from running in the cluster.

OptionWhat it checks and where it runsWhat it stopsWho maintains it
Manual cosign verificationAn engineer runs cosign verify against the public key pinned to a LiteLLM commit hash, on a workstation or release bench, before the image is promotedA bad image entering your release process when someone follows the check, but nothing if the step is skippedYour platform or security team, using commands they write and store in their runbook
Verification in CIA pipeline job pulls the LiteLLM tag or digest from ghcr.io/berriai, verifies it with cosign, then copies it into a registry you control only on successUnverified images reaching your internal registry and any deployment that pulls from itYour CI platform owners, who keep the pinned key, cosign version and pipeline logic current
Admission enforcement with Sigstore Policy ControllerThe cluster checks each pod's image against a ClusterImagePolicy containing the pinned public key when the pod is createdPods running unverified images, including changes made directly in the cluster after the pipeline ranYour Kubernetes platform team, who installs the controller and maintains the policy and its namespace scope
Policy check on image variantsEach variant you run (for example litellm, litellm-non_root or litellm-spend_logs) must match a signed reference in the policyA variant you deploy that is not covered by the signature rule being quietly accepted or rejectedYour team, which must list every variant in use and update the policy when the image set changes
Key pinning and rotationThe public key is taken from a pinned LiteLLM commit hash, not from whatever is on the default branch at check timeSubstitution of a key or image by a party who controls the upstream referenceYour team, which must confirm the pinned commit and track any key change in LiteLLM release notes
Evidence for reviewersVerification output, policy files and pipeline logs show when and where each image was checkedDisputes about whether a deployed image was checked, since the record is missingYour compliance or security team, which should define retention with the records owner

How a signed LiteLLM image moves from publisher to admission

The flow starts with LiteLLM publishing signed image variants to ghcr.io/berriai. Your CI job pulls the image, or a copy from your own registry, and runs cosign verification against the public key you pinned to a specific commit hash. The Sigstore Policy Controller at Kubernetes admission then accepts or rejects each pod. The trust boundary sits where the image leaves LiteLLM's publish pipeline, so verify before you promote and check that the key you pinned is the one you reviewed.

Signed LiteLLM images pass a pinned-key cosign check before Kubernetes admits them.

Verify the LiteLLM image with cosign before you deploy

This sequence confirms that the LiteLLM image you run matches the image LiteLLM published, from choosing a pinned release through to a digest-based pod spec that a reviewer can trace back to recorded verification output.

  1. Pin the LiteLLM release you plan to run

    The platform owner chooses one LiteLLM release line and writes down the exact version tag. Check the current line on the LiteLLM releases page before choosing, since the most recent entry listed there is v1.105.1, published October 14, 2026. Record the version in your change request or configuration repository so every later step refers to the same release. Done when the version is written down and matches a release that is still on a supported line for your deployment type.

  2. Confirm the cosign version on your workstation or pipeline

    The engineer who runs verification installs cosign and checks its version. The LiteLLM image security documentation states that cosign v1.83.0 or newer is needed to verify the signed image variants, so older binaries in shared tooling images are a common cause of false failures. Confirm the installed version with the cosign version command and record it alongside the verification output. Done when the version is v1.83.0 or newer and the binary runs from the environment where verification will happen.

  3. Fetch the public key at the pinned commit hash

    The engineer downloads the LiteLLM public signing key from the location the image security documentation names, using the commit hash that LiteLLM recommends pinning. Do not take the key from a mirror, a search result or a copy in a chat thread. Store the key file in your configuration repository with the commit hash in its name or header, so the trust anchor is reviewable. Done when the key file exists locally, its source commit is recorded, and a second person can reproduce the download from that commit.

  4. Resolve the digest for each image variant you deploy

    The platform engineer pulls the manifest for each variant in use, such as the standard litellm image, litellm-non_root or litellm-spend_logs, from the ghcr.io/berriai registry, and records its sha256 digest. LiteLLM signs all of these variants, but each variant must be verified on its own. Verify tags only if your process cannot pin digests, because a tag can be moved after signing. Done when you have one digest per variant and the variant list matches the images your deployment manifests reference.

  5. Run cosign verify against each exact digest

    The engineer runs cosign verify against each digest with the pinned public key. Confirm the exact command syntax in the LiteLLM image security documentation before running it, because flags and reference formats must match the documented method. A failed verification stops the release, and the image is not promoted to a staging or production cluster. Done when every deployed variant returns a successful verification result against its own digest.

  6. Record the verification output as evidence

    The engineer saves the full cosign output for each digest, along with the cosign version, the public key file hash, the commit hash, the release version and the date of the run. Store these records with the release ticket or in your evidence repository, where security reviewers and auditors can find them later. Done when each variant has a stored record that links the verified digest to the release it supports.

  7. Reference the verified digests in the pod specs

    The platform engineer updates the Kubernetes deployment, Helm values or Terraform configuration so that each container image references the verified digest instead of a mutable tag. Review the rendered manifests after templating, since a chart can override the image field. Done when a rendered manifest for each workload shows only the verified digest and no tag-only references remain for the LiteLLM images.

  8. Confirm the cluster rejects unverified images

    If your cluster runs the Sigstore Policy Controller, which LiteLLM documents as a way to enforce signature verification in Kubernetes, the platform engineer applies the policy and confirms it rejects pods whose images fail cosign verification. Test with one deliberately unverified image in a non-production namespace and check that admission is denied with a clear reason. Confirm the policy setup steps in the LiteLLM documentation and in the Sigstore Policy Controller documentation before applying them. Done when a test pod with an unverified image is rejected and the verified LiteLLM pods are admitted.

Which LiteLLM image variants are signed

LiteLLM publishes several image variants on ghcr.io/berriai, and each one is a separate artifact you verify. All three named variants are signed, so the choice comes down to your runtime policy and what each image is built for.

The litellm image

This is the standard proxy image and the default starting point for most self-hosted gateways. All variants are signed, according to the LiteLLM image security docs, so this image can be verified with cosign like the others. Before you pick it, confirm with your platform team that the container user it runs as meets your policy. If the policy forbids root, choose the non-root variant instead.

Image security docs

The litellm-non_root image

This variant is built to run without root privileges, which suits clusters that enforce non-root containers through Pod Security Standards or a similar admission rule. It is signed like the other variants. Confirm the user ID it runs as and test that any mounted configuration files and writable paths work for that user before you roll it out, because a permissions mismatch shows up only at runtime.

The litellm-spend_logs image

This variant targets deployments that use the spend log workflow described in the LiteLLM docs. It is also signed, so verification follows the same steps. Do not assume it is a drop-in replacement for the other two. Ask your LiteLLM contact or check the image documentation for what differs in configuration and runtime behavior, then test it in a non-production cluster.

Confirm the variant before verifying

Signatures attach to a specific image, so verify the exact reference your cluster will pull, whether that is a tag or a digest. Choose the variant from your runtime security policy first, then verify that same reference. Verifying one variant and deploying another leaves the deployed image unchecked. Record the chosen variant in your deployment manifests so the policy controller and your reviewers see the same reference.

How Sigstore Policy Controller enforces the signature in Kubernetes

LiteLLM documents enforcing signature verification in Kubernetes with the Sigstore Policy Controller, which rejects pods whose images fail cosign verification. A one-time check in CI tells you the image was valid when it was built. Admission enforcement checks the image every time a pod is created, including pods the scheduler recreates after a node failure, a rollback or an autoscaling event. The trade-off is that a verification check in CI is cheap and easy to audit, but it does not stop someone with cluster access from applying a manifest that points at an unverified image. Admission enforcement closes that gap, at the cost of a webhook that must be running and reachable for pods to start.

Plan for what happens during a rollout. An image that was re-tagged, rebuilt from a different source or pushed without a signature will fail verification, and the pod will not be admitted. Check which image reference your Helm chart or manifest uses, whether it pins a digest or a mutable tag, and whether the signed variant (for example, litellm-non_root) is the one you actually deploy. Confirm in the LiteLLM image security docs which variants are signed, and confirm the public key reference and the verification policy resource against the Sigstore Policy Controller documentation, since field names and selection behavior can change between releases. Also confirm which namespaces the policy applies to, so the gateway namespace is covered and system namespaces are not blocked by accident.

Before you rely on this control, test it in a non-production cluster. Apply the policy, then deploy a deliberately unsigned image, or a correctly signed image with a different key, and confirm the admission request is denied with a clear reason in the events. Then deploy the real LiteLLM image and confirm it is admitted. Run the same test after a policy change and after a Policy Controller upgrade. Record the outcome as evidence for your change process, and decide in advance who can approve a rollout that is blocked, and what the rollback path is when the webhook itself is unavailable.

Risks that remain after a signature check passes

A valid signature proves who built the image and that it was not altered after signing. It does not make the image safe, current or the only control you need. The cards below cover the gaps that remain on a cluster where verification is already enforced.

Known vulnerabilities in a signed image

A signed image can still ship with vulnerable operating system packages or Python dependencies, because the signature only attests to the build. Scan each image you deploy and track findings against the LiteLLM release line you run. The scanning workflow is covered in the patching topic on supported versions and advisories, so treat a passing signature as the start of your review, not the end.

Image security docs

Tags that move after verification

A tag such as a version label can be repointed to a different image digest after you verified it, so the policy checks one image and the cluster runs another. Deploy by digest and confirm that the digest your verification step checked is the one in the running pod spec. Ask your platform team who can push to your registry namespace and whether tag mutability is blocked there.

Substitution of the public key

Cosign verification is only as trustworthy as the public key you verify against, so a key fetched from an unpinned location can be swapped by anyone who controls that location. Take the key from the pinned commit hash that LiteLLM recommends, record its fingerprint in your change records, and store the key in version control that requires review. Any change to the key should go through the same approval as a change to the policy.

Bypass by cluster admins and exemptions

Anyone with rights to edit the admission policy, remove a namespace label or create an exemption can allow unsigned images into the cluster. Limit those rights to a small group, alert on policy and namespace label changes, and review any exemption list on a fixed schedule. Test the bypass path during your rollout by attempting to deploy an unsigned image and confirming the admission controller rejects it.

LITELLM_MASTER_KEY in Kubernetes secrets

Signature verification says nothing about how the gateway's master key is stored, and the key grants full administrative access to the proxy. Kubernetes Secrets are stored unencrypted in etcd by default, so enable encryption at rest, restrict list and watch access with least-privilege RBAC, or load the key from an external store with the Secrets Store CSI Driver. The key must start with sk-, and it should stay out of application configuration.

Secrets good practices

Keeping signature checks working across LiteLLM upgrades

Every LiteLLM upgrade produces new image digests, so the pinned public key, the cosign verification step and the Sigstore Policy Controller policy all need to be checked as part of each release, not set once and forgotten. A verification that passed for the image you deployed last quarter says nothing about the image you pull next week. Treat the three artifacts as a unit in every change: confirm the digest being promoted, run cosign verify against it with the public key pinned to the commit hash your team reviewed, and confirm the admission policy still matches the image names and signing identity you expect. If the upstream signing key or pinning guidance changes in a release note, that change belongs in the ticket as a separate review item.

Upgrade cadence depends on which minor line you run. LiteLLM maintains support for the four most recent stable minor versions, so the line you are on will fall out of support on a predictable schedule, and planning around that window matters more than chasing each patch. The GitHub releases page listed v1.105.1, published October 14, 2026, at the time of writing, so confirm the current list before scheduling. When a rollout includes a failed verification, pause the rollout and keep the policy in enforce mode. Do not switch the Policy Controller to a permissive setting or remove the namespace label to get pods running. Check whether the failure comes from a wrong digest, a variant that is not in your policy, a key mismatch or a signature that was not produced by the release you expected, and fix the cause before re-admitting the image.

In the change ticket, record the image name and variant, the full digest, the cosign version used, the public key reference and commit hash, the verification output, the Policy Controller policy version, and the approver for any policy edit. For rollback, keep the previously verified digest in the ticket so the Deployment can be pointed back to a known-good image that still passes the same policy. If a pod is rejected by admission, the rollback path is to restore the prior digest in the manifest and confirm the replacement pod is admitted, not to exempt the workload. Ask your platform team to confirm how rejected admission events reach your alerting before the first production rollout.

Limits to confirm in your environment

Signature verification only proves what the signing key and the registry path let it prove. Each card below is a condition in your own environment that decides whether a cosign check at deploy time actually protects the image you run.

Signed variants and versions

LiteLLM signs all image variants on ghcr.io/berriai, including litellm, litellm-non_root and litellm-spend_logs, with cosign from v1.83.0. Confirm that the exact variant and tag you plan to deploy falls within that signed set. An image published before signing was introduced, or a variant you build yourself, will not verify, and your policy must treat that as a failure rather than a warning.

LiteLLM image security docs

Mirror and registry signature retention

If you pull through a private registry, proxy cache or mirror, confirm that it copies the cosign signature artifacts alongside the image and keeps the digest unchanged. Some mirroring workflows re-tag or re-push images, which can break verification or, worse, leave a signature attached to content you did not intend to trust. Test the path with a known-good image before you enforce it cluster-wide.

Kubernetes and Policy Controller versions

Check your cluster version against the Kubernetes releases page before you choose a Sigstore Policy Controller release. The project currently maintains the three most recent minor releases, with 1.37, 1.36 and 1.35 listed in the supplied support dates, so an older cluster may fall outside support. Confirm the Policy Controller version you install is compatible with your cluster version in its own documentation.

Kubernetes releases

Air-gapped key and transparency access

Verification with a pinned public key needs the key file available inside the cluster, but keyless or transparency-log checks may need outbound access to Sigstore services. Confirm whether your air-gapped clusters can reach those endpoints. If they cannot, bundle the pinned public key and any required verification material into your internal artifact store, and document how that material is refreshed and approved.

Coverage of sidecars and jobs

A policy that admits only some workloads leaves gaps. LiteLLM is often deployed alongside database migration jobs, Redis, monitoring agents and init containers. Confirm that your admission policy applies to every namespace and workload type that runs LiteLLM images, including Jobs and CronJobs, and that unsigned third-party images used beside the gateway are either signed, excluded deliberately or approved in writing.

Key custody and rotation

The control is only as strong as the key that verifies it. Confirm who holds the pinned public key reference, how changes to it are reviewed, and how a key change is rolled out to every cluster. Record the commit hash you pinned, so an auditor can see which trust anchor was in force at each deployment date, and schedule a periodic check that the policy still matches the upstream guidance.

Questions teams ask before verifying LiteLLM image signatures

How much effort does verifying LiteLLM image signatures take?

Verifying a single image with cosign is a small task, but the admission setup around it is where the effort sits. The main drivers are the number of clusters, how many registries or mirrors your images pass through, whether the cluster can reach the public registry at all, and whether you already run an admission or policy tool that the Sigstore Policy Controller must fit alongside. Each additional cluster adds a policy to test and keep in step with the image variants you run. Ask any partner to break its quote down by cluster count, registry topology and whether air-gapped mirroring is in scope, since each of those changes the work more than the verification command does.

How long does signature enforcement take to roll out, and who must be involved?

Duration depends less on the tooling than on approvals. Your platform team needs to pin the public key at the commit hash LiteLLM recommends, decide which image variants (such as litellm, litellm-non_root or litellm-spend_logs) you run, and test a policy in non-production before enforcement. Security needs to sign off on the trust decision and the policy scope, and your change process decides when the policy moves to production. Teams with a standing change window and a test cluster move faster. Ask for a timeline that names each approval gate so you can see which steps depend on your security team rather than on implementation work.

What does the work need from our team?

Plan for four inputs. First, cluster administrator access, because the policy controller and its admission configuration are cluster-scoped. Second, a registry or mirror that your nodes can pull from, along with a way to check signatures against it. Third, a change process that accepts a new admission control, including a rollback plan if a legitimate deployment is blocked. Fourth, a test cluster that matches production closely enough to catch policy mismatches before they reach real workloads. Missing any one of these usually stalls the work at the point where a policy is first enforced, so confirm access and the change window before the scope is agreed.

Can our team verify LiteLLM signatures without outside help?

Yes, for a single cluster with a clear runbook. The LiteLLM image security documentation describes the verification steps and the Kubernetes enforcement pattern, so an engineer comfortable with cosign and Kubernetes admission can complete a pilot alone. Outside help becomes worthwhile when you run several clusters or regions, when registries are mirrored or air-gapped, when existing policy tooling must coexist with the Sigstore Policy Controller, or when the enforcement change must be documented for a compliance assessment. In those cases, the value is usually in the design decisions and the test evidence, not in the commands.

Does a passing signature check satisfy a security review?

No. A successful cosign verification and an enforced admission policy produce evidence that an image matches what LiteLLM published and that unsigned or altered images are rejected. Security reviews also look at configuration, access control, secrets handling, network exposure and how you patch, none of which a signature check covers. Treat the signature results, policy definitions and test records as inputs to the review. Independent auditors and certification bodies make the assessment decision, and DeployOpen prepares the systems and evidence for that assessment rather than issuing it.

What happens when a signature check fails?

With enforcement active, the Sigstore Policy Controller rejects pods whose images fail cosign verification, so the workload does not start. That protects the cluster, but it can also block a legitimate deployment, for example after a mirror serves a stale copy, a tag is rebuilt, or the pinned key is out of date. Your runbook should state who investigates, how the image digest is compared with the published source, and who can approve an exception with a time limit. Do not disable the policy to clear a backlog. Record each failure so the cause, whether a configuration error or a real integrity problem, is visible to the security team.

Which parts of the setup recur after go-live?

Most of the cost is one-time: designing the policy, testing it and documenting the approved image variants. Recurring work includes updating the pinned public key or commit reference when LiteLLM changes it, adding policy coverage when you adopt a new image variant or upgrade to a release that signs images under a different scheme, and reviewing admission failures. Each LiteLLM upgrade also needs a verification pass before rollout. Ask any quote to separate the initial build from a support retainer, since ongoing checks follow the upgrade schedule rather than a fixed calendar.

How DeployOpen scopes and delivers LiteLLM image verification

DeployOpen treats image verification as a short, written piece of work inside your LiteLLM deployment: confirming which image variants you run, checking signatures against the public key you pin, and enforcing that check where your pods start. The result is a verification procedure your platform team can run on every release and an admission policy your security team can review.

How we scope

  • Inventory the image variants you pull, such as litellm, litellm-non_root and litellm-spend_logs, and the registry paths your clusters use.
  • Confirm the cosign version your verification pipeline runs and the pinned commit hash of the public key you will trust.
  • Agree in writing whether the scope covers manual verification, pipeline gates, Sigstore Policy Controller enforcement or all three.

How we build

  • Write the cosign verification commands and pipeline step that fail a deployment when a signature does not match the pinned key.
  • Configure the Sigstore Policy Controller policy so pods with unverified LiteLLM images are rejected in the namespaces you name.
  • Test the policy with a signed image, an unsigned image and an image signed with a different key, and record each result.

How we hand over

  • Deliver the verification runbook, policy manifests and pipeline configuration as files stored in your own source control.
  • Document the procedure for rotating the pinned key or moving to a new LiteLLM release line, including who approves the change.
  • Walk your platform and security teams through the test evidence so they can repeat the checks without DeployOpen involved.

How we support

  • Engagements are fixed-scope, with scope, deliverables and timelines agreed in writing before work starts.
  • Ongoing support for upgrades to new LiteLLM releases and policy changes is available as a retainer, quoted from the written scope.
  • Confirm with your team which cosign and Policy Controller versions your clusters support, since verification results depend on them.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.