CVE-2026-46096

tpm2-sessions: Fix missing tpm_buf_destroy() in tpm2_read_public()

State
Published
Severity
Not scored
Published
May 27, 2026
Updated
Jun 14, 2026
Reserved
May 13, 2026

Read the record on cve.org

Description

In the Linux kernel, the following vulnerability has been resolved:

tpm2-sessions: Fix missing tpm_buf_destroy() in tpm2_read_public()

tpm2_read_public() calls tpm_buf_init() but fails to call tpm_buf_destroy() on two exit paths, leaking a page allocation:

1. When name_size() returns an error (unrecognized hash algorithm), the function returns directly without destroying the buffer.

2. On the success path, the buffer is never destroyed before returning.

All other error paths in the function correctly call tpm_buf_destroy() before returning.

Fix both by adding the missing tpm_buf_destroy() calls.

Scores

The record has no CVSS score.

Weaknesses

The record names no weakness.

Affected Products

ProductVersions
LinuxLinux
  • 20eda7c74b69fe9e1caf9b930a5c016bf8d755fa to before f8775d9d9062da662cc861f9ff7722a65896d4cdAffected
  • bda1cbf73c6e241267c286427f2ed52b5735d872 to before 2f434be87e256fd58254f60ddf5d7d58e775ca0bAffected
  • bda1cbf73c6e241267c286427f2ed52b5735d872 to before f0f75a3d98b7959a8677b6363e23190f3018636bAffected
  • a3b7eb67225c486a2da357c5db3e386f4e64bcdeAffected
  • 6.18.3 to before 6.18.27Affected
  • 6.12.64 to before 6.13Affected
LinuxLinux
  • 6.19Affected
  • before 6.19Not affected
  • 6.18.27 through 6.18.*Not affected
  • 7.0.4 through 7.0.*Not affected
  • 7.1 and laterNot affected

References

Every record here comes from the CVE Program’s CVE List. © 1999–2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.