loop4: detected capacity change from 0 to 4096 ================================================================== BUG: KASAN: use-after-free in ntfs_attr_find+0x7d6/0xd50 Read of size 2 at addr ffff88808f05a12e by task syz-executor.4/12881 CPU: 0 PID: 12881 Comm: syz-executor.4 Not tainted 6.2.0-rc7-syzkaller-00011-g05ecb680708a #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/12/2023 Call Trace: dump_stack_lvl+0x1e7/0x2d0 print_report+0x163/0x4f0 kasan_report+0x13a/0x170 ntfs_attr_find+0x7d6/0xd50 ntfs_attr_lookup+0x4e4/0x2390 ntfs_attr_iget+0x50a/0x2360 load_system_files+0x1333/0x4840 ntfs_fill_super+0x19b4/0x2bd0 mount_bdev+0x271/0x3a0 legacy_get_tree+0xef/0x190 vfs_get_tree+0x8c/0x270 do_new_mount+0x28f/0xae0 __se_sys_mount+0x2d9/0x3c0 do_syscall_64+0x41/0xc0 entry_SYSCALL_64_after_hwframe+0x63/0xcd RIP: 0033:0x7fa752a8d62a Code: 48 c7 c2 b8 ff ff ff f7 d8 64 89 02 b8 ff ff ff ff eb d2 e8 b8 04 00 00 0f 1f 84 00 00 00 00 00 49 89 ca b8 a5 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fa7515fdf88 EFLAGS: 00000202 ORIG_RAX: 00000000000000a5 RAX: ffffffffffffffda RBX: 000000000001f6d9 RCX: 00007fa752a8d62a RDX: 000000002001f6c0 RSI: 000000002001f640 RDI: 00007fa7515fdfe0 RBP: 00007fa7515fe020 R08: 00007fa7515fe020 R09: 0000000000008703 R10: 0000000000008703 R11: 0000000000000202 R12: 000000002001f6c0 R13: 000000002001f640 R14: 00007fa7515fdfe0 R15: 000000002001f700 The buggy address belongs to the physical page: page:ffffea00023c1680 refcount:0 mapcount:0 mapping:0000000000000000 index:0x1 pfn:0x8f05a flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000000000 dead000000000100 dead000000000122 0000000000000000 raw: 0000000000000001 0000000000000000 00000000ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as freed page last allocated via order 0, migratetype Movable, gfp_mask 0x140cca(GFP_HIGHUSER_MOVABLE|__GFP_COMP), pid 11852, tgid 11852 (syz-executor.2), ts 800833812033, free_ts 801677294969 get_page_from_freelist+0x3449/0x35c0 __alloc_pages+0x291/0x7e0 __folio_alloc+0x13/0x30 vma_alloc_folio+0x48a/0x9a0 do_wp_page+0xad7/0x3280 handle_mm_fault+0x2395/0x51e0 exc_page_fault+0x673/0x880 asm_exc_page_fault+0x26/0x30 page last free stack trace: free_unref_page_prepare+0xf3a/0x1040 free_unref_page_list+0x6b1/0x950 release_pages+0x219e/0x2470 tlb_flush_mmu+0x100/0x210 unmap_page_range+0x238d/0x2920 unmap_vmas+0x3c8/0x560 exit_mmap+0x251/0x970 __mmput+0x115/0x3c0 exit_mm+0x227/0x310 do_exit+0x588/0x2210 do_group_exit+0x206/0x2c0 __x64_sys_exit_group+0x3f/0x40 do_syscall_64+0x41/0xc0 entry_SYSCALL_64_after_hwframe+0x63/0xcd Memory state around the buggy address: ffff88808f05a000: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff88808f05a080: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff >ffff88808f05a100: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ^ ffff88808f05a180: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff88808f05a200: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ==================================================================