================================================================== BUG: KASAN: slab-out-of-bounds in xfrm_policy_inexact_list_reinsert+0x5d2/0x690 net/xfrm/xfrm_policy.c:874 Read of size 1 at addr ffff8880624f9608 by task syz.1.2272/11703 CPU: 1 PID: 11703 Comm: syz.1.2272 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/25/2025 Call Trace: dump_stack_lvl+0x188/0x250 lib/dump_stack.c:106 print_address_description+0x60/0x2d0 mm/kasan/report.c:248 __kasan_report mm/kasan/report.c:434 [inline] kasan_report+0xdf/0x130 mm/kasan/report.c:451 xfrm_policy_inexact_list_reinsert+0x5d2/0x690 net/xfrm/xfrm_policy.c:874 xfrm_policy_inexact_node_merge net/xfrm/xfrm_policy.c:1006 [inline] xfrm_policy_inexact_insert_node+0x950/0xb60 net/xfrm/xfrm_policy.c:1062 xfrm_policy_inexact_alloc_chain+0x7ce/0xea0 net/xfrm/xfrm_policy.c:1178 xfrm_policy_inexact_insert+0xe0/0x1460 net/xfrm/xfrm_policy.c:1221 xfrm_policy_insert+0x112/0x930 net/xfrm/xfrm_policy.c:1605 xfrm_add_policy+0x4f2/0x880 net/xfrm/xfrm_user.c:1833 xfrm_user_rcv_msg+0x5e5/0x910 net/xfrm/xfrm_user.c:2979 netlink_rcv_skb+0x1f5/0x440 net/netlink/af_netlink.c:2507 xfrm_netlink_rcv+0x75/0x90 net/xfrm/xfrm_user.c:3001 netlink_unicast_kernel net/netlink/af_netlink.c:1318 [inline] netlink_unicast+0x774/0x920 net/netlink/af_netlink.c:1344 netlink_sendmsg+0x8ba/0xbe0 net/netlink/af_netlink.c:1918 sock_sendmsg_nosec net/socket.c:706 [inline] __sock_sendmsg net/socket.c:718 [inline] ____sys_sendmsg+0x5b7/0x8f0 net/socket.c:2445 ___sys_sendmsg+0x236/0x2e0 net/socket.c:2499 __sys_sendmsg net/socket.c:2528 [inline] __do_sys_sendmsg net/socket.c:2537 [inline] __se_sys_sendmsg+0x1af/0x290 net/socket.c:2535 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x66/0xd0 RIP: 0033:0x7fe55c457cb9 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:00007fe55a6b3028 EFLAGS: 00000246 ORIG_RAX: 000000000000002e RAX: ffffffffffffffda RBX: 00007fe55c6d2fa0 RCX: 00007fe55c457cb9 RDX: 0000000000000000 RSI: 0000200000000580 RDI: 0000000000000009 RBP: 00007fe55c4c5bf7 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007fe55c6d3038 R14: 00007fe55c6d2fa0 R15: 00007ffe0d030f48 Allocated by task 11703: kasan_save_stack mm/kasan/common.c:38 [inline] kasan_set_track mm/kasan/common.c:46 [inline] set_alloc_info mm/kasan/common.c:434 [inline] ____kasan_kmalloc mm/kasan/common.c:513 [inline] __kasan_kmalloc+0xb5/0xf0 mm/kasan/common.c:522 kmalloc include/linux/slab.h:612 [inline] sk_prot_alloc+0xe7/0x210 net/core/sock.c:1866 sk_alloc+0x2f/0x310 net/core/sock.c:1922 pfkey_create+0xd8/0x560 net/key/af_key.c:152 __sock_create+0x47b/0x900 net/socket.c:1495 sock_create net/socket.c:1551 [inline] __sys_socket+0xe2/0x170 net/socket.c:1593 __do_sys_socket net/socket.c:1602 [inline] __se_sys_socket net/socket.c:1600 [inline] __x64_sys_socket+0x76/0x80 net/socket.c:1600 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x66/0xd0 Last potentially related work creation: kasan_save_stack+0x35/0x60 mm/kasan/common.c:38 kasan_record_aux_stack+0xb8/0x100 mm/kasan/generic.c:348 kvfree_call_rcu+0x105/0x7d0 kernel/rcu/tree.c:3600 drop_sysctl_table+0x359/0x4e0 fs/proc/proc_sysctl.c:1685 unregister_sysctl_table+0x87/0x130 fs/proc/proc_sysctl.c:1723 __addrconf_sysctl_unregister net/ipv6/addrconf.c:7132 [inline] addrconf_sysctl_unregister net/ipv6/addrconf.c:7160 [inline] addrconf_ifdown+0x163a/0x19c0 net/ipv6/addrconf.c:3928 addrconf_notify+0x445/0xf00 net/ipv6/addrconf.c:-1 notifier_call_chain kernel/notifier.c:83 [inline] raw_notifier_call_chain+0xcb/0x160 kernel/notifier.c:391 call_netdevice_notifiers_extack net/core/dev.c:2061 [inline] call_netdevice_notifiers net/core/dev.c:2075 [inline] unregister_netdevice_many+0x1049/0x19f0 net/core/dev.c:11134 vti6_exit_batch_net+0x3d2/0x420 net/ipv6/ip6_vti.c:1190 ops_exit_list net/core/net_namespace.c:177 [inline] cleanup_net+0x791/0xba0 net/core/net_namespace.c:635 process_one_work+0x85f/0x1010 kernel/workqueue.c:2310 worker_thread+0xaa6/0x1290 kernel/workqueue.c:2457 kthread+0x436/0x520 kernel/kthread.c:334 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287 The buggy address belongs to the object at ffff8880624f9000 which belongs to the cache kmalloc-2k of size 2048 The buggy address is located 1544 bytes inside of 2048-byte region [ffff8880624f9000, ffff8880624f9800) The buggy address belongs to the page: page:ffffea0001893e00 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x624f8 head:ffffea0001893e00 order:3 compound_mapcount:0 compound_pincount:0 flags: 0xfff00000010200(slab|head|node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000010200 dead000000000100 dead000000000122 ffff888016c42000 raw: 0000000000000000 0000000000080008 00000001ffffffff 0000000000000000 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 4193, ts 51982736342, free_ts 12980175750 prep_new_page mm/page_alloc.c:2426 [inline] get_page_from_freelist+0x1bbd/0x1ca0 mm/page_alloc.c:4192 __alloc_pages+0x1ee/0x480 mm/page_alloc.c:5487 alloc_slab_page mm/slub.c:1780 [inline] allocate_slab mm/slub.c:1917 [inline] new_slab+0xc0/0x4b0 mm/slub.c:1980 ___slab_alloc+0x80a/0xdd0 mm/slub.c:3013 __slab_alloc mm/slub.c:3100 [inline] slab_alloc_node mm/slub.c:3191 [inline] slab_alloc mm/slub.c:3233 [inline] __kmalloc_track_caller+0x1cb/0x330 mm/slub.c:4930 kmemdup+0x22/0x50 mm/util.c:128 neigh_sysctl_register+0xaa/0xa90 net/core/neighbour.c:3652 addrconf_sysctl_register+0xac/0x1b0 net/ipv6/addrconf.c:7146 ipv6_add_dev+0xbf3/0x1190 net/ipv6/addrconf.c:454 addrconf_notify+0x66f/0xf00 net/ipv6/addrconf.c:3576 notifier_call_chain kernel/notifier.c:83 [inline] raw_notifier_call_chain+0xcb/0x160 kernel/notifier.c:391 call_netdevice_notifiers_extack net/core/dev.c:2061 [inline] call_netdevice_notifiers net/core/dev.c:2075 [inline] register_netdevice+0x129d/0x16f0 net/core/dev.c:10428 register_netdev+0x37/0x50 net/core/dev.c:10521 vti6_init_net+0x210/0x2c0 net/ipv6/ip6_vti.c:1164 ops_init+0x357/0x600 net/core/net_namespace.c:138 setup_net+0x39e/0xa10 net/core/net_namespace.c:333 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1340 [inline] free_pcp_prepare mm/page_alloc.c:1391 [inline] free_unref_page_prepare+0x637/0x6c0 mm/page_alloc.c:3317 free_unref_page+0x8f/0x2a0 mm/page_alloc.c:3396 free_contig_range+0x96/0xf0 mm/page_alloc.c:9406 destroy_args+0xf0/0xa00 mm/debug_vm_pgtable.c:1018 debug_vm_pgtable+0x321/0x380 mm/debug_vm_pgtable.c:1336 do_one_initcall+0x272/0x730 init/main.c:1316 do_initcall_level+0x137/0x1f0 init/main.c:1389 do_initcalls+0x4b/0x90 init/main.c:1405 kernel_init_freeable+0x3e9/0x570 init/main.c:1629 kernel_init+0x19/0x1b0 init/main.c:1520 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287 Memory state around the buggy address: ffff8880624f9500: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff8880624f9580: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc >ffff8880624f9600: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff8880624f9680: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff8880624f9700: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================