5.5medium
mm/page_alloc: don't call pfn_to_page() on possibly non-existent PFN in split_large_buddy()
- Severity
- 5.5medium CVSS:3.1 by CISA-ADP
- Exploit likelihood
- 0.18% (higher than 7% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- Linux
Description
In the Linux kernel, the following vulnerability has been resolved: mm/page_alloc: don't call pfn_to_page() on possibly non-existent PFN in split_large_buddy() In split_large_buddy(), we might call pfn_to_page() on a PFN that might not exist. In corner cases, such as when freeing the highest pageblock in the last memory section, this could result with CONFIG_SPARSEMEM && !CONFIG_SPARSEMEM_EXTREME in __pfn_to_section() returning NULL and and __section_mem_map_addr() dereferencing that NULL pointer. Let's fix it, and avoid doing a pfn_to_page() call for the first iteration, where we already have the page. So far this was found by code inspection, but let's just CC stable as the fix is easy.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| Linux Linux | from fd919a85cd55be5d00a6a7372071f44c8eafb825 before 4234ca9884bcae9e48ed38652d91696ad5cd591d, from fd919a85cd55be5d00a6a7372071f44c8eafb825 before faeec8e23c10bd30e8aa759a2eb3018dae00f924, 6.10 Not affected: before 6.10, from 6.12.7 up to 6.12.*, from 6.13 up to * | CVE List |
| linux linux_kernel | from 6.10 before 6.12.7, 6.13 | NVD |
All scores
| CISA-ADP | 5.5medium CVSS:3.1 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H |
| NVD | 5.5medium CVSS:3.1 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H |
Classification
SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial.
What each source says
CVE List
In the Linux kernel, the following vulnerability has been resolved: mm/page_alloc: don't call pfn_to_page() on possibly non-existent PFN in split_large_buddy() In split_large_buddy(), we might call pfn_to_page() on a PFN that might not exist. In corner cases, such as when freeing the highest pageblock in the last memory section, this could result with CONFIG_SPARSEMEM && !CONFIG_SPARSEMEM_EXTREME in __pfn_to_section() returning NULL and and __section_mem_map_addr() dereferencing that NULL pointer. Let's fix it, and avoid doing a pfn_to_page() call for the first iteration, where we already have the page. So far this was found by code inspection, but let's just CC stable as the fix is easy.
NVD (es)
En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: mm/page_alloc: no llamar a pfn_to_page() en PFN posiblemente inexistente en split_large_buddy() En split_large_buddy(), podríamos llamar a pfn_to_page() en un PFN que podría no existir. En casos especiales, como al liberar el bloque de página más alto en la última sección de memoria, esto podría resultar en que CONFIG_SPARSEMEM && !CONFIG_SPARSEMEM_EXTREME en __pfn_to_section() devuelva NULL y __section_mem_map_addr() desreferenciando ese puntero NULL. Vamos a solucionarlo y evitar hacer una llamada a pfn_to_page() para la primera iteración, donde ya tenemos la página. Hasta ahora esto se encontró mediante inspección de código, pero simplemente controlemos CC estable ya que la solución es fácil.
References
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2024-57881 changed 2026-05-11 | CVE Terms of Use |
| NVD | CVE-2024-57881 changed 2026-06-17 | Public domain |