================================================================== BUG: KASAN: use-after-free in string_nocheck lib/vsprintf.c:643 [inline] BUG: KASAN: use-after-free in string+0x20f/0x2a0 lib/vsprintf.c:725 Read of size 1 at addr ffff88810b1f1af0 by task syz.2.1028/3915 CPU: 0 PID: 3915 Comm: syz.2.1028 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/16/2026 Call Trace: __dump_stack+0x21/0x24 lib/dump_stack.c:88 dump_stack_lvl+0x110/0x170 lib/dump_stack.c:106 print_address_description+0x71/0x200 mm/kasan/report.c:316 print_report+0x4a/0x60 mm/kasan/report.c:420 kasan_report+0x122/0x150 mm/kasan/report.c:524 __asan_report_load1_noabort+0x14/0x20 mm/kasan/report_generic.c:348 string_nocheck lib/vsprintf.c:643 [inline] string+0x20f/0x2a0 lib/vsprintf.c:725 vsnprintf+0xec5/0x1990 lib/vsprintf.c:2805 seq_vprintf fs/seq_file.c:391 [inline] seq_printf+0x185/0x280 fs/seq_file.c:406 show_interrupts+0x8f9/0xa00 kernel/irq/proc.c:527 traverse+0x215/0x5e0 fs/seq_file.c:111 seq_lseek+0x13b/0x260 fs/seq_file.c:323 proc_reg_llseek+0x1c1/0x2a0 fs/proc/inode.c:289 vfs_llseek fs/read_write.c:289 [inline] ksys_lseek fs/read_write.c:302 [inline] __do_sys_lseek fs/read_write.c:313 [inline] __se_sys_lseek fs/read_write.c:311 [inline] __x64_sys_lseek+0x182/0x200 fs/read_write.c:311 x64_sys_call+0x297/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:9 do_syscall_x64 arch/x86/entry/common.c:46 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76 entry_SYSCALL_64_after_hwframe+0x68/0xd2 RIP: 0033:0x7f2b8879e159 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:00007f2b871f7028 EFLAGS: 00000246 ORIG_RAX: 0000000000000008 RAX: ffffffffffffffda RBX: 00007f2b88a26090 RCX: 00007f2b8879e159 RDX: 0000000000000000 RSI: 0000002000000008 RDI: 0000000000000006 RBP: 00007f2b8883506b R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007f2b88a26128 R14: 00007f2b88a26090 R15: 00007ffc18eae698 Allocated by task 1925: kasan_save_stack mm/kasan/common.c:46 [inline] kasan_set_track+0x4b/0x70 mm/kasan/common.c:53 kasan_save_alloc_info+0x1f/0x30 mm/kasan/generic.c:505 ____kasan_kmalloc mm/kasan/common.c:380 [inline] __kasan_kmalloc+0x95/0xb0 mm/kasan/common.c:389 kasan_kmalloc include/linux/kasan.h:212 [inline] __do_kmalloc_node mm/slab_common.c:938 [inline] __kmalloc_node+0xb2/0x1e0 mm/slab_common.c:945 kmalloc_node include/linux/slab.h:589 [inline] __vmalloc_area_node mm/vmalloc.c:3070 [inline] __vmalloc_node_range+0x564/0x1440 mm/vmalloc.c:3256 __vmalloc_node mm/vmalloc.c:3321 [inline] vzalloc+0x78/0x90 mm/vmalloc.c:3394 alloc_counters+0x66/0x530 net/ipv4/netfilter/arp_tables.c:672 copy_entries_to_user net/ipv6/netfilter/ip6_tables.c:839 [inline] get_entries net/ipv6/netfilter/ip6_tables.c:1039 [inline] do_ip6t_get_ctl+0xa84/0x11b0 net/ipv6/netfilter/ip6_tables.c:1676 nf_getsockopt+0x27f/0x2a0 net/netfilter/nf_sockopt.c:116 ipv6_getsockopt+0x230/0x2d0 net/ipv6/ipv6_sockglue.c:1513 tcp_getsockopt+0xff/0x130 net/ipv4/tcp.c:4464 sock_common_getsockopt+0xaa/0xc0 net/core/sock.c:3689 __sys_getsockopt+0x215/0x490 net/socket.c:2322 __do_sys_getsockopt net/socket.c:2337 [inline] __se_sys_getsockopt net/socket.c:2334 [inline] __x64_sys_getsockopt+0xbf/0xd0 net/socket.c:2334 x64_sys_call+0x3d/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:56 do_syscall_x64 arch/x86/entry/common.c:46 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76 entry_SYSCALL_64_after_hwframe+0x68/0xd2 Freed by task 1925: kasan_save_stack mm/kasan/common.c:46 [inline] kasan_set_track+0x4b/0x70 mm/kasan/common.c:53 kasan_save_free_info+0x2b/0x40 mm/kasan/generic.c:516 ____kasan_slab_free+0x132/0x180 mm/kasan/common.c:242 __kasan_slab_free+0x11/0x20 mm/kasan/common.c:250 kasan_slab_free include/linux/kasan.h:178 [inline] slab_free_hook mm/slub.c:1750 [inline] slab_free_freelist_hook+0xc2/0x190 mm/slub.c:1776 slab_free mm/slub.c:3712 [inline] __kmem_cache_free+0xb7/0x1b0 mm/slub.c:3728 kfree+0x6f/0xf0 mm/slab_common.c:990 kvfree+0x35/0x40 mm/util.c:639 __vunmap+0xb32/0xc00 mm/vmalloc.c:2745 __vfree mm/vmalloc.c:2788 [inline] vfree+0x61/0x90 mm/vmalloc.c:2819 copy_entries_to_user net/ipv6/netfilter/ip6_tables.c:882 [inline] get_entries net/ipv6/netfilter/ip6_tables.c:1039 [inline] do_ip6t_get_ctl+0xe91/0x11b0 net/ipv6/netfilter/ip6_tables.c:1676 nf_getsockopt+0x27f/0x2a0 net/netfilter/nf_sockopt.c:116 ipv6_getsockopt+0x230/0x2d0 net/ipv6/ipv6_sockglue.c:1513 tcp_getsockopt+0xff/0x130 net/ipv4/tcp.c:4464 sock_common_getsockopt+0xaa/0xc0 net/core/sock.c:3689 __sys_getsockopt+0x215/0x490 net/socket.c:2322 __do_sys_getsockopt net/socket.c:2337 [inline] __se_sys_getsockopt net/socket.c:2334 [inline] __x64_sys_getsockopt+0xbf/0xd0 net/socket.c:2334 x64_sys_call+0x3d/0x9a0 arch/x86/include/generated/asm/syscalls_64.h:56 do_syscall_x64 arch/x86/entry/common.c:46 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76 entry_SYSCALL_64_after_hwframe+0x68/0xd2 The buggy address belongs to the object at ffff88810b1f1af0 which belongs to the cache kmalloc-8 of size 8 The buggy address is located 0 bytes inside of 8-byte region [ffff88810b1f1af0, ffff88810b1f1af8) The buggy address belongs to the physical page: page:ffffea00042c7c40 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x10b1f1 flags: 0x4000000000000200(slab|zone=1) raw: 4000000000000200 dead000000000100 dead000000000122 ffff888100042300 raw: 0000000000000000 0000000000660066 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Unmovable, gfp_mask 0x12cc0(GFP_KERNEL|__GFP_NOWARN|__GFP_NORETRY), pid 1, tgid 1 (swapper/0), ts 2510566123, free_ts 0 set_page_owner include/linux/page_owner.h:33 [inline] post_alloc_hook+0x1f5/0x210 mm/page_alloc.c:2673 prep_new_page+0x1c/0x110 mm/page_alloc.c:2680 get_page_from_freelist+0x2ca9/0x2d20 mm/page_alloc.c:4587 __alloc_pages+0x1fa/0x610 mm/page_alloc.c:5931 alloc_slab_page+0x6e/0xf0 include/linux/gfp.h:-1 allocate_slab mm/slub.c:1967 [inline] new_slab+0x98/0x3e0 mm/slub.c:2020 ___slab_alloc+0x70f/0xb70 mm/slub.c:3177 __slab_alloc+0x5e/0xa0 mm/slub.c:3263 slab_alloc_node mm/slub.c:3348 [inline] __kmem_cache_alloc_node+0x204/0x2d0 mm/slub.c:3423 __do_kmalloc_node mm/slab_common.c:937 [inline] __kmalloc_node_track_caller+0xa1/0x1e0 mm/slab_common.c:958 kstrdup mm/util.c:66 [inline] kstrdup_const+0x5a/0xa0 mm/util.c:89 __kernfs_new_node+0xa6/0x670 fs/kernfs/dir.c:610 kernfs_new_node+0x150/0x260 fs/kernfs/dir.c:690 kernfs_create_dir_ns+0x47/0x130 fs/kernfs/dir.c:1046 sysfs_create_dir_ns+0x128/0x290 fs/sysfs/dir.c:59 create_dir lib/kobject.c:63 [inline] kobject_add_internal+0x718/0xc20 lib/kobject.c:231 page_owner free stack trace missing Memory state around the buggy address: ffff88810b1f1980: fc 05 fc fc fc fc fa fc fc fc fc 00 fc fc fc fc ffff88810b1f1a00: 03 fc fc fc fc 06 fc fc fc fc 07 fc fc fc fc 00 >ffff88810b1f1a80: fc fc fc fc 06 fc fc fc fc 07 fc fc fc fc fa fc ^ ffff88810b1f1b00: fc fc fc 07 fc fc fc fc 06 fc fc fc fc fa fc fc ffff88810b1f1b80: fc fc fa fc fc fc fc fa fc fc fc fc fa fc fc fc ================================================================== loop2: detected capacity change from 0 to 2048 EXT4-fs (loop2): mounted filesystem without journal. Quota mode: none. ext4 filesystem being mounted at /170/file0aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa supports timestamps until 2038-01-19 (0x7fffffff)