====================================== | [ 62.408481][ T11] ================================================================== | [ 62.408965][ T11] BUG: KASAN: slab-use-after-free in vxlan_netdevice_event (drivers/net/vxlan/vxlan_core.c:4613 drivers/net/vxlan/vxlan_core.c:4636) vxlan | [ 62.409471][ T11] Read of size 8 at addr ffff888009068bf0 by task kworker/u8:0/11 | [ 62.409888][ T11] [ 62.410425][ T11] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.16.3-0-ga6ed6b701f0a-prebuilt.qemu.org 04/01/2014 [ 62.411061][ T11] Workqueue: netns cleanup_net [ 62.411343][ T11] Call Trace: [ 62.411535][ T11] [ 62.411685][ T11] dump_stack_lvl (lib/dump_stack.c:107) [ 62.411925][ T11] print_address_description.constprop.0 (mm/kasan/report.c:378) [ 62.412278][ T11] ? vxlan_netdevice_event (drivers/net/vxlan/vxlan_core.c:4613 drivers/net/vxlan/vxlan_core.c:4636) vxlan [ 62.412630][ T11] print_report (mm/kasan/report.c:489) [ 62.412877][ T11] ? kasan_addr_to_slab (./arch/x86/include/asm/bitops.h:206 ./arch/x86/include/asm/bitops.h:238 ./include/asm-generic/bitops/instrumented-non-atomic.h:142 ./include/linux/page-flags.h:481 mm/kasan/../slab.h:206 mm/kasan/common.c:38) [ 62.413149][ T11] kasan_report (mm/kasan/report.c:603) [ 62.413393][ T11] ? vxlan_netdevice_event (drivers/net/vxlan/vxlan_core.c:4613 drivers/net/vxlan/vxlan_core.c:4636) vxlan [ 62.413739][ T11] vxlan_netdevice_event (drivers/net/vxlan/vxlan_core.c:4613 drivers/net/vxlan/vxlan_core.c:4636) vxlan [ 62.414068][ T11] ? __pfx_vxlan_netdevice_event (drivers/net/vxlan/vxlan_core.c:4631) vxlan [ 62.414414][ T11] ? netconsole_netdev_event (drivers/net/netconsole.c:991) [ 62.414726][ T11] notifier_call_chain (kernel/notifier.c:93) [ 62.415013][ T11] unregister_netdevice_many_notify (net/core/dev.c:11095) [ 62.415352][ T11] ? mutex_is_locked (./arch/x86/include/asm/atomic64_64.h:15 ./include/linux/atomic/atomic-arch-fallback.h:2569 ./include/linux/atomic/atomic-long.h:38 ./include/linux/atomic/atomic-instrumented.h:3161 kernel/locking/mutex.c:81 kernel/locking/mutex.c:91) [ 62.415602][ T11] ? __pfx_unregister_netdevice_many_notify (net/core/dev.c:11035) [ 62.415959][ T11] ? __pfx_unregister_netdevice_queue (net/core/dev.c:11019) [ 62.416300][ T11] default_device_exit_batch (net/core/dev.c:11629) [ 62.416600][ T11] ? __pfx_default_device_exit_batch (net/core/dev.c:11604) [ 62.416908][ T11] ? mutex_is_locked (./arch/x86/include/asm/atomic64_64.h:15 ./include/linux/atomic/atomic-arch-fallback.h:2569 ./include/linux/atomic/atomic-long.h:38 ./include/linux/atomic/atomic-instrumented.h:3161 kernel/locking/mutex.c:81 kernel/locking/mutex.c:91) [ 62.417146][ T11] ? nexthop_net_exit_batch_rtnl (net/ipv4/nexthop.c:569 net/ipv4/nexthop.c:1918 net/ipv4/nexthop.c:2426 net/ipv4/nexthop.c:3754) [ 62.417444][ T11] cleanup_net (net/core/net_namespace.c:636 (discriminator 3)) [ 62.417670][ T11] ? __pfx_lock_acquire.part.0 (kernel/locking/lockdep.c:5719) [ 62.417950][ T11] ? __pfx_cleanup_net (net/core/net_namespace.c:581) [ 62.418199][ T11] ? lock_acquire (./include/trace/events/lock.h:24 kernel/locking/lockdep.c:5725) [ 62.418436][ T11] ? process_one_work (kernel/workqueue.c:2609) [ 62.418695][ T11] process_one_work (kernel/workqueue.c:2633) [ 62.418943][ T11] ? hlock_class (./arch/x86/include/asm/bitops.h:227 ./arch/x86/include/asm/bitops.h:239 ./include/asm-generic/bitops/instrumented-non-atomic.h:142 kernel/locking/lockdep.c:228) [ 62.419172][ T11] ? __pfx_process_one_work (kernel/workqueue.c:2542) [ 62.419445][ T11] ? assign_work (kernel/workqueue.c:1101) [ 62.419680][ T11] worker_thread (kernel/workqueue.c:2700 kernel/workqueue.c:2787) [ 62.419919][ T11] ? __pfx_worker_thread (kernel/workqueue.c:2733) [ 62.420174][ T11] kthread (kernel/kthread.c:388) [ 62.420380][ T11] ? __pfx_kthread (kernel/kthread.c:341) [ 62.420610][ T11] ret_from_fork (arch/x86/kernel/process.c:147) [ 62.420835][ T11] ? __pfx_kthread (kernel/kthread.c:341) [ 62.421065][ T11] ret_from_fork_asm (arch/x86/entry/entry_64.S:250) | [ 62.441260][ T11] #PF: supervisor read access in kernel mode | [ 62.441571][ T11] #PF: error_code(0x0000) - not-present page | [ 62.441865][ T11] PGD df37067 P4D df37067 PUD 0 | [ 62.442116][ T11] Oops: 0000 [#1] PREEMPT SMP KASAN NOPTI [ 62.442865][ T11] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.16.3-0-ga6ed6b701f0a-prebuilt.qemu.org 04/01/2014 [ 62.443478][ T11] Workqueue: netns cleanup_net [ 62.443720][ T11] RIP: 0010:vxlan_netdevice_event (drivers/net/vxlan/vxlan_core.c:4613 drivers/net/vxlan/vxlan_core.c:4636) vxlan [ 62.444069][ T11] Code: fc ff df 49 89 c0 48 89 44 24 08 49 c1 e8 03 4d 8d 24 08 eb 2c 48 8d 53 30 48 89 d0 48 c1 e8 03 80 3c 08 00 0f 85 e0 00 00 00 <48> 8b 43 30 49 89 dd 48 83 e8 30 49 39 d6 0f 84 83 00 00 00 48 89 All code ======== 0: fc cld 1: ff (bad) 2: df 49 89 fisttps -0x77(%rcx) 5: c0 48 89 44 rorb $0x44,-0x77(%rax) 9: 24 08 and $0x8,%al b: 49 c1 e8 03 shr $0x3,%r8 f: 4d 8d 24 08 lea (%r8,%rcx,1),%r12 13: eb 2c jmp 0x41 15: 48 8d 53 30 lea 0x30(%rbx),%rdx 19: 48 89 d0 mov %rdx,%rax 1c: 48 c1 e8 03 shr $0x3,%rax 20: 80 3c 08 00 cmpb $0x0,(%rax,%rcx,1) 24: 0f 85 e0 00 00 00 jne 0x10a 2a:* 48 8b 43 30 mov 0x30(%rbx),%rax <-- trapping instruction 2e: 49 89 dd mov %rbx,%r13 31: 48 83 e8 30 sub $0x30,%rax 35: 49 39 d6 cmp %rdx,%r14 38: 0f 84 83 00 00 00 je 0xc1 3e: 48 rex.W 3f: 89 .byte 0x89 Code starting with the faulting instruction =========================================== 0: 48 8b 43 30 mov 0x30(%rbx),%rax 4: 49 89 dd mov %rbx,%r13 7: 48 83 e8 30 sub $0x30,%rax b: 49 39 d6 cmp %rdx,%r14 e: 0f 84 83 00 00 00 je 0x97 14: 48 rex.W 15: 89 .byte 0x89 [ 62.445104][ T11] RSP: 0018:ffffc900000bf980 EFLAGS: 00010246 [ 62.445406][ T11] RAX: 1fffffffe0001fff RBX: ffffffff0000ffcf RCX: dffffc0000000000 [ 62.445816][ T11] RDX: ffffffff0000ffff RSI: 0000000000000004 RDI: ffff888009068c44 [ 62.446223][ T11] RBP: 1ffff92000017f33 R08: 1ffff110010ba21a R09: ffffc900000bf9b8 [ 62.446632][ T11] R10: ffffffffa1434a07 R11: 205d313154202020 R12: ffffed10010ba21a [ 62.447039][ T11] R13: ffff888009068bc0 R14: ffff888006bb9000 R15: ffff8880085d1000 [ 62.447430][ T11] FS: 0000000000000000(0000) GS:ffff888035600000(0000) knlGS:0000000000000000 [ 62.447870][ T11] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 62.448196][ T11] CR2: ffffffff0000ffff CR3: 000000000df34005 CR4: 0000000000770ef0 [ 62.448593][ T11] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 [ 62.449000][ T11] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 [ 62.449405][ T11] PKRU: 55555554 [ 62.449600][ T11] Call Trace: [ 62.449768][ T11] [ 62.449929][ T11] ? __die (arch/x86/kernel/dumpstack.c:421 arch/x86/kernel/dumpstack.c:434) [ 62.450126][ T11] ? page_fault_oops (arch/x86/mm/fault.c:707) [ 62.450375][ T11] ? __pfx_page_fault_oops (arch/x86/mm/fault.c:635) [ 62.450641][ T11] ? fixup_exception (arch/x86/mm/extable.c:253) [ 62.450890][ T11] ? exc_page_fault (arch/x86/mm/fault.c:1505 arch/x86/mm/fault.c:1563) [ 62.451129][ T11] ? asm_exc_page_fault (./arch/x86/include/asm/idtentry.h:570) [ 62.451384][ T11] ? vxlan_netdevice_event (drivers/net/vxlan/vxlan_core.c:4613 drivers/net/vxlan/vxlan_core.c:4636) vxlan [ 62.451704][ T11] ? __pfx_vxlan_netdevice_event (drivers/net/vxlan/vxlan_core.c:4631) vxlan [ 62.452038][ T11] ? netconsole_netdev_event (drivers/net/netconsole.c:991) [ 62.452319][ T11] notifier_call_chain (kernel/notifier.c:93) [ 62.452573][ T11] unregister_netdevice_many_notify (net/core/dev.c:11095) [ 62.452890][ T11] ? mutex_is_locked (./arch/x86/include/asm/atomic64_64.h:15 ./include/linux/atomic/atomic-arch-fallback.h:2569 ./include/linux/atomic/atomic-long.h:38 ./include/linux/atomic/atomic-instrumented.h:3161 kernel/locking/mutex.c:81 kernel/locking/mutex.c:91) [ 62.453138][ T11] ? __pfx_unregister_netdevice_many_notify (net/core/dev.c:11035) [ 62.453495][ T11] ? __pfx_unregister_netdevice_queue (net/core/dev.c:11019) [ 62.453854][ T11] default_device_exit_batch (net/core/dev.c:11629) [ 62.454134][ T11] ? __pfx_default_device_exit_batch (net/core/dev.c:11604) [ 62.454455][ T11] ? mutex_is_locked (./arch/x86/include/asm/atomic64_64.h:15 ./include/linux/atomic/atomic-arch-fallback.h:2569 ./include/linux/atomic/atomic-long.h:38 ./include/linux/atomic/atomic-instrumented.h:3161 kernel/locking/mutex.c:81 kernel/locking/mutex.c:91) [ 62.454708][ T11] ? nexthop_net_exit_batch_rtnl (net/ipv4/nexthop.c:569 net/ipv4/nexthop.c:1918 net/ipv4/nexthop.c:2426 net/ipv4/nexthop.c:3754) [ 62.455019][ T11] cleanup_net (net/core/net_namespace.c:636 (discriminator 3)) [ 62.455261][ T11] ? __pfx_lock_acquire.part.0 (kernel/locking/lockdep.c:5719) [ 62.455565][ T11] ? __pfx_cleanup_net (net/core/net_namespace.c:581) [ 62.455836][ T11] ? lock_acquire (./include/trace/events/lock.h:24 kernel/locking/lockdep.c:5725) [ 62.456079][ T11] ? process_one_work (kernel/workqueue.c:2609) [ 62.456356][ T11] process_one_work (kernel/workqueue.c:2633) [ 62.456640][ T11] ? hlock_class (./arch/x86/include/asm/bitops.h:227 ./arch/x86/include/asm/bitops.h:239 ./include/asm-generic/bitops/instrumented-non-atomic.h:142 kernel/locking/lockdep.c:228) [ 62.456887][ T11] ? __pfx_process_one_work (kernel/workqueue.c:2542) [ 62.457172][ T11] ? assign_work (kernel/workqueue.c:1101) [ 62.457402][ T11] worker_thread (kernel/workqueue.c:2700 kernel/workqueue.c:2787) [ 62.457638][ T11] ? __pfx_worker_thread (kernel/workqueue.c:2733) [ 62.457893][ T11] kthread (kernel/kthread.c:388) [ 62.458097][ T11] ? __pfx_kthread (kernel/kthread.c:341) [ 62.458326][ T11] ret_from_fork (arch/x86/kernel/process.c:147) [ 62.458550][ T11] ? __pfx_kthread (kernel/kthread.c:341) Finger prints: dump_stack_lvl:print_report:kasan_report:vxlan_netdevice_event vxlan_netdevice_event:notifier_call_chain:unregister_netdevice_many_notify:default_device_exit_batch