{"resultsPerPage":1,"startIndex":0,"totalResults":1,"format":"NVD_CVE","version":"2.0","timestamp":"2026-06-17T00:47:36.452","vulnerabilities":[{"cve":{"id":"CVE-2025-71183","sourceIdentifier":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","published":"2026-01-31T12:16:03.570","lastModified":"2026-03-25T19:16:17.120","vulnStatus":"Analyzed","cveTags":[],"descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nbtrfs: always detect conflicting inodes when logging inode refs\n\nAfter rename exchanging (either with the rename exchange operation or\nregular renames in multiple non-atomic steps) two inodes and at least\none of them is a directory, we can end up with a log tree that contains\nonly of the inodes and after a power failure that can result in an attempt\nto delete the other inode when it should not because it was not deleted\nbefore the power failure. In some case that delete attempt fails when\nthe target inode is a directory that contains a subvolume inside it, since\nthe log replay code is not prepared to deal with directory entries that\npoint to root items (only inode items).\n\n1) We have directories \"dir1\" (inode A) and \"dir2\" (inode B) under the\n   same parent directory;\n\n2) We have a file (inode C) under directory \"dir1\" (inode A);\n\n3) We have a subvolume inside directory \"dir2\" (inode B);\n\n4) All these inodes were persisted in a past transaction and we are\n   currently at transaction N;\n\n5) We rename the file (inode C), so at btrfs_log_new_name() we update\n   inode C's last_unlink_trans to N;\n\n6) We get a rename exchange for \"dir1\" (inode A) and \"dir2\" (inode B),\n   so after the exchange \"dir1\" is inode B and \"dir2\" is inode A.\n   During the rename exchange we call btrfs_log_new_name() for inodes\n   A and B, but because they are directories, we don't update their\n   last_unlink_trans to N;\n\n7) An fsync against the file (inode C) is done, and because its inode\n   has a last_unlink_trans with a value of N we log its parent directory\n   (inode A) (through btrfs_log_all_parents(), called from\n   btrfs_log_inode_parent()).\n\n8) So we end up with inode B not logged, which now has the old name\n   of inode A. At copy_inode_items_to_log(), when logging inode A, we\n   did not check if we had any conflicting inode to log because inode\n   A has a generation lower than the current transaction (created in\n   a past transaction);\n\n9) After a power failure, when replaying the log tree, since we find that\n   inode A has a new name that conflicts with the name of inode B in the\n   fs tree, we attempt to delete inode B... this is wrong since that\n   directory was never deleted before the power failure, and because there\n   is a subvolume inside that directory, attempting to delete it will fail\n   since replay_dir_deletes() and btrfs_unlink_inode() are not prepared\n   to deal with dir items that point to roots instead of inodes.\n\n   When that happens the mount fails and we get a stack trace like the\n   following:\n\n   [87.2314] BTRFS info (device dm-0): start tree-log replay\n   [87.2318] BTRFS critical (device dm-0): failed to delete reference to subvol, root 5 inode 256 parent 259\n   [87.2332] ------------[ cut here ]------------\n   [87.2338] BTRFS: Transaction aborted (error -2)\n   [87.2346] WARNING: CPU: 1 PID: 638968 at fs/btrfs/inode.c:4345 __btrfs_unlink_inode+0x416/0x440 [btrfs]\n   [87.2368] Modules linked in: btrfs loop dm_thin_pool (...)\n   [87.2470] CPU: 1 UID: 0 PID: 638968 Comm: mount Tainted: G        W           6.18.0-rc7-btrfs-next-218+ #2 PREEMPT(full)\n   [87.2489] Tainted: [W]=WARN\n   [87.2494] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.16.2-0-gea1b7a073390-prebuilt.qemu.org 04/01/2014\n   [87.2514] RIP: 0010:__btrfs_unlink_inode+0x416/0x440 [btrfs]\n   [87.2538] Code: c0 89 04 24 (...)\n   [87.2568] RSP: 0018:ffffc0e741f4b9b8 EFLAGS: 00010286\n   [87.2574] RAX: 0000000000000000 RBX: ffff9d3ec8a6cf60 RCX: 0000000000000000\n   [87.2582] RDX: 0000000000000002 RSI: ffffffff84ab45a1 RDI: 00000000ffffffff\n   [87.2591] RBP: ffff9d3ec8a6ef20 R08: 0000000000000000 R09: ffffc0e741f4b840\n   [87.2599] R10: ffff9d45dc1fffa8 R11: 0000000000000003 R12: ffff9d3ee26d77e0\n   [87.2608] R13: ffffc0e741f4ba98 R14: ffff9d4458040800 R15: ffff9d44b6b7ca10\n   [87.2618] FS:  00007f7b9603a840(0000) GS:ffff9d4658982000(0000) knlGS:0000000000000000\n   [87.\n---truncated---"},{"lang":"es","value":"En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta:  btrfs: siempre detectar inodos en conflicto al registrar referencias de inodos  Después de un intercambio de renombre (ya sea con la operación de intercambio de renombre o renombres regulares en múltiples pasos no atómicos) de dos inodos y al menos uno de ellos es un directorio, podemos terminar con un árbol de registro que contiene solo uno de los inodos y después de un fallo de energía eso puede resultar en un intento de eliminar el otro inodo cuando no debería porque no fue eliminado antes del fallo de energía. En algunos casos, ese intento de eliminación falla cuando el inodo de destino es un directorio que contiene un subvolumen dentro de él, ya que el código de reproducción del registro no está preparado para manejar entradas de directorio que apuntan a elementos raíz (solo elementos de inodo).  1) Tenemos directorios 'dir1' (inodo A) y 'dir2' (inodo B) bajo el mismo directorio padre;  2) Tenemos un archivo (inodo C) bajo el directorio 'dir1' (inodo A);  3) Tenemos un subvolumen dentro del directorio 'dir2' (inodo B);  4) Todos estos inodos fueron persistidos en una transacción pasada y actualmente estamos en la transacción N;  5) Renombramos el archivo (inodo C), así que en btrfs_log_new_name() actualizamos el last_unlink_trans del inodo C a N;  6) Obtenemos un intercambio de renombre para 'dir1' (inodo A) y 'dir2' (inodo B), así que después del intercambio 'dir1' es el inodo B y 'dir2' es el inodo A. Durante el intercambio de renombre llamamos a btrfs_log_new_name() para los inodos A y B, pero como son directorios, no actualizamos su last_unlink_trans a N;  7) Se realiza un fsync contra el archivo (inodo C), y debido a que su inodo tiene un last_unlink_trans con un valor de N registramos su directorio padre (inodo A) (a través de btrfs_log_all_parents(), llamado desde btrfs_log_inode_parent()).  8) Así que terminamos con el inodo B no registrado, que ahora tiene el nombre antiguo del inodo A. En copy_inode_items_to_log(), al registrar el inodo A, no verificamos si teníamos algún inodo en conflicto para registrar porque el inodo A tiene una generación inferior a la transacción actual (creado en una transacción pasada);  9) Después de un fallo de energía, al reproducir el árbol de registro, ya que encontramos que el inodo A tiene un nuevo nombre que entra en conflicto con el nombre del inodo B en el árbol del sistema de archivos, intentamos eliminar el inodo B... esto es incorrecto ya que ese directorio nunca fue eliminado antes del fallo de energía, y porque hay un subvolumen dentro de ese directorio, intentar eliminarlo fallará ya que replay_dir_deletes() y btrfs_unlink_inode() no están preparados para manejar elementos de directorio que apuntan a raíces en lugar de inodos.  Cuando eso sucede el montaje falla y obtenemos un seguimiento de pila como el siguiente:  [87.2314] Información de BTRFS (dispositivo dm-0): inicio de reproducción del registro de árbol [87.2318] Crítico de BTRFS (dispositivo dm-0): falló al eliminar la referencia al subvolumen, raíz 5 inodo 256 padre 259 [87.2332] ------------[ cut here ]------------ [87.2338] BTRFS: Transacción abortada (error -2) [87.2346] ADVERTENCIA: CPU: 1 PID: 638968 en fs/btrfs/inode.c:4345 __btrfs_unlink_inode+0x416/0x440 [btrfs] [87.2368] Módulos enlazados: btrfs loop dm_thin_pool (...) [87.2470] CPU: 1 UID: 0 PID: 638968 Comm: mount Tainted: G"}],"metrics":{"cvssMetricV31":[{"source":"nvd@nist.gov","type":"Primary","cvssData":{"version":"3.1","vectorString":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","baseScore":5.5,"baseSeverity":"MEDIUM","attackVector":"LOCAL","attackComplexity":"LOW","privilegesRequired":"LOW","userInteraction":"NONE","scope":"UNCHANGED","confidentialityImpact":"NONE","integrityImpact":"NONE","availabilityImpact":"HIGH"},"exploitabilityScore":1.8,"impactScore":3.6}]},"weaknesses":[{"source":"nvd@nist.gov","type":"Primary","description":[{"lang":"en","value":"NVD-CWE-noinfo"}]}],"configurations":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"3.18.32","versionEndExcluding":"3.19","matchCriteriaId":"74263283-B447-48B8-BCC8-109460AAE2E3"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.1.23","versionEndExcluding":"4.2","matchCriteriaId":"566FCC4C-3928-4B30-84CA-0F32EF3E983A"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.4.8","versionEndExcluding":"4.5","matchCriteriaId":"03151A20-B391-4679-9B11-C4E1861FDD0D"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.5.2","versionEndExcluding":"4.6","matchCriteriaId":"88F022EB-29BD-4EA9-85B4-5BF89E332B07"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"4.6.1","versionEndExcluding":"6.1.161","matchCriteriaId":"040C1144-458F-4589-93EE-D6A064EA7595"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.2","versionEndExcluding":"6.6.121","matchCriteriaId":"BB7A164B-7422-4A1C-82FB-5FCAEE53C06C"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.7","versionEndExcluding":"6.12.66","matchCriteriaId":"F72B884C-B44F-40E4-9895-CE421AC663D0"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.13","versionEndExcluding":"6.18.6","matchCriteriaId":"879529BC-5B4C-4EBE-BF1D-1A31404A8B2E"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:4.6:-:*:*:*:*:*:*","matchCriteriaId":"92D59C76-843D-4745-972B-CAFF5331371C"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:6.19:rc1:*:*:*:*:*:*","matchCriteriaId":"17B67AA7-40D6-4AFA-8459-F200F3D7CFD1"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:6.19:rc2:*:*:*:*:*:*","matchCriteriaId":"C47E4CC9-C826-4FA9-B014-7FE3D9B318B2"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:6.19:rc3:*:*:*:*:*:*","matchCriteriaId":"F71D92C0-C023-48BD-B3B6-70B638EEE298"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:6.19:rc4:*:*:*:*:*:*","matchCriteriaId":"13580667-0A98-40CC-B29F-D12790B91BDB"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:6.19:rc5:*:*:*:*:*:*","matchCriteriaId":"CAD1FED7-CF48-47BF-AC7D-7B6FA3C065FC"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:6.19:rc6:*:*:*:*:*:*","matchCriteriaId":"3EF854A1-ABB1-4E93-BE9A-44569EC76C0D"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:6.19:rc7:*:*:*:*:*:*","matchCriteriaId":"F5DC0CA6-F0AF-4DDF-A882-3DADB9A886A7"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:6.19:rc8:*:*:*:*:*:*","matchCriteriaId":"EB5B7DFC-C36B-45D8-922C-877569FDDF43"}]}]}],"references":[{"url":"https://git.kernel.org/stable/c/0c2413c69129f6ce60157f7b53d9ba880260400b","source":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":["Patch"]},{"url":"https://git.kernel.org/stable/c/7ba0b6461bc4edb3005ea6e00cdae189bcf908a5","source":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":["Patch"]},{"url":"https://git.kernel.org/stable/c/a63998cd6687c14b160dccb0bbcf281b2eb0dab3","source":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":["Patch"]},{"url":"https://git.kernel.org/stable/c/c7f0207db68d5a1b4af23acbef1a8e8ddc431ebb","source":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":["Patch"]},{"url":"https://git.kernel.org/stable/c/d52af58dd463821c5c516aebb031a58934f696ea","source":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":["Patch"]}]}}]}