================================================================== BUG: KASAN: slab-out-of-bounds in string_nocheck lib/vsprintf.c:648 [inline] BUG: KASAN: slab-out-of-bounds in string+0x216/0x2d0 lib/vsprintf.c:730 Read of size 1 at addr ffff888022792758 by task syz.2.125 Read of size 1 at addr ffff888022792758 by task syz.2.12593/1952 CPU: 1 UID: 0 PID: 1952 Comm: syz.2.12593 Not tainted syzkaller #0 PREEMPT(full) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 08/26/2026 Call Trace: dump_stack_lvl+0xe8/0x150 lib/dump_stack.c:120 print_address_description+0x55/0x1e0 mm/kasan/report.c:378 print_report+0x58/0x70 mm/kasan/report.c:482 kasan_report+0x117/0x150 mm/kasan/report.c:595 string_nocheck lib/vsprintf.c:648 [inline] string+0x216/0x2d0 lib/vsprintf.c:730 vsnprintf+0x74a/0xef0 lib/vsprintf.c:2949 seq_vprintf fs/seq_file.c:392 [inline] seq_printf+0x188/0x290 fs/seq_file.c:407 input_devices_seq_show+0x10f/0x640 drivers/input/input.c:1178 seq_read_iter+0x8d5/0xca0 fs/seq_file.c:273 seq_read+0x367/0x480 fs/seq_file.c:163 pde_read fs/proc/inode.c:308 [inline] proc_reg_read+0x1e9/0x2e0 fs/proc/inode.c:320 vfs_read+0x213/0xa80 fs/read_write.c:572 ksys_read+0x150/0x270 fs/read_write.c:716 do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline] do_syscall_64+0x166/0x520 arch/x86/entry/syscall_64.c:84 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f1cbff9e159 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:00007f1cc0ede028 EFLAGS: 00000246 ORIG_RAX: 0000000000000000 RAX: ffffffffffffffda RBX: 00007f1cc0225fa0 RCX: 00007f1cbff9e159 RDX: 0000000000002020 RSI: 00002000000028c0 RDI: 0000000000000003 RBP: 00007f1cc003506b R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007f1cc0226038 R14: 00007f1cc0225fa0 R15: 00007ffd854bdab8 Allocated by task 29592: kasan_save_stack mm/kasan/common.c:57 [inline] kasan_save_track+0x3e/0x80 mm/kasan/common.c:78 poison_kmalloc_redzone mm/kasan/common.c:398 [inline] __kasan_kmalloc+0x93/0xb0 mm/kasan/common.c:415 kasan_kmalloc include/linux/kasan.h:263 [inline] __kmalloc_cache_noprof+0x321/0x600 mm/slub.c:5563 _kmalloc_noprof include/linux/slab.h:991 [inline] _kzalloc_noprof include/linux/slab.h:1312 [inline] keypair_create drivers/net/wireguard/noise.c:100 [inline] wg_noise_handshake_begin_session+0xd4/0xbf0 drivers/net/wireguard/noise.c:827 wg_receive_handshake_packet drivers/net/wireguard/receive.c:176 [inline] wg_packet_handshake_receive_worker+0x700/0x10c0 drivers/net/wireguard/receive.c:213 process_one_work kernel/workqueue.c:3396 [inline] process_scheduled_works+0xc3d/0x1630 kernel/workqueue.c:3479 worker_thread+0xa47/0xfb0 kernel/workqueue.c:3560 kthread+0x38b/0x480 kernel/kthread.c:436 ret_from_fork+0x514/0xb70 arch/x86/kernel/process.c:158 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 The buggy address belongs to the object at ffff888022792000 which belongs to the cache kmalloc-2k of size 2048 The buggy address is located 608 bytes to the right of allocated 1272-byte region [ffff888022792000, ffff8880227924f8) The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0xffff888022796000 pfn:0x22790 head: order:3 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0 flags: 0xfff00000000240(workingset|head|node=0|zone=1|lastcpupid=0x7ff) page_type: f5(slab) raw: 00fff00000000240 ffff88801b042000 ffffea0001f3ca10 ffffea0000a6ae10 raw: ffff888022796000 0000000000080007 00000000f5000000 0000000000000000 head: 00fff00000000240 ffff88801b042000 ffffea0001f3ca10 ffffea0000a6ae10 head: ffff888022796000 0000000000080007 00000000f5000000 0000000000000000 head: 00fff00000000003 fffffffffffffe01 00000000ffffffff 00000000ffffffff head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000008 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 3, migratetype Unmovable, gfp_mask 0xd20c0(__GFP_IO|__GFP_FS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC), pid 1, tgid 1 (swapper/0), ts 5676030468 set_page_owner include/linux/page_owner.h:33 [inline] post_alloc_hook+0x1f9/0x250 mm/page_alloc.c:1871 prep_new_page mm/page_alloc.c:1879 [inline] get_page_from_freelist+0x2209/0x2280 mm/page_alloc.c:3943 __alloc_frozen_pages_noprof+0x217/0x5a0 mm/page_alloc.c:5436 alloc_slab_page mm/slub.c:3347 [inline] allocate_slab+0x7d/0x620 mm/slub.c:3462 new_slab mm/slub.c:3513 [inline] refill_objects+0x2d5/0x350 mm/slub.c:7417 refill_sheaf mm/slub.c:2885 [inline] __pcs_replace_empty_main+0x2c8/0x6c0 mm/slub.c:4774 alloc_from_pcs mm/slub.c:4850 [inline] slab_alloc_node mm/slub.c:4984 [inline] __kmalloc_cache_noprof+0x39b/0x600 mm/slub.c:5559 _kmalloc_noprof include/linux/slab.h:991 [inline] _kzalloc_noprof include/linux/slab.h:1312 [inline] device_create_groups_vargs drivers/base/core.c:4440 [inline] device_create_with_groups+0x13d/0x300 drivers/base/core.c:4538 misc_register+0x2f7/0x560 drivers/char/misc.c:254 nvmf_init+0x237/0x330 drivers/nvme/host/fabrics.c:1517 do_one_initcall+0x250/0x870 init/main.c:1362 do_initcall_level+0x10a/0x1a0 init/main.c:1424 do_initcalls+0x59/0xa0 init/main.c:1440 kernel_init_freeable+0x29d/0x3e0 init/main.c:1675 kernel_init+0x22/0x1d0 init/main.c:1565 ret_from_fork+0x514/0xb70 arch/x86/kernel/process.c:158 page last free pid 983 tgid 983 ts 5435157251 stack trace: reset_page_owner include/linux/page_owner.h:26 [inline] __free_pages_prepare mm/page_alloc.c:1418 [inline] free_pages_prepare+0x9eb/0xaf0 mm/page_alloc.c:1463 __free_contig_range_common+0x174/0x340 mm/page_alloc.c:7072 __free_contig_range mm/page_alloc.c:7117 [inline] free_pages_bulk+0x48/0x120 mm/page_alloc.c:5322 vm_area_free_pages mm/vmalloc.c:3461 [inline] vfree+0x231/0x490 mm/vmalloc.c:3510 delayed_vfree_work+0x55/0x80 mm/vmalloc.c:3414 process_one_work kernel/workqueue.c:3396 [inline] process_scheduled_works+0xc3d/0x1630 kernel/workqueue.c:3479 worker_thread+0xa47/0xfb0 kernel/workqueue.c:3560 kthread+0x38b/0x480 kernel/kthread.c:436 ret_from_fork+0x514/0xb70 arch/x86/kernel/process.c:158 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 Memory state around the buggy address: ffff888022792600: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff888022792680: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff888022792700: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff888022792780: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff888022792800: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================