TecLeads TecLeads Blog
2026-11-14 · 7 min read

Your SBOM Is Not Evidence Until You Sign the Build

Developer typing on a backlit keyboard in a dark room
devsecopssoftware-supply-chainsbomcontainer-securitypolicy-as-code

The image passed every scanner in CI. Two days later, nobody could prove that the image running in production was the one CI had scanned.

The tag matched. The digest was missing from the deployment record. The software bill of materials sat in a build artifact store, detached from the container it supposedly described. Anyone with registry write access could have replaced the tag. We had plenty of security data and very little evidence.

That is the trap with software supply chain security. Teams generate an SBOM, add a green check to the pipeline, and call the job done. An unsigned SBOM attached to a mutable tag is an inventory claim. It is not trustworthy evidence.

A defensible chain needs three linked facts: what is inside the artifact, who produced it, and how it was produced. SBOMs, signing, and provenance answer those questions, but only when they are bound to the same immutable digest and checked before deployment.

Start with the digest, not the tag

Container tags are convenient pointers. They are also mutable. If your deployment refers to payments:1.8.4, the registry can return different bytes tomorrow without changing the tag.

Resolve and record the digest after the image is pushed:

IMAGE="registry.example.com/platform/payments:1.8.4"
DIGEST=$(crane digest "$IMAGE")
ARTIFACT="registry.example.com/platform/payments@$DIGEST"

echo "$ARTIFACT"

Every later operation should use ARTIFACT, including scanning, SBOM generation, signing, attestation, promotion, and deployment. This removes a surprising number of arguments during incident response. You are discussing one exact object, not whatever a tag happens to mean at that moment.

Digest pinning does not prove the object is safe. It proves everybody is looking at the same object. That is the foundation the rest of the controls need.

An SBOM should describe the artifact you actually ship

Generate the SBOM from the finished image, not only from the source checkout. Source analysis misses packages introduced by base images, package managers, copied binaries, and creative Dockerfiles.

Syft can produce CycloneDX JSON directly from the registry image:

syft "$ARTIFACT" -o cyclonedx-json > sbom.cdx.json

Grype can then scan that SBOM:

grype sbom:sbom.cdx.json --fail-on high

Keep the raw SBOM even if the vulnerability gate passes. Scanner findings change as advisory databases change. The inventory remains useful for later queries, such as finding every deployed image containing a newly disclosed library.

There is a catch. A JSON file named after an image does not establish a relationship with that image. Uploading both files to the same CI run is better than nothing, but it still relies on storage permissions, naming conventions, and human interpretation.

Attach the SBOM as an attestation to the image digest:

cosign attest \
 --yes \
 --type cyclonedx \
 --predicate sbom.cdx.json \
 "$ARTIFACT"

Now the statement identifies the subject by digest. If somebody rebuilds the image, even from the same commit and Dockerfile, it gets a different digest and needs a new attestation.

Signing tells you who made the claim

A signature does not make software trustworthy. It tells you which identity vouched for a specific digest. Whether you trust that identity is a policy decision.

For CI systems that support OIDC, keyless signing with Cosign is usually preferable to distributing a long lived private key:

cosign sign --yes "$ARTIFACT"

The CI workload obtains a short lived identity token, and the resulting certificate carries information about the signer. Verification must constrain that identity. Merely checking that some valid signature exists is too loose.

For example, a verifier can require a particular GitHub Actions workflow and issuer:

cosign verify "$ARTIFACT" \
 --certificate-identity \
 "https://github.com/example-org/payments/.github/workflows/release.yml@refs/heads/main" \
 --certificate-oidc-issuer \
 "https://token.actions.githubusercontent.com"

Use exact identities where possible. Broad regular expressions turn a useful control into theatre. Also protect the workflow file, branch, and registry credentials. Signing a compromised build faithfully proves that the compromised build signed the artifact.

That is why signing belongs beside SAST, software composition analysis, secret detection, infrastructure policy, and container hardening. These controls answer different questions. Treating one as a substitute for the others leaves predictable gaps.

Provenance explains where the bytes came from

An SBOM says what was found. A signature says who endorsed the digest. Provenance describes the build path: source repository, revision, builder identity, workflow, parameters, and resulting artifact.

Good provenance is generated by the build platform, not handwritten in a shell script after the build. A process that can freely edit its own evidence can also lie about it. Prefer CI features and build systems that emit signed attestations from a controlled builder identity.

When reviewing provenance, ask practical questions. Did the build use the expected repository and protected branch? Was the artifact produced by the release workflow or by somebody's laptop? Were unreviewed build arguments accepted? Does the recorded subject digest match the deployed image?

The goal is not to collect a perfect genealogy of every byte. The goal is to make unauthorised build paths distinguishable from authorised ones, then reject the former.

Verification belongs at admission time

Pipeline checks are necessary, but they do not control every route into a cluster. Administrators can run kubectl. Deployment credentials leak. Old automation survives long after its owner leaves. A second registry may appear during an outage and quietly become permanent.

Admission control is where supply chain claims become enforcement. Kyverno, Sigstore Policy Controller, and Gatekeeper can apply policy as code before a workload is admitted. A basic Kyverno signature policy looks like this:

apiVersion: kyverno.io/v1
kind: ClusterPolicy
metadata:
 name: require-signed-platform-images
spec:
 validationFailureAction: Enforce
 webhookConfiguration:
 failurePolicy: Fail
 rules:
 - name: verify-platform-images
 match:
 any:
 - resources:
 kinds:
 - Pod
 verifyImages:
 - imageReferences:
 - "registry.example.com/platform/*"
 required: true
 mutateDigest: true
 verifyDigest: true
 attestors:
 - entries:
 - keyless:
 subject: "https://github.com/example-org/*"
 issuer: "https://token.actions.githubusercontent.com"

Treat this as a starting shape, not a finished policy. Tighten the subject to approved release workflows, require the attestations your risk model needs, and test failure behaviour before enabling enforcement. If the verifier cannot reach required transparency or registry services, decide whether the cluster fails closed. For production namespaces, failing open usually means the policy is decorative exactly when pressure is highest.

Roll out in audit mode first to find unmanaged images, then set a deadline and enforce. Permanent audit mode is just expensive logging.

Compliance needs evidence you can replay

Auditors and incident responders eventually ask the same awkward question: what exactly was deployed, and what controls approved it?

Keep the image digest, signature verification result, SBOM, provenance statement, policy decision, and deployment identity. Retention should match your operational and compliance obligations. More importantly, make the evidence queryable. A bucket full of opaque JSON objects is technically retained and operationally useless.

This is also where container security and compliance stop being separate projects. The same signed evidence can support admission decisions, vulnerability response, release approval, and later investigation. One chain, several consumers.

If you only do one thing this week

Pick one production service and make its release pipeline carry the image digest from build through deployment. Generate an SBOM from that digest, sign it, attach provenance, and verify the signer at admission.

Do not start by generating SBOMs for every repository. Start by completing one trustworthy chain. Once it survives a rebuild, a rollback, and a failed verification, turn it into the standard path for every commit, build, and deploy.


If this is on your plate, TecLeads does exactly this as part of our DevSecOps work. If you'd like a second pair of eyes on your setup, book a 30-minute call or explore what we do.

📍 Tech Pulse · today's quick question 🟡 Level: Intermediate Cybersecurity

What is a zero-day?

Pick an answer to see how other engineers voted.

Want a hand with this?

TecLeads helps engineering teams ship faster and more securely.

Book a 30-minute call

← All posts