syz.3.735: attempt to access beyond end of device loop3: rw=524288, sector=16, nr_sectors = 40 limit=16 ================================================================== BUG: KASAN: slab-use-after-free in memcpy_to_page include/linux/highmem.h:427 [inline] BUG: KASAN: slab-use-after-free in z_erofs_transform_plain+0x38c/0x460 fs/erofs/decompressor.c:346 Read of size 4096 at addr ffff888067a78000 by task syz.3.735/8433 CPU: 0 PID: 8433 Comm: syz.3.735 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 02/12/2026 Call Trace: dump_stack_lvl+0x18c/0x250 lib/dump_stack.c:106 print_address_description mm/kasan/report.c:364 [inline] print_report+0xa8/0x210 mm/kasan/report.c:468 kasan_report+0x117/0x150 mm/kasan/report.c:581 check_region_inline mm/kasan/generic.c:-1 [inline] kasan_check_range+0x241/0x290 mm/kasan/generic.c:187 __asan_memcpy+0x29/0x70 mm/kasan/shadow.c:105 memcpy_to_page include/linux/highmem.h:427 [inline] z_erofs_transform_plain+0x38c/0x460 fs/erofs/decompressor.c:346 z_erofs_decompress_pcluster fs/erofs/zdata.c:1296 [inline] z_erofs_decompress_queue+0x1780/0x26f0 fs/erofs/zdata.c:1377 z_erofs_runqueue+0x1913/0x1aa0 fs/erofs/zdata.c:1774 z_erofs_read_folio+0x323/0x5c0 fs/erofs/zdata.c:1859 filemap_read_folio+0x172/0x760 mm/filemap.c:2420 filemap_update_page mm/filemap.c:2504 [inline] filemap_get_pages+0x13c7/0x1e90 mm/filemap.c:2618 filemap_read+0x402/0xf00 mm/filemap.c:2690 __kernel_read+0x2f3/0x710 fs/read_write.c:428 integrity_kernel_read+0x8a/0xd0 security/integrity/iint.c:221 ima_calc_file_hash_tfm security/integrity/ima/ima_crypto.c:485 [inline] ima_calc_file_shash security/integrity/ima/ima_crypto.c:516 [inline] ima_calc_file_hash+0x91d/0x1910 security/integrity/ima/ima_crypto.c:573 ima_collect_measurement+0x4d4/0xa20 security/integrity/ima/ima_api.c:290 process_measurement+0x128e/0x1d70 security/integrity/ima/ima_main.c:370 ima_file_check+0xcc/0x110 security/integrity/ima/ima_main.c:568 do_open fs/namei.c:3642 [inline] path_openat+0x28b7/0x3230 fs/namei.c:3797 do_filp_open+0x1f5/0x430 fs/namei.c:3824 do_sys_openat2+0x134/0x1d0 fs/open.c:1421 do_sys_open fs/open.c:1436 [inline] __do_sys_openat fs/open.c:1452 [inline] __se_sys_openat fs/open.c:1447 [inline] __x64_sys_openat+0x139/0x160 fs/open.c:1447 do_syscall_x64 arch/x86/entry/common.c:46 [inline] do_syscall_64+0x55/0xa0 arch/x86/entry/common.c:76 entry_SYSCALL_64_after_hwframe+0x68/0xd2 RIP: 0033:0x7f3c0e19c799 Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 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 e8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f3c0ef8a028 EFLAGS: 00000246 ORIG_RAX: 0000000000000101 RAX: ffffffffffffffda RBX: 00007f3c0e415fa0 RCX: 00007f3c0e19c799 RDX: 0000000000121140 RSI: 0000200000000000 RDI: ffffffffffffff9c RBP: 00007f3c0e232c99 R08: 0000000000000000 R09: 0000000000000000 R10: 000000000000013d R11: 0000000000000246 R12: 0000000000000000 R13: 00007f3c0e416038 R14: 00007f3c0e415fa0 R15: 00007ffe21552e08 Allocated by task 5867: kasan_save_stack mm/kasan/common.c:46 [inline] kasan_set_track+0x4e/0x70 mm/kasan/common.c:53 __kasan_slab_alloc+0x6c/0x80 mm/kasan/common.c:329 kasan_slab_alloc include/linux/kasan.h:188 [inline] slab_post_alloc_hook+0x6e/0x4b0 mm/slab.h:767 slab_alloc_node mm/slub.c:3495 [inline] kmem_cache_alloc_node+0x14c/0x320 mm/slub.c:3540 kmalloc_reserve+0x95/0x240 net/core/skbuff.c:562 __alloc_skb+0x138/0x2c0 net/core/skbuff.c:653 skb_copy+0x13d/0x7a0 net/core/skbuff.c:1987 mac80211_hwsim_tx_frame_no_nl+0xca9/0x11a0 drivers/net/wireless/virtual/mac80211_hwsim.c:1840 mac80211_hwsim_tx_frame+0x1b5/0x200 drivers/net/wireless/virtual/mac80211_hwsim.c:2176 mac80211_hwsim_beacon_tx+0x3e9/0x780 drivers/net/wireless/virtual/mac80211_hwsim.c:2269 __iterate_interfaces+0x243/0x500 net/mac80211/util.c:766 ieee80211_iterate_active_interfaces_atomic+0xdb/0x180 net/mac80211/util.c:802 mac80211_hwsim_beacon+0xbb/0x1b0 drivers/net/wireless/virtual/mac80211_hwsim.c:2295 __run_hrtimer kernel/time/hrtimer.c:1750 [inline] __hrtimer_run_queues+0x520/0xc40 kernel/time/hrtimer.c:1814 hrtimer_run_softirq+0x187/0x2b0 kernel/time/hrtimer.c:1831 handle_softirqs+0x280/0x820 kernel/softirq.c:578 __do_softirq kernel/softirq.c:612 [inline] invoke_softirq kernel/softirq.c:452 [inline] __irq_exit_rcu+0xd3/0x190 kernel/softirq.c:661 irq_exit_rcu+0x9/0x20 kernel/softirq.c:673 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1088 [inline] sysvec_apic_timer_interrupt+0xa4/0xc0 arch/x86/kernel/apic/apic.c:1088 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:687 The buggy address belongs to the object at ffff888067a78000 which belongs to the cache skbuff_small_head of size 704 The buggy address is located 0 bytes inside of freed 704-byte region [ffff888067a78000, ffff888067a782c0) The buggy address belongs to the physical page: page:ffffea00019e9e00 refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff888067a78340 pfn:0x67a78 head:ffffea00019e9e00 order:2 entire_mapcount:0 nr_pages_mapped:0 pincount:0 flags: 0xfff00000000840(slab|head|node=0|zone=1|lastcpupid=0x7ff) page_type: 0xffffffff() raw: 00fff00000000840 ffff8881426598c0 ffffea0001ef6d10 ffffea0001980b10 raw: ffff888067a78340 000000000013000f 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 2, migratetype Unmovable, gfp_mask 0x1d20c0(__GFP_IO|__GFP_FS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC|__GFP_HARDWALL), pid 8018, tgid 8018 (syz-executor), ts 171508997299, free_ts 170579533645 set_page_owner include/linux/page_owner.h:31 [inline] post_alloc_hook+0x1c1/0x200 mm/page_alloc.c:1581 prep_new_page mm/page_alloc.c:1588 [inline] get_page_from_freelist+0x1951/0x19e0 mm/page_alloc.c:3220 __alloc_pages+0x1f0/0x460 mm/page_alloc.c:4500 alloc_slab_page+0x5d/0x160 mm/slub.c:1881 allocate_slab mm/slub.c:2028 [inline] new_slab+0x87/0x2d0 mm/slub.c:2081 ___slab_alloc+0xc5d/0x12f0 mm/slub.c:3253 __slab_alloc mm/slub.c:3339 [inline] __slab_alloc_node mm/slub.c:3392 [inline] slab_alloc_node mm/slub.c:3485 [inline] kmem_cache_alloc_node+0x1e6/0x320 mm/slub.c:3540 kmalloc_reserve+0x95/0x240 net/core/skbuff.c:562 __alloc_skb+0x138/0x2c0 net/core/skbuff.c:653 alloc_skb include/linux/skbuff.h:1316 [inline] nlmsg_new include/net/netlink.h:1010 [inline] inet_netconf_notify_devconf+0x173/0x230 net/ipv4/devinet.c:2149 __devinet_sysctl_register+0x3f0/0x470 net/ipv4/devinet.c:2639 devinet_sysctl_register+0x17c/0x1f0 net/ipv4/devinet.c:2673 inetdev_init+0x2b4/0x4f0 net/ipv4/devinet.c:287 inetdev_event+0x324/0x1630 net/ipv4/devinet.c:1568 notifier_call_chain+0x197/0x380 kernel/notifier.c:93 call_netdevice_notifiers_extack net/core/dev.c:2077 [inline] call_netdevice_notifiers net/core/dev.c:2091 [inline] register_netdevice+0x16a5/0x1bb0 net/core/dev.c:10339 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1181 [inline] free_unref_page_prepare+0x7b2/0x8c0 mm/page_alloc.c:2365 free_unref_page+0x32/0x2e0 mm/page_alloc.c:2458 __slab_free+0x35a/0x400 mm/slub.c:3736 qlink_free mm/kasan/quarantine.c:166 [inline] qlist_free_all+0x75/0xd0 mm/kasan/quarantine.c:185 kasan_quarantine_reduce+0x143/0x160 mm/kasan/quarantine.c:292 __kasan_slab_alloc+0x22/0x80 mm/kasan/common.c:306 kasan_slab_alloc include/linux/kasan.h:188 [inline] slab_post_alloc_hook+0x6e/0x4b0 mm/slab.h:767 slab_alloc_node mm/slub.c:3495 [inline] slab_alloc mm/slub.c:3503 [inline] __kmem_cache_alloc_lru mm/slub.c:3510 [inline] kmem_cache_alloc+0x11a/0x2d0 mm/slub.c:3519 getname_flags+0xbb/0x500 fs/namei.c:140 user_path_at_empty+0x2c/0x60 fs/namei.c:2916 do_readlinkat+0xdd/0x490 fs/stat.c:494 __do_sys_readlink fs/stat.c:527 [inline] __se_sys_readlink fs/stat.c:524 [inline] __x64_sys_readlink+0x7f/0x90 fs/stat.c:524 do_syscall_x64 arch/x86/entry/common.c:46 [inline] do_syscall_64+0x55/0xa0 arch/x86/entry/common.c:76 entry_SYSCALL_64_after_hwframe+0x68/0xd2 Memory state around the buggy address: ffff888067a77f00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888067a77f80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff888067a78000: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff888067a78080: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff888067a78100: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ==================================================================