ntfs: volume version 3.1. ================================================================== BUG: KASAN: use-after-free in ntfs_attr_find+0x7d6/0xd50 fs/ntfs/attrib.c:609 Read of size 2 at addr ffff8880a934e09a by task syz-executor.1/9208 CPU: 0 PID: 9208 Comm: syz-executor.1 Not tainted 6.4.0-rc6-syzkaller-00026-gfb054096aea0 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/25/2023 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x1e7/0x2d0 lib/dump_stack.c:106 print_address_description mm/kasan/report.c:351 [inline] print_report+0x163/0x540 mm/kasan/report.c:462 kasan_report+0x176/0x1b0 mm/kasan/report.c:572 ntfs_attr_find+0x7d6/0xd50 fs/ntfs/attrib.c:609 ntfs_attr_lookup+0x4e4/0x2390 ntfs_read_locked_inode+0xbcf/0x49c0 fs/ntfs/inode.c:768 ntfs_iget+0x113/0x190 fs/ntfs/inode.c:177 load_system_files+0x3528/0x4840 fs/ntfs/super.c:1982 ntfs_fill_super+0x19b3/0x2bd0 fs/ntfs/super.c:2900 mount_bdev+0x2d0/0x3f0 fs/super.c:1380 legacy_get_tree+0xef/0x190 fs/fs_context.c:610 vfs_get_tree+0x8c/0x270 fs/super.c:1510 do_new_mount+0x28f/0xae0 fs/namespace.c:3039 do_mount fs/namespace.c:3382 [inline] __do_sys_mount fs/namespace.c:3591 [inline] __se_sys_mount+0x2d9/0x3c0 fs/namespace.c:3568 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd RIP: 0033:0x7fcffb68d6ca 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:00007fcffc4b0f88 EFLAGS: 00000202 ORIG_RAX: 00000000000000a5 RAX: ffffffffffffffda RBX: 0000000000000991 RCX: 00007fcffb68d6ca RDX: 000000002001f1c0 RSI: 000000002001f200 RDI: 00007fcffc4b0fe0 RBP: 00007fcffc4b1020 R08: 00007fcffc4b1020 R09: 0000000000000003 R10: 0000000000000003 R11: 0000000000000202 R12: 000000002001f1c0 R13: 000000002001f200 R14: 00007fcffc4b0fe0 R15: 000000002001f240 The buggy address belongs to the physical page: page:ffffea0002a4d380 refcount:0 mapcount:0 mapping:0000000000000000 index:0x1 pfn:0xa934e flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) page_type: 0xffffffff() raw: 00fff00000000000 ffffea0002a4d3c8 ffff8880b9843260 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 3, migratetype Unmovable, gfp_mask 0x1d2820(GFP_ATOMIC|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC|__GFP_HARDWALL), pid 5082, tgid 5082 (kworker/0:7), ts 2422950996735, free_ts 2462966425673 set_page_owner include/linux/page_owner.h:31 [inline] post_alloc_hook+0x1e6/0x210 mm/page_alloc.c:1731 prep_new_page mm/page_alloc.c:1738 [inline] get_page_from_freelist+0x321c/0x33a0 mm/page_alloc.c:3502 __alloc_pages+0x255/0x670 mm/page_alloc.c:4768 alloc_slab_page+0x6a/0x160 mm/slub.c:1851 allocate_slab mm/slub.c:1998 [inline] new_slab+0x84/0x2f0 mm/slub.c:2051 ___slab_alloc+0xa85/0x10a0 mm/slub.c:3192 __slab_alloc mm/slub.c:3291 [inline] __slab_alloc_node mm/slub.c:3344 [inline] slab_alloc_node mm/slub.c:3441 [inline] __kmem_cache_alloc_node+0x1b8/0x290 mm/slub.c:3490 __do_kmalloc_node mm/slab_common.c:965 [inline] __kmalloc_node_track_caller+0xa5/0x230 mm/slab_common.c:986 kmalloc_reserve+0xfe/0x240 net/core/skbuff.c:585 __alloc_skb+0x1b1/0x420 net/core/skbuff.c:654 alloc_skb include/linux/skbuff.h:1288 [inline] nsim_dev_trap_skb_build drivers/net/netdevsim/dev.c:751 [inline] nsim_dev_trap_report drivers/net/netdevsim/dev.c:808 [inline] nsim_dev_trap_report_work+0x250/0xa90 drivers/net/netdevsim/dev.c:853 process_one_work+0x8a0/0x10e0 kernel/workqueue.c:2405 worker_thread+0xa63/0x1210 kernel/workqueue.c:2552 kthread+0x2b8/0x350 kernel/kthread.c:379 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:308 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1302 [inline] free_unref_page_prepare+0x903/0xa30 mm/page_alloc.c:2564 free_unref_page+0x37/0x3f0 mm/page_alloc.c:2659 discard_slab mm/slub.c:2097 [inline] __unfreeze_partials+0x1b1/0x1f0 mm/slub.c:2636 put_cpu_partial+0x116/0x180 mm/slub.c:2712 qlist_free_all+0x22/0x60 mm/kasan/quarantine.c:185 kasan_quarantine_reduce+0x14b/0x160 mm/kasan/quarantine.c:292 __kasan_slab_alloc+0x23/0x70 mm/kasan/common.c:305 kasan_slab_alloc include/linux/kasan.h:186 [inline] slab_post_alloc_hook+0x68/0x3a0 mm/slab.h:711 slab_alloc_node mm/slub.c:3451 [inline] slab_alloc mm/slub.c:3459 [inline] __kmem_cache_alloc_lru mm/slub.c:3466 [inline] kmem_cache_alloc+0x11f/0x2e0 mm/slub.c:3475 dup_mm kernel/fork.c:1683 [inline] copy_mm+0x168/0x1d70 kernel/fork.c:1741 copy_process+0x1a0f/0x4290 kernel/fork.c:2507 kernel_clone+0x222/0x800 kernel/fork.c:2915 __do_sys_clone kernel/fork.c:3058 [inline] __se_sys_clone kernel/fork.c:3042 [inline] __x64_sys_clone+0x258/0x2a0 kernel/fork.c:3042 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd Memory state around the buggy address: ffff8880a934df80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff8880a934e000: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff >ffff8880a934e080: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ^ ffff8880a934e100: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff8880a934e180: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ==================================================================