EXT4-fs (loop3): mounted filesystem 00000[ 168.325205][ T6653] EXT4-fs (loop3): mounted filesystem 00000000-0000-0000-0000-000000000000 r/w without journal. Quota mode: none. EXT4-fs warning (device loop3): dx_probe:801: inode #2: comm syz.3.23: Unrecognised inode hash code 4 EXT4-fs warning (device loop3): dx_probe:934: inode #2: comm syz.3.23: Corrupt directory, running e2fsck is recommended ================================================================== BUG: KASAN: slab-use-after-free in __ext4_check_dir_entry+0x708/0x8a0 fs/ext4/dir.c:85 Read of size 2 at addr ffff88803276a003 by task syz.3.23/6653 CPU: 0 UID: 0 PID: 6653 Comm: syz.3.23 Not tainted syzkaller #0 PREEMPT_{RT,(full)} Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/25/2025 Call Trace: dump_stack_lvl+0x189/0x250 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:378 [inline] print_report+0xca/0x240 mm/kasan/report.c:482 kasan_report+0x118/0x150 mm/kasan/report.c:595 __ext4_check_dir_entry+0x708/0x8a0 fs/ext4/dir.c:85 ext4_readdir+0x12a2/0x3b70 fs/ext4/dir.c:262 iterate_dir+0x3a5/0x580 fs/readdir.c:108 __do_sys_getdents64 fs/readdir.c:410 [inline] __se_sys_getdents64+0xe4/0x260 fs/readdir.c:396 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xfa/0xf80 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f7727b1e929 Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 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 a8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f7726d8e038 EFLAGS: 00000246 ORIG_RAX: 00000000000000d9 RAX: ffffffffffffffda RBX: 00007f7727d45fa0 RCX: 00007f7727b1e929 RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000006 RBP: 00007f7727ba0b39 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 0000000000000000 R14: 00007f7727d45fa0 R15: 00007ffd6873d2e8 Allocated by task 6601: kasan_save_stack mm/kasan/common.c:56 [inline] kasan_save_track+0x3e/0x80 mm/kasan/common.c:77 poison_kmalloc_redzone mm/kasan/common.c:400 [inline] __kasan_kmalloc+0x93/0xb0 mm/kasan/common.c:417 kasan_kmalloc include/linux/kasan.h:262 [inline] __kmalloc_cache_noprof+0x1ef/0x6c0 mm/slub.c:5771 kmalloc_noprof include/linux/slab.h:957 [inline] slab_free_hook mm/slub.c:2495 [inline] slab_free mm/slub.c:6642 [inline] kmem_cache_free+0x165/0x8f0 mm/slub.c:6752 exit_mmap+0x532/0xb20 mm/mmap.c:1305 __mmput+0xcb/0x3d0 kernel/fork.c:1133 exec_mmap+0x680/0x7a0 fs/exec.c:901 begin_new_exec+0x1359/0x2400 fs/exec.c:1156 load_elf_binary+0x9a1/0x2750 fs/binfmt_elf.c:1010 search_binary_handler fs/exec.c:1669 [inline] exec_binprm fs/exec.c:1701 [inline] bprm_execve+0x99c/0x1430 fs/exec.c:1753 do_execveat_common+0x510/0x6a0 fs/exec.c:1859 do_execve fs/exec.c:1933 [inline] __do_sys_execve fs/exec.c:2009 [inline] __se_sys_execve fs/exec.c:2004 [inline] __x64_sys_execve+0x94/0xb0 fs/exec.c:2004 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xfa/0xf80 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f Freed by task 20: kasan_save_stack mm/kasan/common.c:56 [inline] kasan_save_track+0x3e/0x80 mm/kasan/common.c:77 __kasan_save_free_info+0x46/0x50 mm/kasan/generic.c:587 kasan_save_free_info mm/kasan/kasan.h:406 [inline] poison_slab_object mm/kasan/common.c:252 [inline] __kasan_slab_free+0x5c/0x80 mm/kasan/common.c:284 kasan_slab_free include/linux/kasan.h:234 [inline] slab_free_hook mm/slub.c:2543 [inline] slab_free mm/slub.c:6642 [inline] kfree+0x18e/0x930 mm/slub.c:6849 slab_free_after_rcu_debug+0x60/0x4e0 mm/slub.c:6687 rcu_do_batch kernel/rcu/tree.c:2605 [inline] rcu_core kernel/rcu/tree.c:2857 [inline] rcu_cpu_kthread+0xc96/0x1c40 kernel/rcu/tree.c:2945 smpboot_thread_fn+0x542/0xa60 kernel/smpboot.c:160 kthread+0x711/0x8a0 kernel/kthread.c:463 ret_from_fork+0x52d/0xa60 arch/x86/kernel/process.c:158 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 Last potentially related work creation: kasan_save_stack+0x3e/0x60 mm/kasan/common.c:56 kasan_record_aux_stack+0xbd/0xd0 mm/kasan/generic.c:559 __call_rcu_common kernel/rcu/tree.c:3119 [inline] call_rcu+0x157/0x9c0 kernel/rcu/tree.c:3239 slab_free_hook mm/slub.c:2507 [inline] slab_free mm/slub.c:6642 [inline] kmem_cache_free+0x71c/0x8f0 mm/slub.c:6752 exit_mmap+0x532/0xb20 mm/mmap.c:1305 __mmput+0xcb/0x3d0 kernel/fork.c:1133 exec_mmap+0x680/0x7a0 fs/exec.c:901 begin_new_exec+0x1359/0x2400 fs/exec.c:1156 load_elf_binary+0x9a1/0x2750 fs/binfmt_elf.c:1010 search_binary_handler fs/exec.c:1669 [inline] exec_binprm fs/exec.c:1701 [inline] bprm_execve+0x99c/0x1430 fs/exec.c:1753 do_execveat_common+0x510/0x6a0 fs/exec.c:1859 do_execve fs/exec.c:1933 [inline] __do_sys_execve fs/exec.c:2009 [inline] __se_sys_execve fs/exec.c:2004 [inline] __x64_sys_execve+0x94/0xb0 fs/exec.c:2004 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xfa/0xf80 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f The buggy address belongs to the object at ffff88803276a000 which belongs to the cache kmalloc-32 of size 32 The buggy address is located 3 bytes inside of freed 32-byte region [ffff88803276a000, ffff88803276a020) The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x3276a flags: 0x80000000000000(node=0|zone=1) page_type: f5(slab) raw: 0080000000000000 ffff88813ff26780 dead000000000100 dead000000000122 raw: 0000000000000000 0000000000400040 00000000f5000000 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 0x52800(GFP_NOWAIT|__GFP_NORETRY|__GFP_COMP), pid 5502, tgid 5502 (dhcpcd-run-hook), ts 52454416426, free_ts 52381705254 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x234/0x290 mm/page_alloc.c:1845 prep_new_page mm/page_alloc.c:1853 [inline] get_page_from_freelist+0x28c0/0x2960 mm/page_alloc.c:3879 __alloc_frozen_pages_noprof+0x181/0x370 mm/page_alloc.c:5178 alloc_pages_mpol+0xd1/0x380 mm/mempolicy.c:2416 alloc_slab_page mm/slub.c:3059 [inline] allocate_slab+0x96/0x350 mm/slub.c:3232 new_slab mm/slub.c:3286 [inline] ___slab_alloc+0xb10/0x1400 mm/slub.c:4655 __slab_alloc+0xc6/0x1f0 mm/slub.c:4778 __slab_alloc_node mm/slub.c:4854 [inline] slab_alloc_node mm/slub.c:5276 [inline] __kmalloc_cache_noprof+0xec/0x6c0 mm/slub.c:5766 kmalloc_noprof include/linux/slab.h:957 [inline] slab_free_hook mm/slub.c:2495 [inline] slab_free mm/slub.c:6642 [inline] kmem_cache_free+0x165/0x8f0 mm/slub.c:6752 anon_vma_free mm/rmap.c:136 [inline] __put_anon_vma+0x12a/0x310 mm/rmap.c:2777 put_anon_vma include/linux/rmap.h:117 [inline] unlink_anon_vmas+0x503/0x670 mm/rmap.c:443 free_pgtables+0x72b/0x9c0 mm/memory.c:414 exit_mmap+0x437/0xb20 mm/mmap.c:1291 __mmput+0xcb/0x3d0 kernel/fork.c:1133 exec_mmap+0x680/0x7a0 fs/exec.c:901 begin_new_exec+0x1359/0x2400 fs/exec.c:1156 page last free pid 20 tgid 20 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] free_pages_prepare mm/page_alloc.c:1394 [inline] __free_frozen_pages+0xfb6/0x1140 mm/page_alloc.c:2901 __tlb_remove_table_free mm/mmu_gather.c:227 [inline] tlb_remove_table_rcu+0x85/0x100 mm/mmu_gather.c:290 rcu_do_batch kernel/rcu/tree.c:2605 [inline] rcu_core kernel/rcu/tree.c:2857 [inline] rcu_cpu_kthread+0xc96/0x1c40 kernel/rcu/tree.c:2945 smpboot_thread_fn+0x542/0xa60 kernel/smpboot.c:160 kthread+0x711/0x8a0 kernel/kthread.c:463 ret_from_fork+0x52d/0xa60 arch/x86/kernel/process.c:158 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 Memory state around the buggy address: ffff888032769f00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888032769f80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff88803276a000: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc ^ ffff88803276a080: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc ffff88803276a100: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc ==================================================================