================================================================== BUG: KASAN: slab-out-of-bounds in ntfs_write_bh+0x6b9/0x6e0 fs/ntfs3/fsntfs.c:1401 Read of size 8 at addr ffff888029d28000 by task syz-executor.2/3291 CPU: 0 PID: 3291 Comm: syz-executor.2 Not tainted 6.6.0-rc3-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 08/04/2023 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0xd9/0x1b0 lib/dump_stack.c:106 print_address_description mm/kasan/report.c:364 [inline] print_report+0xc4/0x620 mm/kasan/report.c:475 kasan_report+0xda/0x110 mm/kasan/report.c:588 ntfs_write_bh+0x6b9/0x6e0 fs/ntfs3/fsntfs.c:1401 mi_write+0xc0/0x1e0 fs/ntfs3/record.c:346 ni_write_inode+0x1025/0x2810 fs/ntfs3/frecord.c:3360 write_inode fs/fs-writeback.c:1456 [inline] __writeback_single_inode+0xa81/0xe70 fs/fs-writeback.c:1668 writeback_single_inode+0x2af/0x590 fs/fs-writeback.c:1724 sync_inode_metadata+0xa5/0xe0 fs/fs-writeback.c:2786 ntfs_set_state+0x3f0/0x6e0 fs/ntfs3/fsntfs.c:995 ntfs_create_inode+0x317/0x4290 fs/ntfs3/inode.c:1307 ntfs_mkdir+0x3c/0x80 fs/ntfs3/namei.c:216 vfs_mkdir+0x532/0x7e0 fs/namei.c:4120 do_mkdirat+0x2a9/0x330 fs/namei.c:4143 __do_sys_mkdirat fs/namei.c:4158 [inline] __se_sys_mkdirat fs/namei.c:4156 [inline] __x64_sys_mkdirat+0x115/0x170 fs/namei.c:4156 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x38/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd RIP: 0033:0x7fd44227cae9 Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 20 00 00 90 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 b0 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fd4430250c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000102 RAX: ffffffffffffffda RBX: 00007fd44239bf80 RCX: 00007fd44227cae9 RDX: 0000000000000000 RSI: 0000000020000000 RDI: ffffffffffffff9c RBP: 00007fd4422c847a R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 000000000000000b R14: 00007fd44239bf80 R15: 00007ffdf837cef8 Allocated by task 2435: kasan_save_stack+0x33/0x50 mm/kasan/common.c:45 kasan_set_track+0x25/0x30 mm/kasan/common.c:52 __kasan_slab_alloc+0x81/0x90 mm/kasan/common.c:328 kasan_slab_alloc include/linux/kasan.h:188 [inline] slab_post_alloc_hook mm/slab.h:762 [inline] slab_alloc_node mm/slab.c:3237 [inline] kmem_cache_alloc_node+0x173/0x540 mm/slab.c:3509 __alloc_skb+0x287/0x330 net/core/skbuff.c:640 skb_copy+0x12d/0x3c0 net/core/skbuff.c:1976 mac80211_hwsim_tx_frame_no_nl.isra.0+0xb94/0x1300 drivers/net/wireless/virtual/mac80211_hwsim.c:1835 mac80211_hwsim_tx_frame+0x1eb/0x2a0 drivers/net/wireless/virtual/mac80211_hwsim.c:2171 mac80211_hwsim_beacon_tx+0x41b/0x730 drivers/net/wireless/virtual/mac80211_hwsim.c:2264 __iterate_interfaces+0x2d2/0x580 net/mac80211/util.c:766 ieee80211_iterate_active_interfaces_atomic+0x71/0x1b0 net/mac80211/util.c:802 mac80211_hwsim_beacon+0x101/0x200 drivers/net/wireless/virtual/mac80211_hwsim.c:2290 __run_hrtimer kernel/time/hrtimer.c:1688 [inline] __hrtimer_run_queues+0x203/0xc10 kernel/time/hrtimer.c:1752 hrtimer_run_softirq+0x17d/0x350 kernel/time/hrtimer.c:1769 __do_softirq+0x218/0x965 kernel/softirq.c:553 The buggy address belongs to the object at ffff888029d280c0 which belongs to the cache skbuff_head_cache of size 240 The buggy address is located 192 bytes to the left of allocated 240-byte region [ffff888029d280c0, ffff888029d281b0) The buggy address belongs to the physical page: page:ffffea0000a74a00 refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff888029d28e80 pfn:0x29d28 memcg:ffff888021333681 flags: 0xfff00000000800(slab|node=0|zone=1|lastcpupid=0x7ff) page_type: 0x8() raw: 00fff00000000800 ffff888140065b00 ffffea00009f5590 ffffea0001dfeb10 raw: ffff888029d28e80 ffff888029d280c0 0000000100000008 ffff888021333681 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Unmovable, gfp_mask 0x342020(__GFP_HIGH|__GFP_NOWARN|__GFP_COMP|__GFP_HARDWALL|__GFP_THISNODE), pid 5019, tgid 5019 (sshd), ts 2565560271416, free_ts 2565559348925 set_page_owner include/linux/page_owner.h:31 [inline] post_alloc_hook+0x2cf/0x340 mm/page_alloc.c:1536 prep_new_page mm/page_alloc.c:1543 [inline] get_page_from_freelist+0xee0/0x2f20 mm/page_alloc.c:3170 __alloc_pages+0x1d0/0x4a0 mm/page_alloc.c:4426 __alloc_pages_node include/linux/gfp.h:237 [inline] kmem_getpages mm/slab.c:1356 [inline] cache_grow_begin+0x99/0x3a0 mm/slab.c:2550 cache_alloc_refill+0x294/0x3a0 mm/slab.c:2923 ____cache_alloc mm/slab.c:2999 [inline] ____cache_alloc mm/slab.c:2982 [inline] __do_cache_alloc mm/slab.c:3182 [inline] slab_alloc_node mm/slab.c:3230 [inline] slab_alloc mm/slab.c:3246 [inline] __kmem_cache_alloc_lru mm/slab.c:3423 [inline] kmem_cache_alloc+0x3a1/0x400 mm/slab.c:3432 skb_clone+0x171/0x3c0 net/core/skbuff.c:1911 dev_queue_xmit_nit+0x389/0xb70 net/core/dev.c:2284 xmit_one net/core/dev.c:3540 [inline] dev_hard_start_xmit+0x59/0x6c0 net/core/dev.c:3560 sch_direct_xmit+0x1ac/0xc20 net/sched/sch_generic.c:342 __dev_xmit_skb net/core/dev.c:3771 [inline] __dev_queue_xmit+0x126e/0x3d60 net/core/dev.c:4306 dev_queue_xmit include/linux/netdevice.h:3082 [inline] neigh_hh_output include/net/neighbour.h:526 [inline] neigh_output include/net/neighbour.h:540 [inline] ip_finish_output2+0x169c/0x2550 net/ipv4/ip_output.c:233 __ip_finish_output net/ipv4/ip_output.c:311 [inline] __ip_finish_output+0x38b/0x640 net/ipv4/ip_output.c:293 ip_finish_output+0x31/0x310 net/ipv4/ip_output.c:321 NF_HOOK_COND include/linux/netfilter.h:293 [inline] ip_output+0x13b/0x290 net/ipv4/ip_output.c:431 dst_output include/net/dst.h:458 [inline] ip_local_out net/ipv4/ip_output.c:127 [inline] __ip_queue_xmit+0xa15/0x1df0 net/ipv4/ip_output.c:533 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1136 [inline] free_unref_page_prepare+0x476/0xa40 mm/page_alloc.c:2312 free_unref_page+0x33/0x3b0 mm/page_alloc.c:2405 __folio_put_small mm/swap.c:106 [inline] __folio_put+0xc3/0x110 mm/swap.c:129 folio_put include/linux/mm.h:1475 [inline] put_page include/linux/mm.h:1544 [inline] anon_pipe_buf_release+0x3fa/0x4b0 fs/pipe.c:138 pipe_buf_release include/linux/pipe_fs_i.h:203 [inline] pipe_read+0x635/0x1270 fs/pipe.c:324 call_read_iter include/linux/fs.h:1950 [inline] new_sync_read fs/read_write.c:389 [inline] vfs_read+0x7ef/0x930 fs/read_write.c:470 ksys_read+0x1f0/0x250 fs/read_write.c:613 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x38/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd Memory state around the buggy address: ffff888029d27f00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff888029d27f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff888029d28000: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff888029d28080: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb ffff888029d28100: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ==================================================================