================================================================== BUG: KASAN: use-after-free in crc_itu_t+0x1dd/0x2b0 lib/crc-itu-t.c:60 Read of size 1 at addr ffff88802a823000 by task syz-executor334/5060 CPU: 1 PID: 5060 Comm: syz-executor334 Not tainted 6.2.0-rc1-syzkaller #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+0x1b1/0x290 lib/dump_stack.c:106 print_address_description+0x74/0x340 mm/kasan/report.c:306 print_report+0x107/0x1f0 mm/kasan/report.c:417 kasan_report+0xcd/0x100 mm/kasan/report.c:517 crc_itu_t+0x1dd/0x2b0 lib/crc-itu-t.c:60 udf_finalize_lvid fs/udf/super.c:2021 [inline] udf_sync_fs+0x1bc/0x360 fs/udf/super.c:2377 sync_filesystem+0xe8/0x220 fs/sync.c:56 generic_shutdown_super+0x6b/0x310 fs/super.c:474 kill_block_super+0x79/0xd0 fs/super.c:1386 deactivate_locked_super+0xa7/0xf0 fs/super.c:332 cleanup_mnt+0x494/0x520 fs/namespace.c:1291 task_work_run+0x243/0x300 kernel/task_work.c:179 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline] exit_to_user_mode_loop+0x124/0x150 kernel/entry/common.c:171 exit_to_user_mode_prepare+0xb2/0x140 kernel/entry/common.c:203 __syscall_exit_to_user_mode_work kernel/entry/common.c:285 [inline] syscall_exit_to_user_mode+0x26/0x60 kernel/entry/common.c:296 do_syscall_64+0x49/0xb0 arch/x86/entry/common.c:86 entry_SYSCALL_64_after_hwframe+0x63/0xcd RIP: 0033:0x7fceb8082dc7 Code: 07 00 48 83 c4 08 5b 5d c3 66 2e 0f 1f 84 00 00 00 00 00 c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 b8 a6 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:00007ffeeddb2228 EFLAGS: 00000206 ORIG_RAX: 00000000000000a6 RAX: 0000000000000000 RBX: 0000000000000000 RCX: 00007fceb8082dc7 RDX: 00007ffeeddb22e9 RSI: 000000000000000a RDI: 00007ffeeddb22e0 RBP: 00007ffeeddb22e0 R08: 00000000ffffffff R09: 00007ffeeddb20c0 R10: 0000555556f22653 R11: 0000000000000206 R12: 00007ffeeddb3350 R13: 0000555556f225f0 R14: 00007ffeeddb2250 R15: 0000000000000001 The buggy address belongs to the physical page: page:ffffea0000aa08c0 refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x2a823 flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000000000 ffffea0000880fc8 ffffea0000aa0908 0000000000000000 raw: 0000000000000000 0000000000000000 00000000ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as freed page last allocated via order 0, migratetype Unmovable, gfp_mask 0x141cc0(GFP_USER|__GFP_COMP|__GFP_WRITE), pid 5061, tgid 5061 (syz-executor334), ts 50026993606, free_ts 50035209519 prep_new_page mm/page_alloc.c:2531 [inline] get_page_from_freelist+0x742/0x7c0 mm/page_alloc.c:4283 __alloc_pages+0x259/0x560 mm/page_alloc.c:5549 folio_alloc+0x1a/0x50 mm/mempolicy.c:2296 filemap_alloc_folio+0xca/0x2c0 mm/filemap.c:972 __filemap_get_folio+0x892/0x1250 mm/filemap.c:1966 pagecache_get_page+0x28/0x250 mm/folio-compat.c:98 block_write_begin+0x2e/0x1e0 fs/buffer.c:2098 generic_perform_write+0x2e4/0x5e0 mm/filemap.c:3772 __generic_file_write_iter+0x29b/0x400 mm/filemap.c:3868 blkdev_write_iter+0x3ea/0x720 block/fops.c:534 do_iter_write+0x6c2/0xc20 fs/read_write.c:861 iter_file_splice_write+0x7fc/0xfc0 fs/splice.c:686 do_splice_from fs/splice.c:764 [inline] direct_splice_actor+0xe6/0x1c0 fs/splice.c:931 splice_direct_to_actor+0x4e4/0xc00 fs/splice.c:886 do_splice_direct+0x279/0x3d0 fs/splice.c:974 do_sendfile+0x5fb/0xf80 fs/read_write.c:1255 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+0x751/0x780 mm/page_alloc.c:1496 free_unref_page_prepare mm/page_alloc.c:3369 [inline] free_unref_page_list+0xb2/0x830 mm/page_alloc.c:3510 release_pages+0x233e/0x25e0 mm/swap.c:1076 __pagevec_release+0x7d/0xf0 mm/swap.c:1096 pagevec_release include/linux/pagevec.h:71 [inline] folio_batch_release include/linux/pagevec.h:135 [inline] invalidate_mapping_pagevec+0x509/0x640 mm/truncate.c:536 __generic_file_write_iter+0x36e/0x400 mm/filemap.c:3890 blkdev_write_iter+0x3ea/0x720 block/fops.c:534 do_iter_write+0x6c2/0xc20 fs/read_write.c:861 iter_file_splice_write+0x7fc/0xfc0 fs/splice.c:686 do_splice_from fs/splice.c:764 [inline] direct_splice_actor+0xe6/0x1c0 fs/splice.c:931 splice_direct_to_actor+0x4e4/0xc00 fs/splice.c:886 do_splice_direct+0x279/0x3d0 fs/splice.c:974 do_sendfile+0x5fb/0xf80 fs/read_write.c:1255 __do_sys_sendfile64 fs/read_write.c:1323 [inline] __se_sys_sendfile64+0x14f/0x1b0 fs/read_write.c:1309 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: ffff88802a822f00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff88802a822f80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff88802a823000: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ^ ffff88802a823080: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff88802a823100: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ==================================================================