erofs: handle NONHEAD !delta[1] lclusters gracefully
In the Linux kernel, the following vulnerability has been resolved: erofs: handle NONHEAD !delta[1] lclusters gracefully syzbot reported a WARNING in iomap_iter_done: iomap_fiemap+0x73b/0x9b0 fs/iomap/fiemap.c:80 ioctl_fiemap fs/ioctl.c:220 [inline] Generally, NONHEAD lclusters won't have delta[1]==0, except for crafted images and filesystems created by pre-1.0 mkfs versions. Previously, it would immediately bail out if delta[1]==0, which led to inadequate decompressed lengths (thus FIEMAP is impacted). Treat it as delta[1]=1 to work around these legacy mkfs versions. `lclusterbits > 14` is illegal for compact indexes, error out too.
02 / AFFECTED SOFTWARE
Affected packages
1096 explicit affected versions
03 / CONNECTIONS
Connected vulnerabilities
04 / EVIDENCE
Source records
In the Linux kernel, the following vulnerability has been resolved: erofs: handle NONHEAD !delta[1] lclusters gracefully syzbot reported a WARNING in iomap_iter_done: iomap_fiemap+0x73b/0x9b0 fs/iomap/fiemap.c:80 ioctl_fiemap fs/ioctl.c:220 [inline] Generally, NONHEAD lclusters won't have delta[1]==0, except for crafted images and filesystems created by pre-1.0 mkfs versions. Previously, it would immediately bail out if delta[1]==0, which led to inadequate decompressed lengths (thus FIEMAP is impacted). Treat it as delta[1]=1 to work around these legacy mkfs versions. `lclusterbits > 14` is illegal for compact indexes, error out too.
05 / REFERENCES
Further evidence
- https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
- https://git.kernel.org/stable/c/0bc8061ffc733a0a246b8689b2d32a3e9204f43c
- https://git.kernel.org/stable/c/480c6c7b55aeacac800bc2a0d321ff53273045e5
- https://git.kernel.org/stable/c/75a0a6dde803e7a3af700da8da9a361b49f69eba
- https://git.kernel.org/stable/c/daaf68fef4b2ff97928227630021d37b27a96655
- https://git.kernel.org/stable/c/f466641debcbea8bdf78d1b63a6270aadf9301bf
- https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/53xxx/CVE-2024-53234.json
- https://lists.debian.org/debian-lts-announce/2025/03/msg00001.html
- https://nvd.nist.gov/vuln/detail/CVE-2024-53234