kyverno fetches notary attestations (referrers) and extracts statement predicates by reading Layer.Uncompressed() into a bytes.Buffer without an uncompressed-size limit. the code checks Layer.Size() and descriptor sizes (compressed), but does not enforce a cap on the uncompressed bytes read from Uncompressed() .
in an admission-controller deployment, an attacker who can supply registry artifacts for an image’s referrers can cause kyverno to allocate excessive memory while fetching attestations, potentially triggering an oom kill and denial of service.
high (availability-only impact; admission controller memory exhaustion)
cvss: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H (7.5) cwe: CWE-409 (Improper Handling of Highly Compressed Data (Data Amplification))
affected versions: >= 1.11.0, <= 1.16.2 (estimated; code confirmed at pinned commit)
affected commits: main at f63dda3 (as-of 2026-02-11)
patched versions: none known
preconditions / attacker model
kyverno is deployed as an admission controller and image verification policies fetch notary attestations for admitted workloads
attacker can cause the cluster to evaluate an image reference that resolves to attacker-controlled registry artifacts (referrers / attestation predicate layers)
repo:
callsite: pkg/notary/notary.go:337 ( extractStatement )
callsite permalink: kyverno/pkg/notary/notary.go Line 337 in f63dda3 ioPredicate , err := layer . Uncompressed ()
kyverno/pkg/notary/notary.go
extractStatement performs size checks on compressed blobs ( predicateDesc.Size , layer.Size() ), then calls layer.Uncompressed() and reads the full stream into a bytes.Buffer via ReadFrom without any upper bound or reader close.
an attacker-controlled predicate layer can decompress far beyond maxPayloadSize (10,000,000 bytes) and force kyverno to allocate memory proportional to the uncompressed size.
attached poc.zip starts a local oci registry, pushes a gzip layer that decompresses beyond maxPayloadSize as a referrer artifact, then triggers FetchAttestations at the pinned commit:
vulnerable: uncompressed bytes exceed the limit and are fully buffered (see canonical.log in the archive)
fixed control: uncompressed bytes are rejected after applying fix.patch (see control.log in the archive)
canonical output contains:
control output contains:
enforce an upper bound on uncompressed reads (e.g., io.LimitReader(..., maxPayloadSize+1) and error if exceeded)
close uncompressed readers ( defer Close() )
poc.zip PR_DESCRIPTION.md
The full story
This article is one source in a clustered incident — the cluster page carries the summary, timeline and every other outlet covering it.
