================================================================== BUG: KASAN: slab-out-of-bounds in ext4_htree_store_dirent+0x198/0x5c0 fs/ext4/dir.c:494 Read of size 255 at addr ffff888112b8da69 by task syz-executor/462 CPU: 1 PID: 462 Comm: syz-executor Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/12/2025 Call Trace: __dump_stack+0x21/0x30 lib/dump_stack.c:88 dump_stack_lvl+0xee/0x150 lib/dump_stack.c:106 print_address_description+0x7f/0x2c0 mm/kasan/report.c:248 __kasan_report mm/kasan/report.c:427 [inline] kasan_report+0xf1/0x140 mm/kasan/report.c:444 check_region_inline mm/kasan/generic.c:-1 [inline] kasan_check_range+0x280/0x290 mm/kasan/generic.c:189 memcpy+0x2d/0x70 mm/kasan/shadow.c:65 ext4_htree_store_dirent+0x198/0x5c0 fs/ext4/dir.c:494 ext4_htree_fill_tree+0x6cd/0x10d0 fs/ext4/namei.c:1247 ext4_dx_readdir fs/ext4/dir.c:609 [inline] ext4_readdir+0x2bfd/0x3a40 fs/ext4/dir.c:145 iterate_dir+0x260/0x600 fs/readdir.c:-1 __do_sys_getdents64 fs/readdir.c:369 [inline] __se_sys_getdents64+0xe5/0x240 fs/readdir.c:354 __x64_sys_getdents64+0x7b/0x90 fs/readdir.c:354 x64_sys_call+0x592/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:218 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x66/0xd0 RIP: 0033:0x7f0b212d6693 Code: c1 66 0f 1f 44 00 00 48 83 c4 08 48 89 ef 5b 5d e9 82 3e f8 ff 66 90 b8 ff ff ff 7f 48 39 c2 48 0f 47 d0 b8 d9 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 05 c3 0f 1f 40 00 48 c7 c2 a8 ff ff ff f7 d8 RSP: 002b:00007ffd516038f8 EFLAGS: 00000293 ORIG_RAX: 00000000000000d9 RAX: ffffffffffffffda RBX: 000055558b49e4e0 RCX: 00007f0b212d6693 RDX: 0000000000008000 RSI: 000055558b49e4e0 RDI: 0000000000000005 RBP: 000055558b49e4b4 R08: 0000000000028b61 R09: 0000000000000000 R10: 00007f0b21469ca0 R11: 0000000000000293 R12: ffffffffffffffa8 R13: 0000000000000010 R14: 000055558b49e4b0 R15: 0000000000000001 Allocated by task 329: kasan_save_stack mm/kasan/common.c:38 [inline] kasan_set_track mm/kasan/common.c:45 [inline] set_alloc_info mm/kasan/common.c:433 [inline] __kasan_slab_alloc+0xbd/0xf0 mm/kasan/common.c:466 kasan_slab_alloc include/linux/kasan.h:217 [inline] slab_post_alloc_hook+0x4f/0x2b0 mm/slab.h:550 slab_alloc_node mm/slub.c:3245 [inline] slab_alloc mm/slub.c:3255 [inline] kmem_cache_alloc+0xf7/0x260 mm/slub.c:3260 dst_alloc+0x15c/0x1d0 net/core/dst.c:92 ip6_dst_alloc net/ipv6/route.c:342 [inline] icmp6_dst_alloc+0xf5/0x560 net/ipv6/route.c:3280 mld_sendpack+0x4c0/0xb40 net/ipv6/mcast.c:1814 mld_send_cr net/ipv6/mcast.c:2126 [inline] mld_ifc_work+0x80c/0xbe0 net/ipv6/mcast.c:2658 process_one_work+0x6be/0xba0 kernel/workqueue.c:2325 worker_thread+0xa59/0x1200 kernel/workqueue.c:2472 kthread+0x411/0x500 kernel/kthread.c:337 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287 Last potentially related work creation: kasan_save_stack+0x3a/0x60 mm/kasan/common.c:38 __kasan_record_aux_stack+0xd2/0x100 mm/kasan/generic.c:348 kasan_record_aux_stack_noalloc+0xb/0x10 mm/kasan/generic.c:358 __call_rcu_common kernel/rcu/tree.c:3011 [inline] call_rcu+0x105/0xfe0 kernel/rcu/tree.c:3129 call_rcu_hurry include/linux/rcupdate.h:89 [inline] dst_release+0x123/0x190 net/core/dst.c:181 refdst_drop include/net/dst.h:255 [inline] skb_dst_drop include/net/dst.h:267 [inline] __dev_queue_xmit+0x7b3/0x2d80 net/core/dev.c:4252 dev_queue_xmit+0x17/0x20 net/core/dev.c:4329 neigh_hh_output include/net/neighbour.h:501 [inline] neigh_output include/net/neighbour.h:515 [inline] ip6_finish_output2+0x1080/0x1760 net/ipv6/ip6_output.c:130 __ip6_finish_output+0x61e/0x7d0 net/ipv6/ip6_output.c:201 ip6_finish_output+0x31/0x240 net/ipv6/ip6_output.c:211 NF_HOOK_COND include/linux/netfilter.h:294 [inline] ip6_output+0x1d1/0x3b0 net/ipv6/ip6_output.c:234 dst_output include/net/dst.h:453 [inline] NF_HOOK include/linux/netfilter.h:305 [inline] mld_sendpack+0x676/0xb40 net/ipv6/mcast.c:1825 mld_send_cr net/ipv6/mcast.c:2126 [inline] mld_ifc_work+0x80c/0xbe0 net/ipv6/mcast.c:2658 process_one_work+0x6be/0xba0 kernel/workqueue.c:2325 worker_thread+0xa59/0x1200 kernel/workqueue.c:2472 kthread+0x411/0x500 kernel/kthread.c:337 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287 The buggy address belongs to the object at ffff888112b8da00 which belongs to the cache ip6_dst_cache of size 240 The buggy address is located 105 bytes inside of 240-byte region [ffff888112b8da00, ffff888112b8daf0) The buggy address belongs to the page: page:ffffea00044ae340 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x112b8d flags: 0x4000000000000200(slab|zone=1) raw: 4000000000000200 0000000000000000 dead000000000122 ffff8881003c9c80 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 0x112a20(GFP_ATOMIC|__GFP_NOWARN|__GFP_NORETRY|__GFP_HARDWALL), pid 329, ts 49508478845, free_ts 48597793789 set_page_owner include/linux/page_owner.h:33 [inline] post_alloc_hook+0x192/0x1b0 mm/page_alloc.c:2605 prep_new_page+0x1c/0x110 mm/page_alloc.c:2611 get_page_from_freelist+0x2cc5/0x2d50 mm/page_alloc.c:4485 __alloc_pages+0x18f/0x440 mm/page_alloc.c:5808 alloc_slab_page mm/slub.c:-1 [inline] allocate_slab mm/slub.c:1937 [inline] new_slab+0xa1/0x4d0 mm/slub.c:2000 ___slab_alloc+0x381/0x810 mm/slub.c:3033 __slab_alloc+0x49/0x90 mm/slub.c:3120 slab_alloc_node mm/slub.c:3211 [inline] slab_alloc mm/slub.c:3255 [inline] kmem_cache_alloc+0x138/0x260 mm/slub.c:3260 dst_alloc+0x15c/0x1d0 net/core/dst.c:92 ip6_dst_alloc net/ipv6/route.c:342 [inline] ip6_rt_pcpu_alloc net/ipv6/route.c:1375 [inline] rt6_make_pcpu_route net/ipv6/route.c:1424 [inline] ip6_pol_route+0x960/0x1110 net/ipv6/route.c:2262 ip6_pol_route_input+0x56/0x80 net/ipv6/route.c:2283 pol_lookup_func include/net/ip6_fib.h:592 [inline] fib6_rule_lookup+0x1c6/0x560 net/ipv6/fib6_rules.c:115 ip6_route_input_lookup net/ipv6/route.c:2295 [inline] ip6_route_input+0x591/0x820 net/ipv6/route.c:2591 ip6_rcv_finish_core net/ipv6/ip6_input.c:66 [inline] ip6_rcv_finish+0x156/0x360 net/ipv6/ip6_input.c:77 NF_HOOK include/linux/netfilter.h:305 [inline] ipv6_rcv+0xe9/0x210 net/ipv6/ip6_input.c:300 __netif_receive_skb_one_core net/core/dev.c:5533 [inline] __netif_receive_skb+0xc8/0x280 net/core/dev.c:5647 page last free stack trace: reset_page_owner include/linux/page_owner.h:26 [inline] free_pages_prepare mm/page_alloc.c:1472 [inline] free_pcp_prepare mm/page_alloc.c:1544 [inline] free_unref_page_prepare+0x542/0x550 mm/page_alloc.c:3534 free_unref_page+0xa2/0x550 mm/page_alloc.c:3616 free_the_page mm/page_alloc.c:805 [inline] __free_pages+0x6c/0x100 mm/page_alloc.c:5884 __vunmap+0x84d/0x9e0 mm/vmalloc.c:2660 __vfree mm/vmalloc.c:2709 [inline] vfree+0x8b/0xc0 mm/vmalloc.c:2740 kcov_put kernel/kcov.c:417 [inline] kcov_close+0x2b/0x50 kernel/kcov.c:519 __fput+0x20b/0x8b0 fs/file_table.c:311 ____fput+0x15/0x20 fs/file_table.c:339 task_work_run+0x127/0x190 kernel/task_work.c:188 exit_task_work include/linux/task_work.h:33 [inline] do_exit+0xa7e/0x27a0 kernel/exit.c:889 do_group_exit+0x141/0x310 kernel/exit.c:1003 get_signal+0x66a/0x1480 kernel/signal.c:2907 arch_do_signal_or_restart+0xc1/0x10f0 arch/x86/kernel/signal.c:867 handle_signal_work kernel/entry/common.c:154 [inline] exit_to_user_mode_loop+0xa7/0xe0 kernel/entry/common.c:178 exit_to_user_mode_prepare+0x5a/0xa0 kernel/entry/common.c:214 __syscall_exit_to_user_mode_work kernel/entry/common.c:296 [inline] syscall_exit_to_user_mode+0x1a/0x30 kernel/entry/common.c:307 Memory state around the buggy address: ffff888112b8d980: fb fb fb fb fb fb fc fc fc fc fc fc fc fc fc fc ffff888112b8da00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff888112b8da80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc fc ^ ffff888112b8db00: fc fc fc fc fc fc fc fc 00 00 00 00 00 00 00 00 ffff888112b8db80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ==================================================================