5.5medium
nilfs2: fix potential bug in end_buffer_async_write
- Severity
- 5.5medium CVSS:3.1 by CISA-ADP
- Exploit likelihood
- 0.25% (higher than 17% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- Linux
Description
In the Linux kernel, the following vulnerability has been resolved: nilfs2: fix potential bug in end_buffer_async_write According to a syzbot report, end_buffer_async_write(), which handles the completion of block device writes, may detect abnormal condition of the buffer async_write flag and cause a BUG_ON failure when using nilfs2. Nilfs2 itself does not use end_buffer_async_write(). But, the async_write flag is now used as a marker by commit 7f42ec394156 ("nilfs2: fix issue with race condition of competition between segments for dirty blocks") as a means of resolving double list insertion of dirty blocks in nilfs_lookup_dirty_data_buffers() and nilfs_lookup_node_buffers() and the resulting crash. This modification is safe as long as it is used for file data and b-tree node blocks where the page caches are independent. However, it was irrelevant and redundant to also introduce async_write for segment summary and super root blocks that share buffers with the backing device. This led to the possibility that the BUG_ON check in end_buffer_async_write would fail as described above, if independent writebacks of the backing device occurred in parallel. The use of async_write for segment summary buffers has already been removed in a previous change. Fix this issue by removing the manipulation of the async_write flag for the remaining super root block buffer.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| Linux Linux | from 7f42ec3941560f0902fe3671e36f2c20ffd3af0a before c4a09fdac625e64abe478dcf88bfa20406616928, from 7f42ec3941560f0902fe3671e36f2c20ffd3af0a before d31c8721e816eff5ca6573cc487754f357c093cd, from 7f42ec3941560f0902fe3671e36f2c20ffd3af0a before f3e4963566f58726d3265a727116a42b591f6596, from 7f42ec3941560f0902fe3671e36f2c20ffd3af0a before 8fa90634ec3e9cc50f42dd605eec60f2d146ced8, from 7f42ec3941560f0902fe3671e36f2c20ffd3af0a before 6589f0f72f8edd1fa11adce4eedbd3615f2e78ab, from 7f42ec3941560f0902fe3671e36f2c20ffd3af0a before 2c3bdba00283a6c7a5b19481a59a730f46063803, from 7f42ec3941560f0902fe3671e36f2c20ffd3af0a before 626daab3811b772086aef1bf8eed3ffe6f523eff, from 7f42ec3941560f0902fe3671e36f2c20ffd3af0a before 5bc09b397cbf1221f8a8aacb1152650c9195b02b and 9 more Not affected: before 3.12, from 4.19.307 up to 4.19.*, from 5.4.269 up to 5.4.*, from 5.10.210 up to 5.10.*, from 5.15.149 up to 5.15.*, from 6.1.79 up to 6.1.* | CVE List |
| linux linux_kernel | from 3.2.52 before 3.3, from 3.4.83 before 3.5, from 3.10.16 before 3.11, from 3.11.5 before 4.19.307, from 4.20 before 5.4.269, from 5.5 before 5.10.210, from 5.11 before 5.15.149, from 5.16 before 6.1.79 and 3 more | NVD |
| debian debian_linux | 10.0 | NVD |
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: nilfs2: fix potential bug in end_buffer_async_write According to a syzbot report, end_buffer_async_write(), which handles the completion of block device writes, may detect abnormal condition of the buffer async_write flag and cause a BUG_ON failure when using nilfs2. Nilfs2 itself does not use end_buffer_async_write(). But, the async_write flag is now used as a marker by commit 7f42ec394156 ("nilfs2: fix issue with race condition of competition between segments for dirty blocks") as a means of resolving double list insertion of dirty blocks in nilfs_lookup_dirty_data_buffers() and nilfs_lookup_node_buffers() and the resulting crash. This modification is safe as long as it is used for file data and b-tree node blocks where the page caches are independent. However, it was irrelevant and redundant to also introduce async_write for segment summary and super root blocks that share buffers with the backing device. This led to the possibility that the BUG_ON check in end_buffer_async_write would fail as described above, if independent writebacks of the backing device occurred in parallel. The use of async_write for segment summary buffers has already been removed in a previous change. Fix this issue by removing the manipulation of the async_write flag for the remaining super root block buffer.
NVD (es)
En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: nilfs2: corrige un posible error en end_buffer_async_write Según un informe de syzbot, end_buffer_async_write(), que maneja la finalización de las escrituras del dispositivo de bloque, puede detectar una condición anormal del indicador async_write del búfer y causar un Error BUG_ON al usar nilfs2. Nilfs2 en sí no usa end_buffer_async_write(). Pero el indicador async_write ahora se usa como marcador en el commit 7f42ec394156 ("nilfs2: soluciona el problema con la condición de ejecución de competencia entre segmentos por bloques sucios") como un medio para resolver la inserción de lista doble de bloques sucios en nilfs_lookup_dirty_data_buffers() y nilfs_lookup_node_buffers( ) y el accidente resultante. Esta modificación es segura siempre que se utilice para datos de archivos y bloques de nodos de árbol b donde las cachés de páginas sean independientes. Sin embargo, era irrelevante y redundante introducir también async_write para el resumen de segmento y los bloques súper raíz que comparten buffers con el dispositivo de respaldo. Esto generó la posibilidad de que la verificación BUG_ON en end_buffer_async_write fallara como se describe anteriormente, si se produjeran reescrituras independientes del dispositivo de respaldo en paralelo. El uso de async_write para buffers de resumen de segmentos ya se eliminó en un cambio anterior. Solucione este problema eliminando la manipulación del indicador async_write para el búfer de bloque súper raíz restante.
References
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2024-26685 changed 2026-05-23 | CVE Terms of Use |
| NVD | CVE-2024-26685 changed 2026-06-17 | Public domain |