# CVE-2024-35940: pstore/zone: Add a null pointer check to the psz_kmsg_read

- Severity: Medium 5.5 (CVSS:3.1, scored by CISA-ADP) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.21%, higher than 12% of CVEs (2026-12-01)
- Published: 2024-05-19T10:10:45.582Z
- Modified: 2026-10-15T01:17:54.413Z
- Weaknesses: CWE-476
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: Linux

## Description

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

pstore/zone: Add a null pointer check to the psz_kmsg_read

kasprintf() returns a pointer to dynamically allocated memory
which can be NULL upon failure. Ensure the allocation was successful
by checking the pointer validity.

(As written by CVE List.)

## Affected

- Linux Linux: from d26c3321fe18dc74517dc1f518d584aa33b0a851 before 98e2b97acb875d65bdfc75fc408e67975cef3041; from d26c3321fe18dc74517dc1f518d584aa33b0a851 before 0ff96ec22a84d80a18d7ae8ca7eb111c34ee33bb; from d26c3321fe18dc74517dc1f518d584aa33b0a851 before 635594cca59f9d7a8e96187600c34facb8bc0682; from d26c3321fe18dc74517dc1f518d584aa33b0a851 before ec7256887d072f98c42cdbef4dcc80ddf84c7a70; from d26c3321fe18dc74517dc1f518d584aa33b0a851 before 6f9f2e498eae7897ba5d3e33908917f68ff4abcc; from d26c3321fe18dc74517dc1f518d584aa33b0a851 before 98bc7e26e14fbb26a6abf97603d59532475e97f8; 5.8 (not affected: before 5.8; from 5.10.215 up to 5.10.*; from 5.15.155 up to 5.15.*; from 6.1.86 up to 6.1.*; from 6.6.27 up to 6.6.*; from 6.8.6 up to 6.8.*; from 6.9 up to *)
- linux linux_kernel: before 5.10.215; from 5.11 before 5.15.155; from 5.16 before 6.1.86; from 6.2 before 6.6.27; from 6.7 before 6.8.6
- debian debian_linux: 10.0

## References

- <https://git.kernel.org/stable/c/98e2b97acb875d65bdfc75fc408e67975cef3041> (patch)
- <https://git.kernel.org/stable/c/0ff96ec22a84d80a18d7ae8ca7eb111c34ee33bb> (patch)
- <https://git.kernel.org/stable/c/635594cca59f9d7a8e96187600c34facb8bc0682> (patch)
- <https://git.kernel.org/stable/c/ec7256887d072f98c42cdbef4dcc80ddf84c7a70> (patch)
- <https://git.kernel.org/stable/c/6f9f2e498eae7897ba5d3e33908917f68ff4abcc> (patch)
- <https://git.kernel.org/stable/c/98bc7e26e14fbb26a6abf97603d59532475e97f8> (patch)
- <https://lists.debian.org/debian-lts-announce/2024/06/msg00017.html> (mailing-list, third-party-advisory)
- <https://cert-portal.siemens.com/productcert/html/ssa-265688.html>

## Sources

- CVE List: [CVE-2024-35940](https://www.cve.org/CVERecord?id=CVE-2024-35940), CVE Terms of Use, modified 2026-10-15
- NVD: [CVE-2024-35940](https://nvd.nist.gov/vuln/detail/CVE-2024-35940), Public domain, modified 2026-10-15

---

Page: https://cve.day/CVE-2024-35940 · Whole record: https://cve.day/CVE-2024-35940.json · Rebuilt by cve.day 2026-11-25T22:58:40.614Z
