CVE-2026-31652

In the Linux kernel, the following vulnerability has been resolved: mm/damon/stat: deallocate damon_call() failure leaking damon_ctx damon_stat_start() always allocates the module's damon_ctx object (damon_stat_context). Meanwhile, if damon_call() in the function fails, the damon_ctx object is not deallocated. Hence, if the damon_call() is failed, and the user writes Y to “enabled” again, the previously allocated damon_ctx object is leaked. This cannot simply be fixed by deallocating the damon_ctx object when damon_call() fails. That's because damon_call() failure doesn't guarantee the kdamond main function, which accesses the damon_ctx object, is completely finished. In other words, if damon_stat_start() deallocates the damon_ctx object after damon_call() failure, the not-yet-terminated kdamond could access the freed memory (use-after-free). Fix the leak while avoiding the use-after-free by keeping returning damon_stat_start() without deallocating the damon_ctx object after damon_call() failure, but deallocating it when the function is invoked again and the kdamond is completely terminated. If the kdamond is not yet terminated, simply return -EAGAIN, as the kdamond will soon be terminated. The issue was discovered [1] by sashiko.
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:6.17:-:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:7.0:rc1:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:7.0:rc2:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:7.0:rc3:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:7.0:rc4:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:7.0:rc5:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:7.0:rc6:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:7.0:rc7:*:*:*:*:*:*

History

11 Nov 2026, 23:10

Type Values Removed Values Added
Summary
  • (es) En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta: mm/damon/stat: desasignar el damon_ctx que se fuga por fallo de damon_call() damon_stat_start() siempre asigna el objeto damon_ctx del módulo (damon_stat_context). Mientras tanto, si damon_call() en la función falla, el objeto damon_ctx no es desasignado. Por lo tanto, si damon_call() falla, y el usuario escribe Y en ’enabled’ de nuevo, el objeto damon_ctx previamente asignado se fuga. Esto no puede ser simplemente corregido desasignando el objeto damon_ctx cuando damon_call() falla. Esto se debe a que el fallo de damon_call() no garantiza que la función principal de kdamond, que accede al objeto damon_ctx, esté completamente terminada. En otras palabras, si damon_stat_start() desasigna el objeto damon_ctx después del fallo de damon_call(), el kdamond aún no terminado podría acceder a la memoria liberada (uso después de liberación). Corregir la fuga evitando el uso después de liberación, haciendo que damon_stat_start() siga retornando sin desasignar el objeto damon_ctx después del fallo de damon_call(), pero desasignándolo cuando la función es invocada de nuevo y el kdamond está completamente terminado. Si el kdamond aún no está terminado, simplemente retornar -EAGAIN, ya que el kdamond pronto será terminado. El problema fue descubierto [1] por sashiko.

Information

Published : 2026-04-24 15:16

Updated : 2026-11-11 23:10


NVD link : CVE-2026-31652

Mitre link : CVE-2026-31652

CVE.ORG link : CVE-2026-31652


JSON object : View

Products Affected

linux

  • linux_kernel
CWE
CWE-416

Use After Free