netlink: 12 bytes leftover after parsing attributes in process `syz-executor.1'. ================================================================== BUG: KASAN: slab-out-of-bounds in lco_csum include/linux/skbuff.h:4704 [inline] BUG: KASAN: slab-out-of-bounds in udp6_set_csum+0x52d/0x560 net/ipv6/ip6_checksum.c:127 Read of size 2 at addr ffff88803f5b3c02 by task syz-executor.1/31065 CPU: 0 PID: 31065 Comm: syz-executor.1 Not tainted 5.16.0-rc2-next-20211125-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0xcd/0x134 lib/dump_stack.c:106 print_address_description.constprop.0.cold+0xa5/0x3ed mm/kasan/report.c:247 __kasan_report mm/kasan/report.c:433 [inline] kasan_report.cold+0x83/0xdf mm/kasan/report.c:450 lco_csum include/linux/skbuff.h:4704 [inline] udp6_set_csum+0x52d/0x560 net/ipv6/ip6_checksum.c:127 udp_tunnel6_xmit_skb+0x2a6/0xc90 net/ipv6/ip6_udp_tunnel.c:97 geneve6_xmit_skb drivers/net/geneve.c:1051 [inline] geneve_xmit+0x912/0x3530 drivers/net/geneve.c:1080 __netdev_start_xmit include/linux/netdevice.h:4608 [inline] netdev_start_xmit include/linux/netdevice.h:4622 [inline] xmit_one net/core/dev.c:3473 [inline] dev_hard_start_xmit+0x1eb/0x920 net/core/dev.c:3489 sch_direct_xmit+0x19f/0xbc0 net/sched/sch_generic.c:342 qdisc_restart net/sched/sch_generic.c:407 [inline] __qdisc_run+0x4bc/0x1700 net/sched/sch_generic.c:415 __dev_xmit_skb net/core/dev.c:3758 [inline] __dev_queue_xmit+0x2084/0x3620 net/core/dev.c:4077 packet_snd net/packet/af_packet.c:3052 [inline] packet_sendmsg+0x224c/0x5490 net/packet/af_packet.c:3079 sock_sendmsg_nosec net/socket.c:704 [inline] sock_sendmsg+0xcf/0x120 net/socket.c:724 __sys_sendto+0x21c/0x320 net/socket.c:2036 __do_sys_sendto net/socket.c:2048 [inline] __se_sys_sendto net/socket.c:2044 [inline] __x64_sys_sendto+0xdd/0x1b0 net/socket.c:2044 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x44/0xae RIP: 0033:0x7f441897dae9 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:00007f4415ef3188 EFLAGS: 00000246 ORIG_RAX: 000000000000002c RAX: ffffffffffffffda RBX: 00007f4418a90f60 RCX: 00007f441897dae9 RDX: 0000000000003287 RSI: 0000000020000080 RDI: 0000000000000003 RBP: 00007f44189d7f6d R08: 0000000000000000 R09: 00000000000002ff R10: 0000000004000002 R11: 0000000000000246 R12: 0000000000000000 R13: 00007ffde7eccecf R14: 00007f4415ef3300 R15: 0000000000022000 Allocated by task 15735: kasan_save_stack+0x1e/0x50 mm/kasan/common.c:38 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 mm/kasan/common.c:472 [inline] __kasan_kmalloc+0xa9/0xd0 mm/kasan/common.c:522 kmalloc include/linux/slab.h:590 [inline] kzalloc include/linux/slab.h:724 [inline] ieee802_11_parse_elems_crc+0xd5/0x1050 net/mac80211/util.c:1471 ieee802_11_parse_elems net/mac80211/ieee80211_i.h:2208 [inline] ieee80211_bss_info_update+0x42c/0xb30 net/mac80211/scan.c:212 ieee80211_rx_bss_info net/mac80211/ibss.c:1119 [inline] ieee80211_rx_mgmt_probe_beacon net/mac80211/ibss.c:1610 [inline] ieee80211_ibss_rx_queued_mgmt+0x19cf/0x3130 net/mac80211/ibss.c:1639 ieee80211_iface_process_skb net/mac80211/iface.c:1468 [inline] ieee80211_iface_work+0xa65/0xd00 net/mac80211/iface.c:1522 process_one_work+0x9b2/0x1690 kernel/workqueue.c:2299 worker_thread+0x658/0x11f0 kernel/workqueue.c:2446 kthread+0x405/0x4f0 kernel/kthread.c:345 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295 The buggy address belongs to the object at ffff88803f5b3800 which belongs to the cache kmalloc-1k of size 1024 The buggy address is located 2 bytes to the right of 1024-byte region [ffff88803f5b3800, ffff88803f5b3c00) The buggy address belongs to the page: page:ffffea0000fd6c00 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x3f5b0 head:ffffea0000fd6c00 order:3 compound_mapcount:0 compound_pincount:0 flags: 0xfff00000010200(slab|head|node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000010200 dead000000000100 dead000000000122 ffff888010c41dc0 raw: 0000000000000000 0000000080100010 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 0x1d2820(GFP_ATOMIC|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC|__GFP_HARDWALL), pid 16303, ts 1710194017697, free_ts 1709646495460 prep_new_page mm/page_alloc.c:2433 [inline] get_page_from_freelist+0xa72/0x2f40 mm/page_alloc.c:4164 __alloc_pages+0x1b2/0x500 mm/page_alloc.c:5376 alloc_pages+0x1a7/0x300 mm/mempolicy.c:2192 alloc_slab_page mm/slub.c:1793 [inline] allocate_slab mm/slub.c:1930 [inline] new_slab+0x261/0x460 mm/slub.c:1993 ___slab_alloc+0x798/0xf30 mm/slub.c:3022 __slab_alloc.constprop.0+0x4d/0xa0 mm/slub.c:3109 slab_alloc_node mm/slub.c:3200 [inline] __kmalloc_node_track_caller+0x2cb/0x360 mm/slub.c:4956 kmalloc_reserve net/core/skbuff.c:354 [inline] __alloc_skb+0xde/0x340 net/core/skbuff.c:426 alloc_skb include/linux/skbuff.h:1127 [inline] nlmsg_new include/net/netlink.h:953 [inline] inet6_rt_notify+0xec/0x2b0 net/ipv6/route.c:6149 fib6_add_rt2node net/ipv6/ip6_fib.c:1250 [inline] fib6_add+0x26e7/0x3f10 net/ipv6/ip6_fib.c:1476 __ip6_ins_rt net/ipv6/route.c:1300 [inline] ip6_ins_rt+0xb2/0x110 net/ipv6/route.c:1310 __ipv6_ifa_notify+0x84e/0xa90 net/ipv6/addrconf.c:6114 ipv6_ifa_notify net/ipv6/addrconf.c:6153 [inline] addrconf_dad_completed+0x150/0xd60 net/ipv6/addrconf.c:4178 addrconf_dad_work+0x79f/0x1340 net/ipv6/addrconf.c:4126 process_one_work+0x9b2/0x1690 kernel/workqueue.c:2299 worker_thread+0x658/0x11f0 kernel/workqueue.c:2446 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1351 [inline] free_pcp_prepare+0x414/0xb60 mm/page_alloc.c:1403 free_unref_page_prepare mm/page_alloc.c:3324 [inline] free_unref_page+0x19/0x690 mm/page_alloc.c:3403 __unfreeze_partials+0x19f/0x1c0 mm/slub.c:2527 qlink_free mm/kasan/quarantine.c:146 [inline] qlist_free_all+0x5a/0xf0 mm/kasan/quarantine.c:165 kasan_quarantine_reduce+0x180/0x200 mm/kasan/quarantine.c:272 __kasan_slab_alloc+0xa2/0xc0 mm/kasan/common.c:444 kasan_slab_alloc include/linux/kasan.h:259 [inline] slab_post_alloc_hook mm/slab.h:519 [inline] slab_alloc_node mm/slub.c:3234 [inline] kmem_cache_alloc_node+0x255/0x3f0 mm/slub.c:3270 __alloc_skb+0x215/0x340 net/core/skbuff.c:414 alloc_skb include/linux/skbuff.h:1127 [inline] alloc_skb_with_frags+0x93/0x730 net/core/skbuff.c:5930 sock_alloc_send_pskb+0x793/0x920 net/core/sock.c:2579 mld_newpack+0x1df/0x770 net/ipv6/mcast.c:1754 add_grhead+0x265/0x330 net/ipv6/mcast.c:1857 add_grec+0x1053/0x14e0 net/ipv6/mcast.c:1995 mld_send_initial_cr.part.0+0xf6/0x230 net/ipv6/mcast.c:2242 mld_send_initial_cr net/ipv6/mcast.c:1232 [inline] ipv6_mc_dad_complete+0x1d0/0x690 net/ipv6/mcast.c:2253 addrconf_dad_completed+0xa20/0xd60 net/ipv6/addrconf.c:4196 Memory state around the buggy address: ffff88803f5b3b00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff88803f5b3b80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff88803f5b3c00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff88803f5b3c80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff88803f5b3d00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================