KASAN: use-after-free Read in ext4_get_inode_usage

Status: upstream: reported C repro on 2026/07/09 15:06
Reported-by: syzbot+8ead15b36880a885868b@syzkaller.appspotmail.com
First crash: 25d, last: 15d
Similar bugs (3)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
android-5-15 KASAN: slab-out-of-bounds Read in ext4_get_inode_usage origin:upstream 19 syz, C 11 23d 78d 0/2 upstream: reported C repro on 2026/05/16 23:51
linux-5.15 KASAN: use-after-free Read in ext4_get_inode_usage origin:upstream 19 syz, C 2 29d 78d 0/3 upstream: reported C repro on 2026/05/17 01:53
android-5-10 KASAN: use-after-free Read in ext4_get_inode_usage 19 syz, C 43 25d 80d 0/2 upstream: reported C repro on 2026/05/15 18:41

Sample crash report:
EXT4-fs: Warning: mounting with an experimental mount option 'dioread_nolock' for blocksize < PAGE_SIZE
[EXT4 FS bs=1024, gc=1, bpg=131072, ipg=32, mo=e855c01c, mo2=0003]
System zones: 0-1, 3-36
EXT4-fs (loop2): mounted filesystem without journal. Quota mode: writeback.
==================================================================
BUG: KASAN: use-after-free in ext4_get_inode_usage+0x39c/0x520 fs/ext4/xattr.c:821
Read of size 4 at addr ffff888114c81070 by task syz.2.17/376

CPU: 1 PID: 376 Comm: syz.2.17 Not tainted syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/09/2026
Call Trace:
 <TASK>
 __dump_stack+0x21/0x24 lib/dump_stack.c:88
 dump_stack_lvl+0x110/0x170 lib/dump_stack.c:106
 print_address_description+0x71/0x200 mm/kasan/report.c:316
 print_report+0x4a/0x60 mm/kasan/report.c:420
 kasan_report+0x122/0x150 mm/kasan/report.c:524
 __asan_report_load4_noabort+0x14/0x20 mm/kasan/report_generic.c:350
 ext4_get_inode_usage+0x39c/0x520 fs/ext4/xattr.c:821
 __dquot_transfer+0x1a0/0x2370 fs/quota/dquot.c:2015
 dquot_transfer+0x620/0x7d0 fs/quota/dquot.c:2174
 ext4_setattr+0xa01/0x1c80 fs/ext4/inode.c:5529
 notify_change+0xd33/0x1030 fs/attr.c:499
 chown_common+0x448/0x5f0 fs/open.c:737
 vfs_fchown fs/open.c:805 [inline]
 ksys_fchown+0xef/0x160 fs/open.c:816
 __do_sys_fchown fs/open.c:824 [inline]
 __se_sys_fchown fs/open.c:822 [inline]
 __x64_sys_fchown+0x7a/0x90 fs/open.c:822
 x64_sys_call+0x132/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:94
 do_syscall_x64 arch/x86/entry/common.c:46 [inline]
 do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76
 entry_SYSCALL_64_after_hwframe+0x68/0xd2
RIP: 0033:0x7f8193d9de99
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f8194d34028 EFLAGS: 00000246 ORIG_RAX: 000000000000005d
RAX: ffffffffffffffda RBX: 00007f8194025fa0 RCX: 00007f8193d9de99
RDX: 000000000000ee01 RSI: 0000000000000000 RDI: 0000000000000005
RBP: 00007f8193e33eaf R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007f8194026038 R14: 00007f8194025fa0 R15: 00007ffda376b968
 </TASK>

Allocated by task 371:
 kasan_save_stack mm/kasan/common.c:46 [inline]
 kasan_set_track+0x4b/0x70 mm/kasan/common.c:53
 kasan_save_alloc_info+0x1f/0x30 mm/kasan/generic.c:505
 __kasan_slab_alloc+0x72/0x80 mm/kasan/common.c:334
 kasan_slab_alloc include/linux/kasan.h:202 [inline]
 slab_post_alloc_hook+0x4f/0x2d0 mm/slab.h:768
 slab_alloc_node mm/slub.c:3382 [inline]
 kmem_cache_alloc_node+0x179/0x330 mm/slub.c:3429
 __alloc_skb+0xe8/0x4a0 net/core/skbuff.c:508
 alloc_skb include/linux/skbuff.h:1322 [inline]
 netlink_alloc_large_skb net/netlink/af_netlink.c:1183 [inline]
 netlink_sendmsg+0x635/0xbd0 net/netlink/af_netlink.c:1848
 sock_sendmsg_nosec net/socket.c:716 [inline]
 __sock_sendmsg net/socket.c:728 [inline]
 __sys_sendto+0x4ac/0x660 net/socket.c:2142
 __do_sys_sendto net/socket.c:2154 [inline]
 __se_sys_sendto net/socket.c:2150 [inline]
 __x64_sys_sendto+0xe5/0x100 net/socket.c:2150
 x64_sys_call+0x83/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:45
 do_syscall_x64 arch/x86/entry/common.c:46 [inline]
 do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76
 entry_SYSCALL_64_after_hwframe+0x68/0xd2

Freed by task 371:
 kasan_save_stack mm/kasan/common.c:46 [inline]
 kasan_set_track+0x4b/0x70 mm/kasan/common.c:53
 kasan_save_free_info+0x2b/0x40 mm/kasan/generic.c:516
 ____kasan_slab_free+0x132/0x180 mm/kasan/common.c:242
 __kasan_slab_free+0x11/0x20 mm/kasan/common.c:250
 kasan_slab_free include/linux/kasan.h:178 [inline]
 slab_free_hook mm/slub.c:1750 [inline]
 slab_free_freelist_hook+0xc2/0x190 mm/slub.c:1776
 slab_free mm/slub.c:3712 [inline]
 kmem_cache_free+0x12d/0x300 mm/slub.c:3737
 kfree_skbmem+0x10c/0x180 net/core/skbuff.c:-1
 __kfree_skb net/core/skbuff.c:874 [inline]
 consume_skb+0xb3/0x1f0 net/core/skbuff.c:1038
 netlink_unicast_kernel net/netlink/af_netlink.c:1320 [inline]
 netlink_unicast+0x8c9/0xa60 net/netlink/af_netlink.c:1345
 netlink_sendmsg+0x8b9/0xbd0 net/netlink/af_netlink.c:1873
 sock_sendmsg_nosec net/socket.c:716 [inline]
 __sock_sendmsg net/socket.c:728 [inline]
 __sys_sendto+0x4ac/0x660 net/socket.c:2142
 __do_sys_sendto net/socket.c:2154 [inline]
 __se_sys_sendto net/socket.c:2150 [inline]
 __x64_sys_sendto+0xe5/0x100 net/socket.c:2150
 x64_sys_call+0x83/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:45
 do_syscall_x64 arch/x86/entry/common.c:46 [inline]
 do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76
 entry_SYSCALL_64_after_hwframe+0x68/0xd2

The buggy address belongs to the object at ffff888114c81000
 which belongs to the cache skbuff_head_cache of size 256
The buggy address is located 112 bytes inside of
 256-byte region [ffff888114c81000, ffff888114c81100)

The buggy address belongs to the physical page:
page:ffffea0004532040 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x114c81
flags: 0x4000000000000200(slab|zone=1)
raw: 4000000000000200 ffffea0004531fc0 dead000000000005 ffff88810885c480
raw: 0000000000000000 00000000000c000c 00000001ffffffff 0000000000000000
page dumped because: kasan: bad access detected
page_owner tracks the page as allocated
page last allocated via order 0, migratetype Unmovable, gfp_mask 0x12cc0(GFP_KERNEL|__GFP_NOWARN|__GFP_NORETRY), pid 111, tgid 111 (udevadm), ts 6078239367, free_ts 0
 set_page_owner include/linux/page_owner.h:33 [inline]
 post_alloc_hook+0x1f5/0x210 mm/page_alloc.c:2672
 prep_new_page+0x1c/0x110 mm/page_alloc.c:2679
 get_page_from_freelist+0x2ca9/0x2d20 mm/page_alloc.c:4586
 __alloc_pages+0x1fa/0x610 mm/page_alloc.c:5930
 alloc_slab_page+0x6e/0xf0 include/linux/gfp.h:-1
 allocate_slab mm/slub.c:1967 [inline]
 new_slab+0x98/0x3e0 mm/slub.c:2020
 ___slab_alloc+0x70f/0xb70 mm/slub.c:3177
 __slab_alloc+0x5e/0xa0 mm/slub.c:3263
 slab_alloc_node mm/slub.c:3348 [inline]
 kmem_cache_alloc_node+0x1ba/0x330 mm/slub.c:3429
 __alloc_skb+0xe8/0x4a0 net/core/skbuff.c:508
 alloc_skb include/linux/skbuff.h:1322 [inline]
 alloc_uevent_skb+0x85/0x240 lib/kobject_uevent.c:290
 uevent_net_broadcast_untagged lib/kobject_uevent.c:326 [inline]
 kobject_uevent_net_broadcast+0x343/0x5b0 lib/kobject_uevent.c:409
 kobject_uevent_env+0x541/0x720 lib/kobject_uevent.c:608
 kobject_synth_uevent+0x457/0x940 lib/kobject_uevent.c:208
 uevent_store+0x25/0x70 drivers/base/core.c:2690
 dev_attr_store+0x6c/0x90 drivers/base/core.c:2389
page_owner free stack trace missing

Memory state around the buggy address:
 ffff888114c80f00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
 ffff888114c80f80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
>ffff888114c81000: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
                                                             ^
 ffff888114c81080: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
 ffff888114c81100: fc fc fc fc fc fc fc fc fa fb fb fb fb fb fb fb
==================================================================

Crashes (12):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2026/07/19 09:00 android14-6.1 c7e15f0bdc49 72524a66 .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro #1 (corrupt fs)] [mounted in repro #2 (corrupt fs)] ci2-android-6-1 KASAN: use-after-free Read in ext4_get_inode_usage
2026/07/19 06:13 android14-6.1 c7e15f0bdc49 72524a66 .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro #1 (corrupt fs)] [mounted in repro #2 (corrupt fs)] ci2-android-6-1 KASAN: use-after-free Read in ext4_get_inode_usage
2026/07/18 19:33 android14-6.1 c7e15f0bdc49 72524a66 .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro #1 (corrupt fs)] [mounted in repro #2 (corrupt fs)] ci2-android-6-1 KASAN: use-after-free Read in ext4_get_inode_usage
2026/07/18 18:37 android14-6.1 c7e15f0bdc49 72524a66 .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro #1 (corrupt fs)] [mounted in repro #2 (corrupt fs)] ci2-android-6-1 KASAN: use-after-free Read in ext4_get_inode_usage
2026/07/18 18:10 android14-6.1 c7e15f0bdc49 72524a66 .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro #1 (corrupt fs)] [mounted in repro #2 (corrupt fs)] ci2-android-6-1 KASAN: use-after-free Read in ext4_get_inode_usage
2026/07/09 16:29 android14-6.1 52939c41021c a0c310a3 .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro (clean fs)] ci2-android-6-1 KASAN: use-after-free Read in ext4_get_inode_usage
2026/07/09 15:48 android14-6.1 52939c41021c a0c310a3 .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro (clean fs)] ci2-android-6-1 KASAN: use-after-free Read in ext4_get_inode_usage
2026/07/09 14:59 android14-6.1 52939c41021c a0c310a3 .config console log report syz / log C [disk image] [vmlinux] [kernel image] [mounted in repro (clean fs)] ci2-android-6-1 KASAN: use-after-free Read in ext4_get_inode_usage
2026/07/19 06:35 android14-6.1 c7e15f0bdc49 72524a66 .config console log report syz / log [disk image] [vmlinux] [kernel image] [mounted in repro #1 (corrupt fs)] [mounted in repro #2 (corrupt fs)] ci2-android-6-1 KASAN: use-after-free Read in ext4_get_inode_usage
2026/07/18 23:24 android14-6.1 c7e15f0bdc49 72524a66 .config console log report syz / log [disk image] [vmlinux] [kernel image] [mounted in repro #1 (corrupt fs)] [mounted in repro #2 (corrupt fs)] ci2-android-6-1 KASAN: use-after-free Read in ext4_get_inode_usage
2026/07/18 17:43 android14-6.1 c7e15f0bdc49 72524a66 .config console log report syz / log [disk image] [vmlinux] [kernel image] [mounted in repro #1 (corrupt fs)] [mounted in repro #2 (corrupt fs)] ci2-android-6-1 KASAN: use-after-free Read in ext4_get_inode_usage
2026/07/09 14:16 android14-6.1 52939c41021c a0c310a3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-android-6-1 KASAN: use-after-free Read in ext4_get_inode_usage
* Struck through repros no longer work on HEAD.