REISERFS warning: read_super_block: reiserfs filesystem is deprecated and scheduled to be removed from the kernel in 2025 REISERFS (device loop0): found reiserfs format "3.5" with non-standard journal REISERFS (device loop0): using ordered data mode reiserfs: using flush barriers REISERFS (device loop0): journal params: device loop0, size 15748, journal first block 18, max trans len 1024, max batch 900, max commit age 0, max trans age 30 REISERFS (device loop0): checking transaction log (loop0) REISERFS (device loop0): Using r5 hash to sort names REISERFS (device loop0): using 3.5.x disk format ================================================================== BUG: KASAN: use-after-free in bin_search_in_dir_item fs/reiserfs/namei.c:40 [inline] BUG: KASAN: use-after-free in search_by_entry_key+0x580/0xd20 fs/reiserfs/namei.c:165 Read of size 4 at addr ffff8880723117c4 by task syz-executor327/3606 CPU: 0 PID: 3606 Comm: syz-executor327 Not tainted 6.0.0-syzkaller-09423-g493ffd6605b2 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/22/2022 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x1b1/0x28e lib/dump_stack.c:106 print_address_description+0x65/0x4b0 mm/kasan/report.c:317 print_report+0x108/0x1f0 mm/kasan/report.c:433 kasan_report+0xc3/0xf0 mm/kasan/report.c:495 bin_search_in_dir_item fs/reiserfs/namei.c:40 [inline] search_by_entry_key+0x580/0xd20 fs/reiserfs/namei.c:165 reiserfs_find_entry+0x280/0x1370 fs/reiserfs/namei.c:322 reiserfs_lookup+0x1d0/0x490 fs/reiserfs/namei.c:368 __lookup_slow+0x266/0x3a0 fs/namei.c:1685 lookup_one_len+0x430/0x690 fs/namei.c:2711 reiserfs_lookup_privroot+0x85/0x1e0 fs/reiserfs/xattr.c:973 reiserfs_fill_super+0x1835/0x24a0 fs/reiserfs/super.c:2194 mount_bdev+0x26c/0x3a0 fs/super.c:1400 legacy_get_tree+0xea/0x180 fs/fs_context.c:610 vfs_get_tree+0x88/0x270 fs/super.c:1530 do_new_mount+0x289/0xad0 fs/namespace.c:3040 do_mount fs/namespace.c:3383 [inline] __do_sys_mount fs/namespace.c:3591 [inline] __se_sys_mount+0x2d3/0x3c0 fs/namespace.c:3568 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd RIP: 0033:0x7f7952e7684a Code: 48 c7 c2 c0 ff ff ff f7 d8 64 89 02 b8 ff ff ff ff eb d2 e8 98 03 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 c0 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fff951138d8 EFLAGS: 00000286 ORIG_RAX: 00000000000000a5 RAX: ffffffffffffffda RBX: 00007fff95113930 RCX: 00007f7952e7684a RDX: 0000000020000000 RSI: 0000000020000100 RDI: 00007fff951138f0 RBP: 0000000000000003 R08: 00007fff95113930 R09: 0000000000000000 R10: 0000000000010001 R11: 0000000000000286 R12: 00007fff951138f0 R13: 0000000000000004 R14: 0000000000000003 R15: 0000000000000004 The buggy address belongs to the physical page: page:ffffea0001c8c440 refcount:0 mapcount:0 mapping:0000000000000000 index:0x1 pfn:0x72311 flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000000000 ffffea0001c90e48 ffffea0001c7f688 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 0x140dca(GFP_HIGHUSER_MOVABLE|__GFP_COMP|__GFP_ZERO), pid 3605, tgid 3605 (sh), ts 34997560219, free_ts 35004425544 prep_new_page mm/page_alloc.c:2532 [inline] get_page_from_freelist+0x742/0x7c0 mm/page_alloc.c:4283 __alloc_pages+0x259/0x560 mm/page_alloc.c:5549 __folio_alloc+0xf/0x30 mm/page_alloc.c:5580 vma_alloc_folio+0x663/0xb60 mm/mempolicy.c:2231 alloc_page_vma include/linux/gfp.h:290 [inline] do_anonymous_page+0x329/0x1150 mm/memory.c:4084 handle_pte_fault mm/memory.c:4915 [inline] __handle_mm_fault mm/memory.c:5059 [inline] handle_mm_fault+0x184b/0x3590 mm/memory.c:5157 do_user_addr_fault+0x69b/0xcb0 arch/x86/mm/fault.c:1407 handle_page_fault arch/x86/mm/fault.c:1498 [inline] exc_page_fault+0x7a/0x110 arch/x86/mm/fault.c:1554 asm_exc_page_fault+0x22/0x30 arch/x86/include/asm/idtentry.h:570 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1449 [inline] free_pcp_prepare+0x812/0x900 mm/page_alloc.c:1499 free_unref_page_prepare mm/page_alloc.c:3380 [inline] free_unref_page_list+0xb4/0x7b0 mm/page_alloc.c:3522 release_pages+0x22c3/0x2540 mm/swap.c:1012 tlb_batch_pages_flush mm/mmu_gather.c:58 [inline] tlb_flush_mmu_free mm/mmu_gather.c:255 [inline] tlb_flush_mmu+0x850/0xa70 mm/mmu_gather.c:262 tlb_finish_mmu+0xcb/0x200 mm/mmu_gather.c:353 exit_mmap+0x1cb/0x520 mm/mmap.c:3118 __mmput+0x111/0x3a0 kernel/fork.c:1187 exec_mmap+0x565/0x5f0 fs/exec.c:1033 begin_new_exec+0x7a1/0xfc0 fs/exec.c:1292 load_elf_binary+0x912/0x2840 fs/binfmt_elf.c:1002 search_binary_handler fs/exec.c:1725 [inline] exec_binprm fs/exec.c:1766 [inline] bprm_execve+0x8dc/0x1590 fs/exec.c:1835 do_execveat_common+0x598/0x750 fs/exec.c:1940 do_execve fs/exec.c:2014 [inline] __do_sys_execve fs/exec.c:2090 [inline] __se_sys_execve fs/exec.c:2085 [inline] __x64_sys_execve+0x8e/0xa0 fs/exec.c:2085 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd Memory state around the buggy address: ffff888072311680: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff888072311700: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff >ffff888072311780: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ^ ffff888072311800: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff888072311880: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ==================================================================