What’s Vulnerable › Vulnerabilities
CVE-2024-36967: KEYS: trusted: Fix memory leak in tpm2_key_encode()
- Severity: medium (CVSS 5.5 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 0.2% probability of exploitation in the next 30 days
- Public exploit or detection template: none known
- Published: 2024-06-08 · updated 2026-06-17
- Weakness: CWE-401
Description
In the Linux kernel, the following vulnerability has been resolved: KEYS: trusted: Fix memory leak in tpm2_key_encode() 'scratch' is never freed. Fix this by calling kfree() in the success, and in the error case.
Affected products
- Linux kernel: from 5.13 before 5.15.160; from 5.16 before 6.1.92; from 6.2 before 6.6.32; from 6.7 before 6.8.11; from 6.9 before 6.9.2 — fixed in 5.15.160, 6.1.92, 6.6.32, 6.8.11, 6.9.2
How to fix
Upgrade to a fixed version: Linux kernel 5.15.160, 6.1.92, 6.6.32, 6.8.11. Check the vendor advisory for mitigations.
References
- https://git.kernel.org/stable/c/189c768932d435045b1fae12bf63e53866f06a28
- https://git.kernel.org/stable/c/1e6914fa8e7798bcf3ce4a5b96ea4ac1d5571cdf
- https://git.kernel.org/stable/c/5d91238b590bd883c86ba7707c5c9096469c08b7
- https://git.kernel.org/stable/c/cf26a92f560eed5d6ddc3d441cc645950cbabc56
- https://git.kernel.org/stable/c/e62835264d0352be6086975f18fdfed2b5520b13
- https://git.kernel.org/stable/c/ffcaa2172cc1a85ddb8b783de96d38ca8855e248
- https://git.kernel.org/stable/c/189c768932d435045b1fae12bf63e53866f06a28
- https://git.kernel.org/stable/c/1e6914fa8e7798bcf3ce4a5b96ea4ac1d5571cdf
- https://git.kernel.org/stable/c/5d91238b590bd883c86ba7707c5c9096469c08b7
- https://git.kernel.org/stable/c/cf26a92f560eed5d6ddc3d441cc645950cbabc56
- https://git.kernel.org/stable/c/e62835264d0352be6086975f18fdfed2b5520b13
- https://git.kernel.org/stable/c/ffcaa2172cc1a85ddb8b783de96d38ca8855e248
Get alerted when CVE-2024-36967 or the next vulnerability affects your stack