CVE-2026-85769
libtpms: libtpms: heap out-of-bounds read in TPM2 state unmarshalling via unchecked block_skip_read() blocksize
Severity
ModerateRed Hat Product Security
CVSS 3.1
Review impact separately from score.
Published · September 4, 2026
Updated · September 10, 2026
Description
A flaw was found in libtpms, a library that provides software TPM 2.0 emulation. When restoring TPM 2.0 state (for example during a virtual machine's power-on or state/migration restore), a malformed state blob can supply an oversized skip-block length that is not validated against the remaining size of the input buffer. This can drive an internal size counter negative, which bypasses a subsequent bounds check due to an unsafe signed-to-unsigned conversion, causing the parser to read memory outside the bounds of the heap buffer holding the state data. Successful exploitation can crash the process hosting libtpms (such as swtpm), resulting in a denial of service of the emulated TPM device and the virtual machine that depends on it. No data corruption or information disclosure was confirmed.
Statement
This vulnerability is rated as Moderate because exploitation results in a denial of service (crash or forced TPM failure mode) via a heap out-of-bounds read, with no confirmed information disclosure or code execution path. The flaw affects builds of libtpms compiled with TPM 2.0 support (--with-tpm2, the default). The vulnerable code is in the TPM 2.0 state (de)serializer and is not present in TPM 1.2-only builds. Products that ship libtpms with TPM 2.0 support (used to provide virtual TPM 2.0 devices to guests via swtpm/QEMU) are affected. Practical exposure depends on whether an attacker can supply or tamper with the TPM state blob passed to TPMLIB_SetState(); in swtpm-based VM migration scenarios this may include a trust boundary between cooperating hypervisor hosts. Red Hat product-to-component mapping is required to confirm exact shipped configurations.
CVSS score applicability
The CVSS score(s) listed for this vulnerability do not reflect the associated product's status, and are included for informational purposes to better understand the severity of this vulnerability.
Mitigation
No mitigation is currently available that meets Red Hat Product Security's standards for usability, deployment, applicability, or stability.
CVSS / CWE
CVSS 3.1 · 6.5CVSS:3.1/AV:A/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
CWE-125 · Out-of-bounds Read