ext4: fix off-by-one error in do_split

Summary

CVECVE-2025-23150
StatePUBLISHED
AssignerLinux
Source PriorityCVE Program / NVD first with legacy fallback
Published2025-05-01 13:15:50 UTC
Updated2026-07-30 06:22:16 UTC
DescriptionIn the Linux kernel, the following vulnerability has been resolved: ext4: fix off-by-one error in do_split Syzkaller detected a use-after-free issue in ext4_insert_dentry that was caused by out-of-bounds access due to incorrect splitting in do_split. BUG: KASAN: use-after-free in ext4_insert_dentry+0x36a/0x6d0 fs/ext4/namei.c:2109 Write of size 251 at addr ffff888074572f14 by task syz-executor335/5847 CPU: 0 UID: 0 PID: 5847 Comm: syz-executor335 Not tainted 6.12.0-rc6-syzkaller-00318-ga9cda7c0ffed #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/30/2024 Call Trace: <TASK> __dump_stack lib/dump_stack.c:94 [inline] dump_stack_lvl+0x241/0x360 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:377 [inline] print_report+0x169/0x550 mm/kasan/report.c:488 kasan_report+0x143/0x180 mm/kasan/report.c:601 kasan_check_range+0x282/0x290 mm/kasan/generic.c:189 __asan_memcpy+0x40/0x70 mm/kasan/shadow.c:106 ext4_insert_dentry+0x36a/0x6d0 fs/ext4/namei.c:2109 add_dirent_to_buf+0x3d9/0x750 fs/ext4/namei.c:2154 make_indexed_dir+0xf98/0x1600 fs/ext4/namei.c:2351 ext4_add_entry+0x222a/0x25d0 fs/ext4/namei.c:2455 ext4_add_nondir+0x8d/0x290 fs/ext4/namei.c:2796 ext4_symlink+0x920/0xb50 fs/ext4/namei.c:3431 vfs_symlink+0x137/0x2e0 fs/namei.c:4615 do_symlinkat+0x222/0x3a0 fs/namei.c:4641 __do_sys_symlink fs/namei.c:4662 [inline] __se_sys_symlink fs/namei.c:4660 [inline] __x64_sys_symlink+0x7a/0x90 fs/namei.c:4660 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xf3/0x230 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x77/0x7f </TASK> The following loop is located right above 'if' statement. for (i = count-1; i >= 0; i--) { /* is more than half of this entry in 2nd half of the block? */ if (size + map[i].size/2 > blocksize/2) break; size += map[i].size; move++; } 'i' in this case could go down to -1, in which case sum of active entries wouldn't exceed half the block size, but previous behaviour would also do split in half if sum would exceed at the very last block, which in case of having too many long name files in a single block could lead to out-of-bounds access and following use-after-free. Found by Linux Verification Center (linuxtesting.org) with Syzkaller.

Risk And Classification

Primary CVSS: v3.1 5.5 MEDIUM from [email protected]

CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H

Problem Types: CWE-193


VersionSourceTypeScoreSeverityVector
3.1[email protected]Primary5.5MEDIUMCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
3.1416baaa9-dc9f-4396-8d5f-8c081fb06d67Secondary7.8HIGHCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
3.1CNADECLARED7.8HIGHCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

CVSS v3.1 Breakdown

Attack Vector
Local
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
None
Availability
High

CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H

NVD Known Affected Configurations (CPE 2.3)

TypeVendorProductVersionUpdateEditionLanguage
Operating System Linux Linux Kernel All All All All

Vendor Declared Affected Products

SourceVendorProductVersionPlatforms
CNA Linux Linux affected ea54176e5821936d109bb45dc2c19bd53559e735 b96bd2c3db26ad0daec5b78c85c098b53900e2e1 git Not specified
CNA Linux Linux affected 5872331b3d91820e14716632ebb56b1399b34fe1 515c34cff899eb5dae6aa7eee01c1295b07d81af git Not specified
CNA Linux Linux affected 5872331b3d91820e14716632ebb56b1399b34fe1 2883e9e74f73f9265e5f8d1aaaa89034b308e433 git Not specified
CNA Linux Linux affected 5872331b3d91820e14716632ebb56b1399b34fe1 35d0aa6db9d93307085871ceab8a729594a98162 git Not specified
CNA Linux Linux affected 5872331b3d91820e14716632ebb56b1399b34fe1 2eeb1085bf7bd5c7ba796ca4119925fa5d336a3f git Not specified
CNA Linux Linux affected 5872331b3d91820e14716632ebb56b1399b34fe1 16d9067f00e3a7d1df7c3aa9c20d214923d27e10 git Not specified
CNA Linux Linux affected 5872331b3d91820e14716632ebb56b1399b34fe1 17df39f455f1289319d4d09e4826aa46852ffd17 git Not specified
CNA Linux Linux affected 5872331b3d91820e14716632ebb56b1399b34fe1 ab0cc5c25552ae0d20eae94b40a93be11b080fc5 git Not specified
CNA Linux Linux affected 5872331b3d91820e14716632ebb56b1399b34fe1 94824ac9a8aaf2fb3c54b4bdde842db80ffa555d git Not specified
CNA Linux Linux affected 059b1480105478c5f68cf664301545b8cad6a7cf git Not specified
CNA Linux Linux affected 539ae3e03875dacaa9c388aff141ccbb4ef4ecb5 git Not specified
CNA Linux Linux affected fbbfd55a40d5d0806b59ee0403c75d5ac517533f git Not specified
CNA Linux Linux affected b3ddf6ba5e28a57729fff1605ae08e21be5c92e3 git Not specified
CNA Linux Linux affected e50fe43e3062e18846e99d9646b9c07b097eb1ed git Not specified
CNA Linux Linux affected 88e79f7a9841278fa8ff7ff6178bad12da002ffc git Not specified
CNA Linux Linux affected 5.4.61 5.4.293 semver Not specified
CNA Linux Linux affected 4.4.234 4.5 semver Not specified
CNA Linux Linux affected 4.9.234 4.10 semver Not specified
CNA Linux Linux affected 4.14.195 4.15 semver Not specified
CNA Linux Linux affected 4.19.142 4.20 semver Not specified
CNA Linux Linux affected 5.7.18 5.8 semver Not specified
CNA Linux Linux affected 5.8.4 5.9 semver Not specified
CNA Linux Linux affected 5.9 Not specified
CNA Linux Linux unaffected 5.9 semver Not specified
CNA Linux Linux unaffected 5.4.293 5.4.* semver Not specified
CNA Linux Linux unaffected 5.10.237 5.10.* semver Not specified
CNA Linux Linux unaffected 5.15.181 5.15.* semver Not specified
CNA Linux Linux unaffected 6.1.135 6.1.* semver Not specified
CNA Linux Linux unaffected 6.6.88 6.6.* semver Not specified
CNA Linux Linux unaffected 6.12.24 6.12.* semver Not specified
CNA Linux Linux unaffected 6.13.12 6.13.* semver Not specified
CNA Linux Linux unaffected 6.14.3 6.14.* semver Not specified
CNA Linux Linux unaffected 6.15 * original_commit_for_fix Not specified

References

ReferenceSourceLinkTags
lists.debian.org/debian-lts-announce/2025/05/msg00030.html af854a3a-2127-422b-91ae-364da2661108 lists.debian.org Mailing List
git.kernel.org/stable/c/17df39f455f1289319d4d09e4826aa46852ffd17 416baaa9-dc9f-4396-8d5f-8c081fb06d67 git.kernel.org Patch
git.kernel.org/stable/c/2883e9e74f73f9265e5f8d1aaaa89034b308e433 416baaa9-dc9f-4396-8d5f-8c081fb06d67 git.kernel.org Patch
git.kernel.org/stable/c/35d0aa6db9d93307085871ceab8a729594a98162 416baaa9-dc9f-4396-8d5f-8c081fb06d67 git.kernel.org Patch
git.kernel.org/stable/c/94824ac9a8aaf2fb3c54b4bdde842db80ffa555d 416baaa9-dc9f-4396-8d5f-8c081fb06d67 git.kernel.org Patch
git.kernel.org/stable/c/ab0cc5c25552ae0d20eae94b40a93be11b080fc5 416baaa9-dc9f-4396-8d5f-8c081fb06d67 git.kernel.org Patch
git.kernel.org/stable/c/515c34cff899eb5dae6aa7eee01c1295b07d81af 416baaa9-dc9f-4396-8d5f-8c081fb06d67 git.kernel.org Patch
git.kernel.org/stable/c/2eeb1085bf7bd5c7ba796ca4119925fa5d336a3f 416baaa9-dc9f-4396-8d5f-8c081fb06d67 git.kernel.org Patch
lists.debian.org/debian-lts-announce/2025/05/msg00045.html af854a3a-2127-422b-91ae-364da2661108 lists.debian.org Mailing List
git.kernel.org/stable/c/16d9067f00e3a7d1df7c3aa9c20d214923d27e10 416baaa9-dc9f-4396-8d5f-8c081fb06d67 git.kernel.org Patch
git.kernel.org/stable/c/b96bd2c3db26ad0daec5b78c85c098b53900e2e1 416baaa9-dc9f-4396-8d5f-8c081fb06d67 git.kernel.org Patch
CVE Program record CVE.ORG www.cve.org canonical
NVD vulnerability detail NVD nvd.nist.gov canonical, analysis

© CVE.report 2026

Use of this information constitutes acceptance for use in an AS IS condition. There are NO warranties, implied or otherwise, with regard to this information or its use. Any use of this information is at the user's risk. It is the responsibility of user to evaluate the accuracy, completeness or usefulness of any information, opinion, advice or other content. EACH USER WILL BE SOLELY RESPONSIBLE FOR ANY consequences of his or her direct or indirect use of this web site. ALL WARRANTIES OF ANY KIND ARE EXPRESSLY DISCLAIMED. This site will NOT BE LIABLE FOR ANY DIRECT, INDIRECT or any other kind of loss.

CVE, CWE, and OVAL are registred trademarks of The MITRE Corporation and the authoritative source of CVE content is MITRE's CVE web site. This site includes MITRE data granted under the following license.

Free CVE JSON API cve.report/api

CVE.report and Source URL Uptime Status status.cve.report