CVE-2024-31076

In the Linux kernel, the following vulnerability has been resolved: genirq/cpuhotplug, x86/vector: Prevent vector leak during CPU offline The absence of IRQD_MOVE_PCNTXT prevents immediate effectiveness of interrupt affinity reconfiguration via procfs. Instead, the change is deferred until the next instance of the interrupt being triggered on the original CPU. When the interrupt next triggers on the original CPU, the new affinity is enforced within __irq_move_irq(). A vector is allocated from the new CPU, but the old vector on the original CPU remains and is not immediately reclaimed. Instead, apicd->move_in_progress is flagged, and the reclaiming process is delayed until the next trigger of the interrupt on the new CPU. Upon the subsequent triggering of the interrupt on the new CPU, irq_complete_move() adds a task to the old CPU's vector_cleanup list if it remains online. Subsequently, the timer on the old CPU iterates over its vector_cleanup list, reclaiming old vectors. However, a rare scenario arises if the old CPU is outgoing before the interrupt triggers again on the new CPU. In that case irq_force_complete_move() is not invoked on the outgoing CPU to reclaim the old apicd->prev_vector because the interrupt isn't currently affine to the outgoing CPU, and irq_needs_fixup() returns false. Even though __vector_schedule_cleanup() is later called on the new CPU, it doesn't reclaim apicd->prev_vector; instead, it simply resets both apicd->move_in_progress and apicd->prev_vector to 0. As a result, the vector remains unreclaimed in vector_matrix, leading to a CPU vector leak. To address this issue, move the invocation of irq_force_complete_move() before the irq_needs_fixup() call to reclaim apicd->prev_vector, if the interrupt is currently or used to be affine to the outgoing CPU. Additionally, reclaim the vector in __vector_schedule_cleanup() as well, following a warning message, although theoretically it should never see apicd->move_in_progress with apicd->prev_cpu pointing to an offline CPU.
Configurations

Configuration 1 (hide)

OR cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*

History

04 Nov 2025, 18:16

Type Values Removed Values Added
References
  • () https://lists.debian.org/debian-lts-announce/2024/06/msg00020.html -

29 Sep 2025, 18:25

Type Values Removed Values Added
CVSS v2 : unknown
v3 : unknown
v2 : unknown
v3 : 5.5
First Time Linux linux Kernel
Linux
CWE NVD-CWE-noinfo
CPE cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
References () https://git.kernel.org/stable/c/59f86a2908380d09cdc726461c0fbb8d8579c99f - () https://git.kernel.org/stable/c/59f86a2908380d09cdc726461c0fbb8d8579c99f - Patch
References () https://git.kernel.org/stable/c/6752dfcfff3ac3e16625ebd3f0ad9630900e7e76 - () https://git.kernel.org/stable/c/6752dfcfff3ac3e16625ebd3f0ad9630900e7e76 - Patch
References () https://git.kernel.org/stable/c/9eeda3e0071a329af1eba15f4e57dc39576bb420 - () https://git.kernel.org/stable/c/9eeda3e0071a329af1eba15f4e57dc39576bb420 - Patch
References () https://git.kernel.org/stable/c/a40209d355afe4ed6d533507838c9e5cd70a76d8 - () https://git.kernel.org/stable/c/a40209d355afe4ed6d533507838c9e5cd70a76d8 - Patch
References () https://git.kernel.org/stable/c/a6c11c0a5235fb144a65e0cb2ffd360ddc1f6c32 - () https://git.kernel.org/stable/c/a6c11c0a5235fb144a65e0cb2ffd360ddc1f6c32 - Patch
References () https://git.kernel.org/stable/c/e9c96d01d520498b169ce734a8ad1142bef86a30 - () https://git.kernel.org/stable/c/e9c96d01d520498b169ce734a8ad1142bef86a30 - Patch
References () https://git.kernel.org/stable/c/ebfb16fc057a016abb46a9720a54abf0d4f6abe1 - () https://git.kernel.org/stable/c/ebfb16fc057a016abb46a9720a54abf0d4f6abe1 - Patch
References () https://git.kernel.org/stable/c/f5f4675960609d8c5ee95f027fbf6ce380f98372 - () https://git.kernel.org/stable/c/f5f4675960609d8c5ee95f027fbf6ce380f98372 - Patch

21 Nov 2024, 09:12

Type Values Removed Values Added
References () https://git.kernel.org/stable/c/59f86a2908380d09cdc726461c0fbb8d8579c99f - () https://git.kernel.org/stable/c/59f86a2908380d09cdc726461c0fbb8d8579c99f -
References () https://git.kernel.org/stable/c/6752dfcfff3ac3e16625ebd3f0ad9630900e7e76 - () https://git.kernel.org/stable/c/6752dfcfff3ac3e16625ebd3f0ad9630900e7e76 -
References () https://git.kernel.org/stable/c/9eeda3e0071a329af1eba15f4e57dc39576bb420 - () https://git.kernel.org/stable/c/9eeda3e0071a329af1eba15f4e57dc39576bb420 -
References () https://git.kernel.org/stable/c/a40209d355afe4ed6d533507838c9e5cd70a76d8 - () https://git.kernel.org/stable/c/a40209d355afe4ed6d533507838c9e5cd70a76d8 -
References () https://git.kernel.org/stable/c/a6c11c0a5235fb144a65e0cb2ffd360ddc1f6c32 - () https://git.kernel.org/stable/c/a6c11c0a5235fb144a65e0cb2ffd360ddc1f6c32 -
References () https://git.kernel.org/stable/c/e9c96d01d520498b169ce734a8ad1142bef86a30 - () https://git.kernel.org/stable/c/e9c96d01d520498b169ce734a8ad1142bef86a30 -
References () https://git.kernel.org/stable/c/ebfb16fc057a016abb46a9720a54abf0d4f6abe1 - () https://git.kernel.org/stable/c/ebfb16fc057a016abb46a9720a54abf0d4f6abe1 -
References () https://git.kernel.org/stable/c/f5f4675960609d8c5ee95f027fbf6ce380f98372 - () https://git.kernel.org/stable/c/f5f4675960609d8c5ee95f027fbf6ce380f98372 -

15 Jul 2024, 07:15

Type Values Removed Values Added
References
  • {'url': 'https://lists.debian.org/debian-lts-announce/2024/06/msg00020.html', 'source': '416baaa9-dc9f-4396-8d5f-8c081fb06d67'}

27 Jun 2024, 13:15

Type Values Removed Values Added
References
  • () https://lists.debian.org/debian-lts-announce/2024/06/msg00020.html -
Summary
  • (es) En el kernel de Linux, se resolvió la siguiente vulnerabilidad: genirq/cpuhotplug, x86/vector: evita la fuga de vectores durante la CPU fuera de línea. La ausencia de IRQD_MOVE_PCNTXT impide la efectividad inmediata de la reconfiguración de la afinidad de interrupción a través de procfs. En cambio, el cambio se difiere hasta la siguiente instancia de interrupción que se activa en la CPU original. La siguiente vez que se activa la interrupción en la CPU original, la nueva afinidad se aplica dentro de __irq_move_irq(). Se asigna un vector desde la nueva CPU, pero el vector antiguo en la CPU original permanece y no se recupera inmediatamente. En su lugar, se marca apicd->move_in_progress y el proceso de recuperación se retrasa hasta el siguiente desencadenante de la interrupción en la nueva CPU. Tras la activación posterior de la interrupción en la nueva CPU, irq_complete_move() agrega una tarea a la lista vector_cleanup de la CPU anterior si permanece en línea. Posteriormente, el temporizador de la CPU antigua itera sobre su lista vector_cleanup, recuperando vectores antiguos. Sin embargo, surge un escenario poco común si la CPU antigua sale antes de que la interrupción se active nuevamente en la nueva CPU. En ese caso, irq_force_complete_move() no se invoca en la CPU saliente para recuperar el antiguo apicd->prev_vector porque la interrupción no es actualmente afín a la CPU saliente, e irq_needs_fixup() devuelve false. Aunque más tarde se llama a __vector_schedule_cleanup() en la nueva CPU, no reclama apicd->prev_vector; en su lugar, simplemente restablece apicd->move_in_progress y apicd->prev_vector a 0. Como resultado, el vector permanece sin reclamar en vector_matrix, lo que provoca una fuga de vector de CPU. Para solucionar este problema, mueva la invocación de irq_force_complete_move() antes de la llamada irq_needs_fixup() para recuperar apicd->prev_vector, si la interrupción es actualmente o solía ser afín a la CPU saliente. Además, recupere también el vector en __vector_schedule_cleanup(), después de un mensaje de advertencia, aunque en teoría nunca debería ver apicd->move_in_progress con apicd->prev_cpu apuntando a una CPU fuera de línea.

21 Jun 2024, 11:22

Type Values Removed Values Added
New CVE

Information

Published : 2024-06-21 11:15

Updated : 2025-11-04 18:16


NVD link : CVE-2024-31076

Mitre link : CVE-2024-31076

CVE.ORG link : CVE-2024-31076


JSON object : View

Products Affected

linux

  • linux_kernel