{"id":"CVE-2026-31448","aliases":["CVE-2026-31448"],"related":[],"kind":"vulnerability","state":"published","title":"ext4: avoid infinite loops caused by residual data","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\next4: avoid infinite loops caused by residual data\n\nOn the mkdir/mknod path, when mapping logical blocks to physical blocks,\nif inserting a new extent into the extent tree fails (in this example,\nbecause the file system disabled the huge file feature when marking the\ninode as dirty), ext4_ext_map_blocks() only calls ext4_free_blocks() to\nreclaim the physical block without deleting the corresponding data in\nthe extent tree. This causes subsequent mkdir operations to reference\nthe previously reclaimed physical block number again, even though this\nphysical block is already being used by the xattr block. Therefore, a\nsituation arises where both the directory and xattr are using the same\nbuffer head block in memory simultaneously.\n\nThe above causes ext4_xattr_block_set() to enter an infinite loop about\n\"inserted\" and cannot release the inode lock, ultimately leading to the\n143s blocking problem mentioned in [1].\n\nIf the metadata is corrupted, then trying to remove some extent space\ncan do even more harm. Also in case EXT4_GET_BLOCKS_DELALLOC_RESERVE\nwas passed, remove space wrongly update quota information.\nJan Kara suggests distinguishing between two cases:\n\n1) The error is ENOSPC or EDQUOT - in this case the filesystem is fully\nconsistent and we must maintain its consistency including all the\naccounting. However these errors can happen only early before we've\ninserted the extent into the extent tree. So current code works correctly\nfor this case.\n\n2) Some other error - this means metadata is corrupted. We should strive to\ndo as few modifications as possible to limit damage. So I'd just skip\nfreeing of allocated blocks.\n\n[1]\nINFO: task syz.0.17:5995 blocked for more than 143 seconds.\nCall Trace:\n inode_lock_nested include/linux/fs.h:1073 [inline]\n __start_dirop fs/namei.c:2923 [inline]\n start_dirop fs/namei.c:2934 [inline]","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\next4: avoid infinite loops caused by residual data\n\nOn the mkdir/mknod path, when mapping logical blocks to physical blocks,\nif inserting a new extent into the extent tree fails (in this example,\nbecause the file system disabled the huge file feature when marking the\ninode as dirty), ext4_ext_map_blocks() only calls ext4_free_blocks() to\nreclaim the physical block without deleting the corresponding data in\nthe extent tree. This causes subsequent mkdir operations to reference\nthe previously reclaimed physical block number again, even though this\nphysical block is already being used by the xattr block. Therefore, a\nsituation arises where both the directory and xattr are using the same\nbuffer head block in memory simultaneously.\n\nThe above causes ext4_xattr_block_set() to enter an infinite loop about\n\"inserted\" and cannot release the inode lock, ultimately leading to the\n143s blocking problem mentioned in [1].\n\nIf the metadata is corrupted, then trying to remove some extent space\ncan do even more harm. Also in case EXT4_GET_BLOCKS_DELALLOC_RESERVE\nwas passed, remove space wrongly update quota information.\nJan Kara suggests distinguishing between two cases:\n\n1) The error is ENOSPC or EDQUOT - in this case the filesystem is fully\nconsistent and we must maintain its consistency including all the\naccounting. However these errors can happen only early before we've\ninserted the extent into the extent tree. So current code works correctly\nfor this case.\n\n2) Some other error - this means metadata is corrupted. We should strive to\ndo as few modifications as possible to limit damage. So I'd just skip\nfreeing of allocated blocks.\n\n[1]\nINFO: task syz.0.17:5995 blocked for more than 143 seconds.\nCall Trace:\n inode_lock_nested include/linux/fs.h:1073 [inline]\n __start_dirop fs/namei.c:2923 [inline]\n start_dirop fs/namei.c:2934 [inline]","source":"cvelist"},{"lang":"es","text":"En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta:\n\next4: evitar bucles infinitos causados por datos residuales\n\nEn la ruta mkdir/mknod, al mapear bloques lógicos a bloques físicos, si la inserción de un nuevo extent en el árbol de extents falla (en este ejemplo, porque el sistema de archivos deshabilitó la característica de archivos grandes al marcar el inodo como sucio), ext4_ext_map_blocks() solo llama a ext4_free_blocks() para reclamar el bloque físico sin eliminar los datos correspondientes en el árbol de extents. Esto hace que las operaciones mkdir posteriores referencien de nuevo el número de bloque físico previamente reclamado, aunque este bloque físico ya esté siendo utilizado por el bloque xattr. Por lo tanto, surge una situación en la que tanto el directorio como xattr están utilizando el mismo bloque de cabecera de búfer en memoria simultáneamente.\n\nLo anterior hace que ext4_xattr_block_set() entre en un bucle infinito sobre ’inserted’ y no pueda liberar el bloqueo del inodo, lo que finalmente lleva al problema de bloqueo de 143s mencionado en [1].\n\nSi los metadatos están corruptos, entonces intentar eliminar algo de espacio de extent puede causar aún más daño. También en caso de que se pasara EXT4_GET_BLOCKS_DELALLOC_RESERVE, la eliminación de espacio actualiza erróneamente la información de cuota. Jan Kara sugiere distinguir entre dos casos:\n\n1) El error es ENOSPC o EDQUOT - en este caso el sistema de archivos es totalmente consistente y debemos mantener su consistencia incluyendo toda la contabilidad. Sin embargo, estos errores solo pueden ocurrir temprano antes de haber insertado el extent en el árbol de extents. Por lo tanto, el código actual funciona correctamente para este caso.\n\n2) Algún otro error - esto significa que los metadatos están corruptos. Debemos esforzarnos por hacer la menor cantidad de modificaciones posible para limitar el daño. Así que simplemente omitiría la liberación de bloques asignados.\n\n[1]\nINFO: la tarea syz.0.17:5995 bloqueada durante más de 143 segundos.\nTraza de Llamada:\n inode_lock_nested include/linux/fs.h:1073 [inline]\n __start_dirop fs/namei.c:2923 [inline]\n start_dirop fs/namei.c:2934 [inline]","source":"nvd"}],"published":"2026-04-22T13:53:44.129Z","modified":"2026-12-01T07:17:18.200Z","severity":{"scorer":"Linux","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:H/A:H","score":9.4,"rating":"CRITICAL"},"severities":[{"scorer":"Linux","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:H/A:H","score":9.4,"rating":"CRITICAL"}],"cwes":["CWE-835"],"affected":[{"ranges":[{"type":"git","introduced":"315054f023d28ee64f308adf8b5737831541776b","fixed":"fb3356d72151b554e2b4bc92b368d4c648cce5d9","status":"affected"},{"type":"git","introduced":"315054f023d28ee64f308adf8b5737831541776b","fixed":"101ddb1c8f4b0a196e5cbbf51edf4bb328838868","status":"affected"},{"type":"git","introduced":"315054f023d28ee64f308adf8b5737831541776b","fixed":"c66545e83a802c3851d9be27a41c0479dd29ff0c","status":"affected"},{"type":"git","introduced":"315054f023d28ee64f308adf8b5737831541776b","fixed":"ecc50bfca9b5c2ee6aeef998181689b80477367b","status":"affected"},{"type":"git","introduced":"315054f023d28ee64f308adf8b5737831541776b","fixed":"3a7667595bcad84da53fc156a418e110267c3412","status":"affected"},{"type":"git","introduced":"315054f023d28ee64f308adf8b5737831541776b","fixed":"416c86f30f91b4fb2642ef6b102596ca898f41a5","status":"affected"},{"type":"git","introduced":"315054f023d28ee64f308adf8b5737831541776b","fixed":"64f425b06b3bea9abc8977fd3982779b3ad070c9","status":"affected"},{"type":"git","introduced":"315054f023d28ee64f308adf8b5737831541776b","fixed":"5422fe71d26d42af6c454ca9527faaad4e677d6c","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"2.6.22","status":"affected"},{"type":"semver","introduced":"0","fixed":"2.6.22","status":"unaffected"},{"type":"semver","introduced":"5.10.276","lastAffected":"5.10.*","status":"unaffected"},{"type":"semver","introduced":"5.15.227","lastAffected":"5.15.*","status":"unaffected"},{"type":"semver","introduced":"6.1.168","lastAffected":"6.1.*","status":"unaffected"},{"type":"semver","introduced":"6.6.131","lastAffected":"6.6.*","status":"unaffected"},{"type":"semver","introduced":"6.12.80","lastAffected":"6.12.*","status":"unaffected"},{"type":"semver","introduced":"6.18.21","lastAffected":"6.18.*","status":"unaffected"},{"type":"semver","introduced":"6.19.11","lastAffected":"6.19.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"7.0","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"status":"affected","introduced":"2.6.22.1","fixed":"6.1.168"},{"status":"affected","introduced":"6.2","fixed":"6.6.131"},{"status":"affected","introduced":"6.7","fixed":"6.12.80"},{"status":"affected","introduced":"6.13","fixed":"6.18.21"},{"status":"affected","introduced":"6.19","fixed":"6.19.11"},{"status":"affected","version":"2.6.22"},{"status":"affected","version":"2.6.22"},{"status":"affected","version":"2.6.22"},{"status":"affected","version":"2.6.22"},{"status":"affected","version":"2.6.22"},{"status":"affected","version":"7.0"},{"status":"affected","version":"7.0"},{"status":"affected","version":"7.0"},{"status":"affected","version":"7.0"},{"status":"affected","version":"7.0"}],"vendor":"linux","product":"linux_kernel","cpe":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://git.kernel.org/stable/c/fb3356d72151b554e2b4bc92b368d4c648cce5d9","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/101ddb1c8f4b0a196e5cbbf51edf4bb328838868","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/c66545e83a802c3851d9be27a41c0479dd29ff0c","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/ecc50bfca9b5c2ee6aeef998181689b80477367b","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/3a7667595bcad84da53fc156a418e110267c3412","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/416c86f30f91b4fb2642ef6b102596ca898f41a5","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/64f425b06b3bea9abc8977fd3982779b3ad070c9","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/5422fe71d26d42af6c454ca9527faaad4e677d6c","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://cert-portal.siemens.com/productcert/html/ssa-082556.html","tags":[],"sources":["cvelist","nvd"]},{"url":"https://cert-portal.siemens.com/productcert/html/ssa-019113.html","tags":[],"sources":["cvelist","nvd"]},{"url":"https://cert-portal.siemens.com/productcert/html/ssa-457936.html","tags":[],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"yes","technicalImpact":"partial","date":"2026-10-16T15:09:25.858Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-31448","url":"https://www.cve.org/CVERecord?id=CVE-2026-31448","licence":"CVE Terms of Use","modified":"2026-12-01T06:51:48.663Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-31448","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-31448","licence":"Public domain","modified":"2026-12-01T07:17:18.200Z"}],"updatedAt":"2026-12-01T07:32:13.678Z","epss":{"score":0.0076,"percentile":0.51634,"date":"2026-11-29T12:00:22.000Z"}}