netlink: 68 bytes leftover after parsing attributes in process `syz-executor.6'. ================================================================== BUG: KASAN: slab-use-after-free in xfrm_alloc_spi+0xf67/0x1210 Read of size 4 at addr ffff888045fe00c4 by task syz-executor.6/228638 CPU: 1 UID: 0 PID: 228638 Comm: syz-executor.6 Not tainted 6.17.0-rc1-next-20250815 #1 PREEMPT(voluntary) Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.12.0-1 04/01/2014 Call Trace: dump_stack_lvl+0xca/0x120 print_report+0xcb/0x610 kasan_report+0xca/0x100 xfrm_alloc_spi+0xf67/0x1210 xfrm_alloc_userspi+0x607/0xbb0 xfrm_user_rcv_msg+0x459/0xa00 netlink_rcv_skb+0x147/0x430 xfrm_netlink_rcv+0x74/0x90 netlink_unicast+0x5a7/0x870 netlink_sendmsg+0x8ac/0xd80 ____sys_sendmsg+0xa67/0xc20 ___sys_sendmsg+0x10f/0x1b0 __sys_sendmsg+0x150/0x200 do_syscall_64+0xbf/0x360 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7fbeb179eb19 Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 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 bc ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fbeaed14188 EFLAGS: 00000246 ORIG_RAX: 000000000000002e RAX: ffffffffffffffda RBX: 00007fbeb18b1f60 RCX: 00007fbeb179eb19 RDX: 0000000000000000 RSI: 0000000020000900 RDI: 0000000000000003 RBP: 00007fbeb17f8f6d R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007ffd09f71c8f R14: 00007fbeaed14300 R15: 0000000000022000 Allocated by task 24969: kasan_save_stack+0x24/0x50 kasan_save_track+0x14/0x30 __kasan_slab_alloc+0x59/0x70 kmem_cache_alloc_noprof+0x13c/0x3d0 xfrm_state_alloc+0x25/0x600 __find_acq_core+0x9c8/0x27a0 xfrm_find_acq+0x7f/0xb0 xfrm_alloc_userspi+0x589/0xbb0 xfrm_user_rcv_msg+0x459/0xa00 netlink_rcv_skb+0x147/0x430 xfrm_netlink_rcv+0x74/0x90 netlink_unicast+0x5a7/0x870 netlink_sendmsg+0x8ac/0xd80 ____sys_sendmsg+0xa67/0xc20 ___sys_sendmsg+0x10f/0x1b0 __sys_sendmsg+0x150/0x200 do_syscall_64+0xbf/0x360 entry_SYSCALL_64_after_hwframe+0x77/0x7f Freed by task 11: kasan_save_stack+0x24/0x50 kasan_save_track+0x14/0x30 kasan_save_free_info+0x3a/0x60 __kasan_slab_free+0x3f/0x50 kmem_cache_free+0x2a1/0x460 xfrm_state_gc_task+0x107/0x740 process_one_work+0x8e1/0x19c0 worker_thread+0x67e/0xe90 kthread+0x3c8/0x740 ret_from_fork+0x34b/0x430 ret_from_fork_asm+0x1a/0x30 The buggy address belongs to the object at ffff888045fe0000 which belongs to the cache xfrm_state of size 920 The buggy address is located 196 bytes inside of freed 920-byte region [ffff888045fe0000, ffff888045fe0398) The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0xffff888045fe1540 pfn:0x45fe0 head: order:2 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0 flags: 0x100000000000040(head|node=0|zone=1) page_type: f5(slab) raw: 0100000000000040 ffff88800a711780 dead000000000122 0000000000000000 raw: ffff888045fe1540 00000000800f0009 00000000f5000000 0000000000000000 head: 0100000000000040 ffff88800a711780 dead000000000122 0000000000000000 head: ffff888045fe1540 00000000800f0009 00000000f5000000 0000000000000000 head: 0100000000000002 ffffea000117f801 00000000ffffffff 00000000ffffffff head: 0000000000000000 0000000000000000 00000000ffffffff 0000000000000004 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff888045fdff80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff888045fe0000: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb >ffff888045fe0080: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff888045fe0100: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff888045fe0180: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ================================================================== loop0: detected capacity change from 0 to 736 netlink: 68 bytes leftover after parsing attributes in process `syz-executor.6'. vcan0: tun_chr_ioctl cmd 1074025672 vcan0: ignored: set checksum enabled netlink: 68 bytes leftover after parsing attributes in process `syz-executor.6'. netlink: 68 bytes leftover after parsing attributes in process `syz-executor.6'. loop0: detected capacity change from 0 to 736 netlink: 68 bytes leftover after parsing attributes in process `syz-executor.6'. vcan0: tun_chr_ioctl cmd 1074025672 vcan0: ignored: set checksum enabled loop0: detected capacity change from 0 to 736 9pnet_fd: Insufficient options for proto=fd 9pnet_fd: Insufficient options for proto=fd 9pnet_fd: Insufficient options for proto=fd 9pnet_fd: Insufficient options for proto=fd vcan0: tun_chr_ioctl cmd 1074025672 vcan0: ignored: set checksum enabled loop0: detected capacity change from 0 to 736 vcan0: tun_chr_ioctl cmd 1074025672 vcan0: ignored: set checksum enabled 9pnet_fd: Insufficient options for proto=fd 9pnet_fd: Insufficient options for proto=fd vcan0: tun_chr_ioctl cmd 1074025672 vcan0: ignored: set checksum enabled loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 sr 1:0:0:0: [sr0] CDROM not ready. Make sure there is a disc in the drive. loop0: detected capacity change from 0 to 736 sr 1:0:0:0: [sr0] CDROM not ready. Make sure there is a disc in the drive. sr 1:0:0:0: [sr0] CDROM not ready. Make sure there is a disc in the drive. sr 1:0:0:0: [sr0] CDROM not ready. Make sure there is a disc in the drive. sr 1:0:0:0: [sr0] CDROM not ready. Make sure there is a disc in the drive. sr 1:0:0:0: [sr0] CDROM not ready. Make sure there is a disc in the drive. sr 1:0:0:0: [sr0] CDROM not ready. Make sure there is a disc in the drive. loop0: detected capacity change from 0 to 736 sr 1:0:0:0: [sr0] CDROM not ready. Make sure there is a disc in the drive. loop0: detected capacity change from 0 to 736 sr 1:0:0:0: [sr0] CDROM not ready. Make sure there is a disc in the drive. loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 sr 1:0:0:0: [sr0] CDROM not ready. Make sure there is a disc in the drive. loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 sr 1:0:0:0: [sr0] tag#0 unaligned transfer blk_print_req_error: 6 callbacks suppressed I/O error, dev sr0, sector 0 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 2 buffer_io_error: 6 callbacks suppressed Buffer I/O error on dev sr0, logical block 0, async page read loop0: detected capacity change from 0 to 736 sr 1:0:0:0: [sr0] tag#0 unaligned transfer I/O error, dev sr0, sector 1 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 2 Buffer I/O error on dev sr0, logical block 1, async page read sr 1:0:0:0: [sr0] tag#0 unaligned transfer I/O error, dev sr0, sector 2 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 2 Buffer I/O error on dev sr0, logical block 2, async page read sr 1:0:0:0: [sr0] tag#0 unaligned transfer I/O error, dev sr0, sector 3 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 2 Buffer I/O error on dev sr0, logical block 3, async page read sr 1:0:0:0: [sr0] tag#0 unaligned transfer I/O error, dev sr0, sector 4 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 2 Buffer I/O error on dev sr0, logical block 4, async page read sr 1:0:0:0: [sr0] tag#0 unaligned transfer I/O error, dev sr0, sector 5 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 2 Buffer I/O error on dev sr0, logical block 5, async page read sr 1:0:0:0: [sr0] tag#0 unaligned transfer I/O error, dev sr0, sector 6 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 2 Buffer I/O error on dev sr0, logical block 6, async page read sr 1:0:0:0: [sr0] tag#0 unaligned transfer I/O error, dev sr0, sector 7 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 2 Buffer I/O error on dev sr0, logical block 7, async page read sr 1:0:0:0: [sr0] tag#0 unaligned transfer I/O error, dev sr0, sector 0 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 2 Buffer I/O error on dev sr0, logical block 0, async page read sr 1:0:0:0: [sr0] tag#0 unaligned transfer I/O error, dev sr0, sector 1 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 2 Buffer I/O error on dev sr0, logical block 1, async page read sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer loop0: detected capacity change from 0 to 736 sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer loop0: detected capacity change from 0 to 736 sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer sr 1:0:0:0: [sr0] tag#0 unaligned transfer loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 loop0: detected capacity change from 0 to 736 SELinux: security_context_str_to_sid () failed with errno=-22 SELinux: security_context_str_to_sid () failed with errno=-22