{"id":"CVE-2024-57940","aliases":["CVE-2024-57940"],"related":[],"kind":"vulnerability","state":"published","title":"exfat: fix the infinite loop in exfat_readdir()","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\nexfat: fix the infinite loop in exfat_readdir()\n\nIf the file system is corrupted so that a cluster is linked to\nitself in the cluster chain, and there is an unused directory\nentry in the cluster, 'dentry' will not be incremented, causing\ncondition 'dentry < max_dentries' unable to prevent an infinite\nloop.\n\nThis infinite loop causes s_lock not to be released, and other\ntasks will hang, such as exfat_sync_fs().\n\nThis commit stops traversing the cluster chain when there is unused\ndirectory entry in the cluster to avoid this infinite loop.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\nexfat: fix the infinite loop in exfat_readdir()\n\nIf the file system is corrupted so that a cluster is linked to\nitself in the cluster chain, and there is an unused directory\nentry in the cluster, 'dentry' will not be incremented, causing\ncondition 'dentry < max_dentries' unable to prevent an infinite\nloop.\n\nThis infinite loop causes s_lock not to be released, and other\ntasks will hang, such as exfat_sync_fs().\n\nThis commit stops traversing the cluster chain when there is unused\ndirectory entry in the cluster to avoid this infinite loop.","source":"cvelist"},{"lang":"es","text":"En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: exfat: se corrige el bucle infinito en exfat_readdir() Si el sistema de archivos está dañado de modo que un clúster está vinculado a sí mismo en la cadena de clústeres y hay una entrada de directorio sin usar en el clúster, 'dentry' no se incrementará, lo que provocará que la condición 'dentry &lt; max_dentries' no pueda evitar un bucle infinito. Este bucle infinito hace que s_lock no se libere y otras tareas se cuelguen, como exfat_sync_fs(). Esta confirmación deja de recorrer la cadena de clústeres cuando hay una entrada de directorio sin usar en el clúster para evitar este bucle infinito.","source":"nvd"}],"published":"2025-01-21T12:18:09.150Z","modified":"2026-10-15T02:17:13.330Z","severity":{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"},"severities":[{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"}],"cwes":["CWE-835"],"affected":[{"ranges":[{"type":"git","introduced":"ca06197382bde0a3bc20215595d1c9ce20c6e341","fixed":"d8cfbb8723bd3d3222f360227a1cc15227189ca6","status":"affected"},{"type":"git","introduced":"ca06197382bde0a3bc20215595d1c9ce20c6e341","fixed":"28c21f0ac5293a4bf19b3e0e32005d6dd31a6c17","status":"affected"},{"type":"git","introduced":"ca06197382bde0a3bc20215595d1c9ce20c6e341","fixed":"31beabd0f47f8c3ed9965ba861c9e5b252d4920a","status":"affected"},{"type":"git","introduced":"ca06197382bde0a3bc20215595d1c9ce20c6e341","fixed":"dc1d7afceb982e8f666e70a582e6b5aa806de063","status":"affected"},{"type":"git","introduced":"ca06197382bde0a3bc20215595d1c9ce20c6e341","fixed":"d9ea94f5cd117d56e573696d0045ab3044185a15","status":"affected"},{"type":"git","introduced":"ca06197382bde0a3bc20215595d1c9ce20c6e341","fixed":"fee873761bd978d077d8c55334b4966ac4cb7b59","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"5.7","status":"affected"},{"type":"semver","introduced":"0","fixed":"5.7","status":"unaffected"},{"type":"semver","introduced":"5.10.234","lastAffected":"5.10.*","status":"unaffected"},{"type":"semver","introduced":"5.15.177","lastAffected":"5.15.*","status":"unaffected"},{"type":"semver","introduced":"6.1.125","lastAffected":"6.1.*","status":"unaffected"},{"type":"semver","introduced":"6.6.72","lastAffected":"6.6.*","status":"unaffected"},{"type":"semver","introduced":"6.12.10","lastAffected":"6.12.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"6.13","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":"5.7","fixed":"6.1.125"},{"status":"affected","introduced":"6.2","fixed":"6.6.72"},{"status":"affected","introduced":"6.7","fixed":"6.12.10"},{"status":"affected","version":"6.13"},{"status":"affected","version":"6.13"},{"status":"affected","version":"6.13"},{"status":"affected","version":"6.13"},{"status":"affected","version":"6.13"},{"status":"affected","version":"6.13"}],"vendor":"linux","product":"linux_kernel","cpe":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://git.kernel.org/stable/c/d8cfbb8723bd3d3222f360227a1cc15227189ca6","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/28c21f0ac5293a4bf19b3e0e32005d6dd31a6c17","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/31beabd0f47f8c3ed9965ba861c9e5b252d4920a","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/dc1d7afceb982e8f666e70a582e6b5aa806de063","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/d9ea94f5cd117d56e573696d0045ab3044185a15","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/fee873761bd978d077d8c55334b4966ac4cb7b59","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://lists.debian.org/debian-lts-announce/2025/03/msg00001.html","tags":[],"sources":["cvelist","nvd"]},{"url":"https://lists.debian.org/debian-lts-announce/2025/03/msg00002.html","tags":[],"sources":["cvelist","nvd"]},{"url":"https://cert-portal.siemens.com/productcert/html/ssa-265688.html","tags":[],"sources":["cvelist","nvd"]},{"url":"https://cert-portal.siemens.com/productcert/html/ssa-503939.html","tags":[],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2024-57940","url":"https://www.cve.org/CVERecord?id=CVE-2024-57940","licence":"CVE Terms of Use","modified":"2026-10-15T01:00:52.079Z"},{"source":"nvd","name":"NVD","id":"CVE-2024-57940","url":"https://nvd.nist.gov/vuln/detail/CVE-2024-57940","licence":"Public domain","modified":"2026-10-15T02:17:13.330Z"}],"updatedAt":"2026-11-25T22:58:51.150Z","epss":{"score":0.00225,"percentile":0.14009,"date":"2026-12-01T12:00:22.000Z"}}