[ 10.887246][ T263] ip (263) used greatest stack depth: 23168 bytes left [ 12.208059][ T11] ================================================================== [ 12.208312][ T11] BUG: KASAN: slab-use-after-free in cleanup_net+0xa5d/0xb90 [ 12.208531][ T11] Read of size 8 at addr ffff8880097000f8 by task kworker/u16:0/11 [ 12.208739][ T11] [ 12.208813][ T11] CPU: 0 UID: 0 PID: 11 Comm: kworker/u16:0 Not tainted 6.12.0-virtme #1 [ 12.209026][ T11] Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011 [ 12.209204][ T11] Workqueue: netns cleanup_net [ 12.209349][ T11] Call Trace: [ 12.209465][ T11] [ 12.209539][ T11] dump_stack_lvl+0x82/0xd0 [ 12.209688][ T11] print_address_description.constprop.0+0x2c/0x3b0 [ 12.209865][ T11] ? cleanup_net+0xa5d/0xb90 [ 12.210002][ T11] print_report+0xb4/0x270 [ 12.210138][ T11] ? kasan_addr_to_slab+0x25/0x80 [ 12.210277][ T11] kasan_report+0xbd/0xf0 [ 12.210381][ T11] ? cleanup_net+0xa5d/0xb90 [ 12.210517][ T11] cleanup_net+0xa5d/0xb90 [ 12.210655][ T11] ? __pfx_lock_acquire.part.0+0x10/0x10 [ 12.210797][ T11] ? __pfx_cleanup_net+0x10/0x10 [ 12.210933][ T11] ? trace_lock_acquire+0x148/0x1f0 [ 12.211074][ T11] ? lock_acquire+0x32/0xc0 [ 12.211211][ T11] ? process_one_work+0xe0b/0x16d0 [ 12.211364][ T11] process_one_work+0xe55/0x16d0 [ 12.211510][ T11] ? __pfx___lock_release+0x10/0x10 [ 12.211655][ T11] ? __pfx_process_one_work+0x10/0x10 [ 12.211799][ T11] ? assign_work+0x16c/0x240 [ 12.211941][ T11] worker_thread+0x58c/0xce0 [ 12.212084][ T11] ? __pfx_worker_thread+0x10/0x10 [ 12.212221][ T11] kthread+0x28a/0x350 [ 12.212331][ T11] ? __pfx_kthread+0x10/0x10 [ 12.212473][ T11] ret_from_fork+0x31/0x70 [ 12.212613][ T11] ? __pfx_kthread+0x10/0x10 [ 12.212752][ T11] ret_from_fork_asm+0x1a/0x30 [ 12.212897][ T11] [ 12.213004][ T11] [ 12.213075][ T11] Allocated by task 255: [ 12.213184][ T11] kasan_save_stack+0x24/0x50 [ 12.213326][ T11] kasan_save_track+0x14/0x30 [ 12.213462][ T11] __kasan_slab_alloc+0x59/0x70 [ 12.213602][ T11] kmem_cache_alloc_noprof+0x10b/0x350 [ 12.213748][ T11] copy_net_ns+0xc6/0x540 [ 12.213852][ T11] create_new_namespaces+0x35f/0x920 [ 12.214002][ T11] unshare_nsproxy_namespaces+0x8a/0x1b0 [ 12.214144][ T11] ksys_unshare+0x2c4/0x6e0 [ 12.214293][ T11] __x64_sys_unshare+0x31/0x40 [ 12.214433][ T11] do_syscall_64+0xc1/0x1d0 [ 12.214576][ T11] entry_SYSCALL_64_after_hwframe+0x77/0x7f [ 12.214750][ T11] [ 12.214823][ T11] Freed by task 11: [ 12.214927][ T11] kasan_save_stack+0x24/0x50 [ 12.215068][ T11] kasan_save_track+0x14/0x30 [ 12.215211][ T11] kasan_save_free_info+0x3b/0x60 [ 12.215355][ T11] __kasan_slab_free+0x38/0x50 [ 12.215496][ T11] kmem_cache_free+0xf8/0x330 [ 12.215635][ T11] cleanup_net+0x5a8/0xb90 [ 12.215774][ T11] process_one_work+0xe55/0x16d0 [ 12.215917][ T11] worker_thread+0x58c/0xce0 [ 12.216059][ T11] kthread+0x28a/0x350 [ 12.216168][ T11] ret_from_fork+0x31/0x70 [ 12.216308][ T11] ret_from_fork_asm+0x1a/0x30 [ 12.216452][ T11] [ 12.216526][ T11] Last potentially related work creation: [ 12.216670][ T11] kasan_save_stack+0x24/0x50 [ 12.216813][ T11] __kasan_record_aux_stack+0x8e/0xa0 [ 12.216960][ T11] insert_work+0x34/0x230 [ 12.217069][ T11] __queue_work+0x5fd/0xa40 [ 12.217212][ T11] queue_delayed_work_on+0x8c/0xa0 [ 12.217351][ T11] __inet_insert_ifa+0x751/0xb10 [ 12.217498][ T11] inet_rtm_newaddr+0x833/0xbd0 [ 12.217641][ T11] rtnetlink_rcv_msg+0x712/0xc10 [ 12.217786][ T11] netlink_rcv_skb+0x130/0x360 [ 12.217933][ T11] netlink_unicast+0x44b/0x710 [ 12.218074][ T11] netlink_sendmsg+0x723/0xbe0 [ 12.218215][ T11] ____sys_sendmsg+0x7ac/0xa10 [ 12.218363][ T11] ___sys_sendmsg+0xee/0x170 [ 12.218511][ T11] __sys_sendmsg+0x109/0x1a0 [ 12.218654][ T11] do_syscall_64+0xc1/0x1d0 [ 12.218798][ T11] entry_SYSCALL_64_after_hwframe+0x77/0x7f [ 12.218981][ T11] [ 12.219059][ T11] Second to last potentially related work creation: [ 12.219235][ T11] kasan_save_stack+0x24/0x50 [ 12.219382][ T11] __kasan_record_aux_stack+0x8e/0xa0 [ 12.219520][ T11] insert_work+0x34/0x230 [ 12.219625][ T11] __queue_work+0x5fd/0xa40 [ 12.219764][ T11] queue_delayed_work_on+0x8c/0xa0 [ 12.219905][ T11] __inet_insert_ifa+0x751/0xb10 [ 12.220048][ T11] inetdev_event+0xb18/0xcf0 [ 12.220190][ T11] notifier_call_chain+0xcd/0x150 [ 12.220328][ T11] __dev_notify_flags+0xe6/0x250 [ 12.220465][ T11] dev_change_flags+0xec/0x160 [ 12.220604][ T11] do_setlink.constprop.0+0x79d/0x2300 [ 12.220742][ T11] rtnl_newlink+0x6de/0xa80 [ 12.220878][ T11] rtnetlink_rcv_msg+0x712/0xc10 [ 12.221019][ T11] netlink_rcv_skb+0x130/0x360 [ 12.221166][ T11] netlink_unicast+0x44b/0x710 [ 12.221308][ T11] netlink_sendmsg+0x723/0xbe0 [ 12.221458][ T11] ____sys_sendmsg+0x7ac/0xa10 [ 12.221601][ T11] ___sys_sendmsg+0xee/0x170 [ 12.221747][ T11] __sys_sendmsg+0x109/0x1a0 [ 12.221890][ T11] do_syscall_64+0xc1/0x1d0 [ 12.222033][ T11] entry_SYSCALL_64_after_hwframe+0x77/0x7f [ 12.222215][ T11] [ 12.222287][ T11] The buggy address belongs to the object at ffff888009700040 [ 12.222287][ T11] which belongs to the cache net_namespace of size 6528 [ 12.222664][ T11] The buggy address is located 184 bytes inside of [ 12.222664][ T11] freed 6528-byte region [ffff888009700040, ffff8880097019c0) [ 12.223015][ T11] [ 12.223090][ T11] The buggy address belongs to the physical page: [ 12.223269][ T11] page: refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff888009703640 pfn:0x9700 [ 12.223555][ T11] head: order:3 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0 [ 12.223777][ T11] flags: 0x80000000000240(workingset|head|node=0|zone=1) [ 12.223968][ T11] page_type: f5(slab) [ 12.224083][ T11] raw: 0080000000000240 ffff888001975240 ffff88800197a088 ffff88800197a088 [ 12.224345][ T11] raw: ffff888009703640 0000000000040002 00000001f5000000 0000000000000000 [ 12.224596][ T11] head: 0080000000000240 ffff888001975240 ffff88800197a088 ffff88800197a088 [ 12.224852][ T11] head: ffff888009703640 0000000000040002 00000001f5000000 0000000000000000 [ 12.225100][ T11] head: 0080000000000003 ffffea000025c001 ffffffffffffffff 0000000000000000 [ 12.225356][ T11] head: 0000000000000008 0000000000000000 00000000ffffffff 0000000000000000 [ 12.225606][ T11] page dumped because: kasan: bad access detected [ 12.225786][ T11] [ 12.225855][ T11] Memory state around the buggy address: [ 12.225987][ T11] ffff8880096fff80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.226192][ T11] ffff888009700000: fc fc fc fc fc fc fc fc fa fb fb fb fb fb fb fb [ 12.226395][ T11] >ffff888009700080: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 12.226593][ T11] ^ [ 12.226795][ T11] ffff888009700100: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 12.226991][ T11] ffff888009700180: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 12.227189][ T11] ================================================================== [ 12.227425][ T11] Disabling lock debugging due to kernel taint