CVE-2025-21896
JSON

7.8high

fuse: revert back to __readahead_folio() for readahead

Severity
7.8high CVSS:3.1 by Linux
Exploit likelihood
0.22% (higher than 13% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
Linux

Description

In the Linux kernel, the following vulnerability has been resolved: fuse: revert back to __readahead_folio() for readahead In commit 3eab9d7bc2f4 ("fuse: convert readahead to use folios"), the logic was converted to using the new folio readahead code, which drops the reference on the folio once it is locked, using an inferred reference on the folio. Previously we held a reference on the folio for the entire duration of the readpages call. This is fine, however for the case for splice pipe responses where we will remove the old folio and splice in the new folio (see fuse_try_move_page()), we assume that there is a reference held on the folio for ap->folios, which is no longer the case. To fix this, revert back to __readahead_folio() which allows us to hold the reference on the folio for the duration of readpages until either we drop the reference ourselves in fuse_readpages_end() or the reference is dropped after it's replaced in the page cache in the splice case. This will fix the UAF bug that was reported.

Affected

Product or packageVersionsReported by
Linux Linuxfrom 3eab9d7bc2f4ae7f3f9c9c7852ff61600df79856 before 60db11f1b7fba4a66b117ea998d965818784a98d, from 3eab9d7bc2f4ae7f3f9c9c7852ff61600df79856 before 0c67c37e1710b2a8f61c8a02db95a51fe577e2c1, 6.13
Not affected: before 6.13, from 6.13.6 up to 6.13.*, from 6.14 up to *
CVE List
linux linux_kernelfrom 6.13 before 6.13.6, 6.14NVD

All scores

Linux7.8high CVSS:3.1CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
NVD7.8high CVSS:3.1CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Classification

What each source says

CVE List

In the Linux kernel, the following vulnerability has been resolved: fuse: revert back to __readahead_folio() for readahead In commit 3eab9d7bc2f4 ("fuse: convert readahead to use folios"), the logic was converted to using the new folio readahead code, which drops the reference on the folio once it is locked, using an inferred reference on the folio. Previously we held a reference on the folio for the entire duration of the readpages call. This is fine, however for the case for splice pipe responses where we will remove the old folio and splice in the new folio (see fuse_try_move_page()), we assume that there is a reference held on the folio for ap->folios, which is no longer the case. To fix this, revert back to __readahead_folio() which allows us to hold the reference on the folio for the duration of readpages until either we drop the reference ourselves in fuse_readpages_end() or the reference is dropped after it's replaced in the page cache in the splice case. This will fix the UAF bug that was reported.

NVD (es)

En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: fuse: volver a __readahead_folio() para readahead. En el commit 3eab9d7bc2f4 ("fuse: convertir readahead para usar folios"), la lógica se convirtió para usar el nuevo código de readahead de folio, que elimina la referencia en el folio una vez bloqueado, usando una referencia inferida en el folio. Anteriormente, manteníamos una referencia en el folio durante toda la duración de la llamada a readpages. Esto es correcto, sin embargo, para el caso de las respuestas de la tubería de empalme donde eliminaremos el folio antiguo y empalmaremos en el nuevo folio (ver fuse_try_move_page()), asumimos que hay una referencia mantenida en el folio para ap->folios, lo cual ya no es el caso. Para solucionar esto, vuelva a __readahead_folio(), que nos permite mantener la referencia en el folio durante la lectura de páginas hasta que la eliminemos nosotros mismos en fuse_readpages_end() o hasta que se elimine tras ser reemplazada en la caché de páginas en el caso de empalme. Esto solucionará el error de UAF reportado.

References

Sources

SourceRecordLicence
CVE ListCVE-2025-21896 changed 2026-08-05CVE Terms of Use
NVDCVE-2025-21896 changed 2026-07-30Public domain