================================================================== BUG: KASAN: out-of-bounds in udf_write_fi+0x914/0xf20 fs/udf/namei.c:93 Write of size 18446744073709551572 at addr ffff888095d8f02c by task syz-executor.0/25234 CPU: 1 PID: 25234 Comm: syz-executor.0 Not tainted 6.1.0-syzkaller-14594-g72a85e2b0a1e #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0xd1/0x138 lib/dump_stack.c:106 print_address_description mm/kasan/report.c:306 [inline] print_report+0x15e/0x45d mm/kasan/report.c:417 kasan_report+0xbf/0x1f0 mm/kasan/report.c:517 check_region_inline mm/kasan/generic.c:183 [inline] kasan_check_range+0x141/0x190 mm/kasan/generic.c:189 memset+0x24/0x50 mm/kasan/shadow.c:44 udf_write_fi+0x914/0xf20 fs/udf/namei.c:93 udf_rename+0x456/0x1260 fs/udf/namei.c:1173 vfs_rename+0x1162/0x1a90 fs/namei.c:4779 do_renameat2+0xb22/0xc30 fs/namei.c:4930 __do_sys_renameat2 fs/namei.c:4963 [inline] __se_sys_renameat2 fs/namei.c:4960 [inline] __x64_sys_renameat2+0xe8/0x120 fs/namei.c:4960 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x39/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd RIP: 0033:0x7f3edb08c0a9 Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 f1 19 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 b8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f3edbe58168 EFLAGS: 00000246 ORIG_RAX: 000000000000013c RAX: ffffffffffffffda RBX: 00007f3edb1abf80 RCX: 00007f3edb08c0a9 RDX: 0000000000000004 RSI: 0000000020000080 RDI: 0000000000000005 RBP: 00007f3edbe581d0 R08: 0000000000000000 R09: 0000000000000000 R10: 00000000200000c0 R11: 0000000000000246 R12: 0000000000000002 R13: 00007ffdc339e4ff R14: 00007f3edbe58300 R15: 0000000000022000 The buggy address belongs to the physical page: page:ffffea00025763c0 refcount:2 mapcount:0 mapping:ffff88801dc8eaf8 index:0xa8 pfn:0x95d8f memcg:ffff88807ee5c000 aops:def_blk_aops ino:700000 flags: 0xfff00000002032(referenced|lru|active|private|node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000002032 ffffea0000beb788 ffff888075d95030 ffff88801dc8eaf8 raw: 00000000000000a8 ffff888086856000 00000002ffffffff ffff88807ee5c000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Movable, gfp_mask 0x148c48(GFP_NOFS|__GFP_NOFAIL|__GFP_COMP|__GFP_HARDWALL|__GFP_MOVABLE), pid 25234, tgid 25231 (syz-executor.0), ts 793913736244, free_ts 793907460776 prep_new_page mm/page_alloc.c:2531 [inline] get_page_from_freelist+0x119c/0x2ce0 mm/page_alloc.c:4283 __alloc_pages+0x1cb/0x5b0 mm/page_alloc.c:5549 alloc_pages+0x1aa/0x270 mm/mempolicy.c:2286 folio_alloc+0x20/0x70 mm/mempolicy.c:2296 filemap_alloc_folio+0x362/0x450 mm/filemap.c:972 __filemap_get_folio+0x32c/0xd80 mm/filemap.c:1966 pagecache_get_page+0x2e/0x280 mm/folio-compat.c:98 find_or_create_page include/linux/pagemap.h:612 [inline] grow_dev_page fs/buffer.c:946 [inline] grow_buffers fs/buffer.c:1011 [inline] __getblk_slow+0x1f4/0x1030 fs/buffer.c:1038 __getblk_gfp fs/buffer.c:1333 [inline] __bread_gfp+0x22c/0x330 fs/buffer.c:1367 sb_bread include/linux/buffer_head.h:338 [inline] udf_tread+0x169/0x1d0 fs/udf/misc.c:44 udf_find_entry+0xc99/0x1230 fs/udf/namei.c:206 udf_lookup fs/udf/namei.c:309 [inline] udf_lookup+0x15a/0x270 fs/udf/namei.c:298 lookup_open.isra.0+0x74c/0x1270 fs/namei.c:3391 open_last_lookups fs/namei.c:3481 [inline] path_openat+0x975/0x2a50 fs/namei.c:3711 do_filp_open+0x1ba/0x410 fs/namei.c:3741 do_sys_openat2+0x16d/0x4c0 fs/open.c:1310 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1446 [inline] free_pcp_prepare+0x65c/0xc00 mm/page_alloc.c:1496 free_unref_page_prepare mm/page_alloc.c:3369 [inline] free_unref_page_list+0x176/0xcd0 mm/page_alloc.c:3510 release_pages+0xcb1/0x1330 mm/swap.c:1076 tlb_batch_pages_flush+0xa8/0x1a0 mm/mmu_gather.c:97 tlb_flush_mmu_free mm/mmu_gather.c:292 [inline] tlb_flush_mmu mm/mmu_gather.c:299 [inline] tlb_finish_mmu+0x14b/0x7e0 mm/mmu_gather.c:391 exit_mmap+0x202/0x7b0 mm/mmap.c:3096 __mmput+0x128/0x4c0 kernel/fork.c:1207 mmput+0x60/0x70 kernel/fork.c:1229 exit_mm kernel/exit.c:563 [inline] do_exit+0x9ac/0x2950 kernel/exit.c:854 do_group_exit+0xd4/0x2a0 kernel/exit.c:1012 get_signal+0x21c3/0x2450 kernel/signal.c:2859 arch_do_signal_or_restart+0x79/0x5c0 arch/x86/kernel/signal.c:306 exit_to_user_mode_loop kernel/entry/common.c:168 [inline] exit_to_user_mode_prepare+0x15f/0x250 kernel/entry/common.c:203 __syscall_exit_to_user_mode_work kernel/entry/common.c:285 [inline] syscall_exit_to_user_mode+0x1d/0x50 kernel/entry/common.c:296 do_syscall_64+0x46/0xb0 arch/x86/entry/common.c:86 entry_SYSCALL_64_after_hwframe+0x63/0xcd Memory state around the buggy address: ffff888095d8ef00: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff888095d8ef80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff >ffff888095d8f000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ^ ffff888095d8f080: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888095d8f100: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ==================================================================