====================================== | [ 164.646057][ T945] ================================================================== | [ 164.646452][ T945] BUG: KASAN: slab-use-after-free in kobject_put (lib/kobject.c:733) | [ 164.646789][ T945] Read of size 1 at addr ffff88800e6496ac by task ip/945 | [ 164.647066][ T945] [ 164.647186][ T945] Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011 [ 164.647188][ T945] Call Trace: [ 164.647190][ T945] [ 164.647193][ T945] dump_stack_lvl (lib/dump_stack.c:123) [ 164.647200][ T945] print_address_description.constprop.0 (mm/kasan/report.c:379) [ 164.647208][ T945] ? kobject_put (lib/kobject.c:733) [ 164.647212][ T945] print_report (mm/kasan/report.c:483) [ 164.647215][ T945] ? kobject_put (lib/kobject.c:733) [ 164.647218][ T945] ? kasan_addr_to_slab (./include/linux/mm.h:1245 mm/kasan/../slab.h:191 mm/kasan/common.c:47) [ 164.647222][ T945] ? kobject_put (lib/kobject.c:733) [ 164.647225][ T945] kasan_report (mm/kasan/report.c:597) [ 164.647229][ T945] ? kobject_put (lib/kobject.c:733) [ 164.647234][ T945] kobject_put (lib/kobject.c:733) [ 164.647237][ T945] netdev_run_todo (./include/linux/list.h:381 net/core/dev.c:11670) [ 164.647243][ T945] ? dev_ingress_queue_create (net/core/dev.c:12299) [ 164.647246][ T945] ? generic_xdp_install (net/core/dev.c:11630) [ 164.647251][ T945] ? vrf_dellink (drivers/net/vrf.c:1667) vrf [ 164.647258][ T945] ? vrf_map_unregister_dev (drivers/net/vrf.c:1667) vrf [ 164.647263][ T945] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 164.647276][ T945] rtnl_dellink (net/core/rtnetlink.c:3580) [ 164.647285][ T945] ? valid_bridge_getlink_req.constprop.0 (net/core/rtnetlink.c:3536) [ 164.647306][ T945] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 164.647311][ T945] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 164.647317][ T945] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 164.647320][ T945] ? rtnetlink_rcv_msg (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:897 net/core/rtnetlink.c:6956) [ 164.647323][ T945] ? __lock_release (kernel/locking/lockdep.c:5536) [ 164.647327][ T945] ? valid_bridge_getlink_req.constprop.0 (net/core/rtnetlink.c:3536) [ 164.647330][ T945] rtnetlink_rcv_msg (net/core/rtnetlink.c:6958) [ 164.647334][ T945] ? rtnl_port_fill (net/core/rtnetlink.c:6861) [ 164.647337][ T945] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 164.647343][ T945] netlink_rcv_skb (net/netlink/af_netlink.c:2550) [ 164.647348][ T945] ? rtnl_port_fill (net/core/rtnetlink.c:6861) [ 164.647351][ T945] ? netlink_ack (net/netlink/af_netlink.c:2527) [ 164.647358][ T945] ? netlink_deliver_tap (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:897 net/netlink/af_netlink.c:340) [ 164.647360][ T945] ? netlink_deliver_tap (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:897 ./include/net/netns/generic.h:48 net/netlink/af_netlink.c:333) [ 164.647364][ T945] netlink_unicast (net/netlink/af_netlink.c:1319 net/netlink/af_netlink.c:1344) [ 164.647368][ T945] ? netlink_attachskb (net/netlink/af_netlink.c:1329) [ 164.647372][ T945] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 164.647377][ T945] netlink_sendmsg (net/netlink/af_netlink.c:1894) [ 164.647382][ T945] ? netlink_unicast (net/netlink/af_netlink.c:1813) [ 164.647386][ T945] ? __import_iovec (lib/iov_iter.c:1346 lib/iov_iter.c:1361) [ 164.647392][ T945] ? netlink_unicast (net/netlink/af_netlink.c:1813) [ 164.647395][ T945] ____sys_sendmsg (net/socket.c:727 net/socket.c:742 net/socket.c:2630) [ 164.647405][ T945] ? get_timestamp.constprop.0 (net/socket.c:2576) [ 164.647408][ T945] ? __copy_msghdr (net/socket.c:2556) [ 164.647417][ T945] ___sys_sendmsg (net/socket.c:2686) [ 164.647420][ T945] ? kasan_record_aux_stack (mm/kasan/generic.c:559) [ 164.647422][ T945] ? __call_rcu_common.constprop.0 (./arch/x86/include/asm/irqflags.h:26 ./arch/x86/include/asm/irqflags.h:109 ./arch/x86/include/asm/irqflags.h:127 kernel/rcu/tree.c:3125) [ 164.647431][ T945] ? copy_msghdr_from_user (net/socket.c:2673) [ 164.647436][ T945] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 164.647440][ T945] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 164.647446][ T945] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 164.647449][ T945] ? __virt_addr_valid (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:979 ./include/linux/mmzone.h:2197 arch/x86/mm/physaddr.c:65) [ 164.647455][ T945] ? __lock_release (kernel/locking/lockdep.c:5536) [ 164.647462][ T945] __sys_sendmsg (net/socket.c:2716) [ 164.647465][ T945] ? __call_rcu_common.constprop.0 (kernel/rcu/tree.c:3148) [ 164.647469][ T945] ? __sys_sendmsg_sock (net/socket.c:2701) [ 164.647476][ T945] ? rcu_is_watching (./include/linux/context_tracking.h:128 kernel/rcu/tree.c:751) [ 164.647481][ T945] do_syscall_64 (arch/x86/entry/syscall_64.c:63 arch/x86/entry/syscall_64.c:94) [ 164.647487][ T945] entry_SYSCALL_64_after_hwframe (arch/x86/entry/entry_64.S:130) [ 164.647491][ T945] RIP: 0033:0x7f41502121d7 [ 164.647497][ T945] Code: 0e 00 f7 d8 64 89 02 48 c7 c0 ff ff ff ff eb b9 0f 1f 00 f3 0f 1e fa 64 8b 04 25 18 00 00 00 85 c0 75 10 b8 2e 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 51 c3 48 83 ec 28 89 54 24 1c 48 89 74 24 10 All code ======== 0: 0e (bad) 1: 00 f7 add %dh,%bh 3: d8 64 89 02 fsubs 0x2(%rcx,%rcx,4) 7: 48 c7 c0 ff ff ff ff mov $0xffffffffffffffff,%rax e: eb b9 jmp 0xffffffffffffffc9 10: 0f 1f 00 nopl (%rax) 13: f3 0f 1e fa endbr64 17: 64 8b 04 25 18 00 00 mov %fs:0x18,%eax 1e: 00 1f: 85 c0 test %eax,%eax 21: 75 10 jne 0x33 23: b8 2e 00 00 00 mov $0x2e,%eax 28: 0f 05 syscall 2a:* 48 3d 00 f0 ff ff cmp $0xfffffffffffff000,%rax <-- trapping instruction 30: 77 51 ja 0x83 32: c3 ret 33: 48 83 ec 28 sub $0x28,%rsp 37: 89 54 24 1c mov %edx,0x1c(%rsp) 3b: 48 89 74 24 10 mov %rsi,0x10(%rsp) Code starting with the faulting instruction =========================================== 0: 48 3d 00 f0 ff ff cmp $0xfffffffffffff000,%rax 6: 77 51 ja 0x59 8: c3 ret 9: 48 83 ec 28 sub $0x28,%rsp d: 89 54 24 1c mov %edx,0x1c(%rsp) 11: 48 89 74 24 10 mov %rsi,0x10(%rsp) [ 164.647500][ T945] RSP: 002b:00007ffd5860f798 EFLAGS: 00000246 ORIG_RAX: 000000000000002e [ 164.647506][ T945] RAX: ffffffffffffffda RBX: 00007ffd5860fec0 RCX: 00007f41502121d7 [ 164.647508][ T945] RDX: 0000000000000000 RSI: 00007ffd5860f800 RDI: 0000000000000005 [ 164.647510][ T945] RBP: 0000000000000002 R08: 0000000000000003 R09: 0000000000000078 [ 164.647512][ T945] R10: 00007f415010ef60 R11: 0000000000000246 R12: 0000000000000002 [ 164.647513][ T945] R13: 00000000690dea71 R14: 0000000000499600 R15: 0000000000000000 | [ 164.681390][ T945] refcount_t: underflow; use-after-free. | [ 164.681741][ T945] WARNING: CPU: 2 PID: 945 at lib/refcount.c:28 refcount_warn_saturate (lib/refcount.c:28 (discriminator 3)) | [ 164.682231][ T945] Modules linked in: act_mirred act_gact act_police cls_flower sch_ingress vrf veth | [ 164.683358][ T945] Tainted: [B]=BAD_PAGE [ 164.683595][ T945] Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011 [ 164.683965][ T945] RIP: 0010:refcount_warn_saturate (lib/refcount.c:28 (discriminator 3)) [ 164.684566][ T945] Code: 7d 93 02 80 fb 01 0f 87 bb 99 d9 fe 83 e3 01 0f 85 51 ff ff ff c6 05 a8 7d 93 02 01 90 48 c7 c7 60 8d 65 ac e8 32 bf 18 ff 90 <0f> 0b 90 90 e9 33 ff ff ff 48 89 df e8 b0 63 a1 ff e9 ba fe ff ff All code ======== 0: 7d 93 jge 0xffffffffffffff95 2: 02 80 fb 01 0f 87 add -0x78f0fe05(%rax),%al 8: bb 99 d9 fe 83 mov $0x83fed999,%ebx d: e3 01 jrcxz 0x10 f: 0f 85 51 ff ff ff jne 0xffffffffffffff66 15: c6 05 a8 7d 93 02 01 movb $0x1,0x2937da8(%rip) # 0x2937dc4 1c: 90 nop 1d: 48 c7 c7 60 8d 65 ac mov $0xffffffffac658d60,%rdi 24: e8 32 bf 18 ff call 0xffffffffff18bf5b 29: 90 nop 2a:* 0f 0b ud2 <-- trapping instruction 2c: 90 nop 2d: 90 nop 2e: e9 33 ff ff ff jmp 0xffffffffffffff66 33: 48 89 df mov %rbx,%rdi 36: e8 b0 63 a1 ff call 0xffffffffffa163eb 3b: e9 ba fe ff ff jmp 0xfffffffffffffefa Code starting with the faulting instruction =========================================== 0: 0f 0b ud2 2: 90 nop 3: 90 nop 4: e9 33 ff ff ff jmp 0xffffffffffffff3c 9: 48 89 df mov %rbx,%rdi c: e8 b0 63 a1 ff call 0xffffffffffa163c1 11: e9 ba fe ff ff jmp 0xfffffffffffffed0 [ 164.685816][ T945] RSP: 0018:ffffc9000115f1f0 EFLAGS: 00010286 [ 164.686378][ T945] RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000000 [ 164.687005][ T945] RDX: 0000000000000002 RSI: 0000000000000004 RDI: 0000000000000001 [ 164.687467][ T945] RBP: 0000000000000003 R08: 0000000000000000 R09: fffffbfff59fe134 [ 164.687903][ T945] R10: 0000000000000003 R11: ffffc9000115ed80 R12: 0000000000000001 [ 164.688375][ T945] R13: dffffc0000000000 R14: dead000000000122 R15: dead000000000100 [ 164.689003][ T945] FS: 00007f4150044800(0000) GS:ffff888087ef2000(0000) knlGS:0000000000000000 [ 164.689519][ T945] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 164.689903][ T945] CR2: 000055fe7500c408 CR3: 0000000008d4f004 CR4: 0000000000772ef0 [ 164.690388][ T945] PKRU: 55555554 [ 164.690629][ T945] Call Trace: [ 164.690868][ T945] [ 164.691046][ T945] netdev_run_todo (./include/linux/list.h:381 net/core/dev.c:11670) [ 164.691374][ T945] ? dev_ingress_queue_create (net/core/dev.c:12299) [ 164.691668][ T945] ? generic_xdp_install (net/core/dev.c:11630) [ 164.691980][ T945] ? vrf_dellink (drivers/net/vrf.c:1667) vrf [ 164.692488][ T945] ? vrf_map_unregister_dev (drivers/net/vrf.c:1667) vrf [ 164.692872][ T945] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 164.693190][ T945] rtnl_dellink (net/core/rtnetlink.c:3580) [ 164.693696][ T945] ? valid_bridge_getlink_req.constprop.0 (net/core/rtnetlink.c:3536) [ 164.694103][ T945] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 164.694424][ T945] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 164.694732][ T945] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 164.695283][ T945] ? rtnetlink_rcv_msg (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:897 net/core/rtnetlink.c:6956) [ 164.695609][ T945] ? __lock_release (kernel/locking/lockdep.c:5536) [ 164.695919][ T945] ? valid_bridge_getlink_req.constprop.0 (net/core/rtnetlink.c:3536) [ 164.696291][ T945] rtnetlink_rcv_msg (net/core/rtnetlink.c:6958) [ 164.696797][ T945] ? rtnl_port_fill (net/core/rtnetlink.c:6861) [ 164.697104][ T945] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 164.697421][ T945] netlink_rcv_skb (net/netlink/af_netlink.c:2550) [ 164.697720][ T945] ? rtnl_port_fill (net/core/rtnetlink.c:6861) [ 164.698206][ T945] ? netlink_ack (net/netlink/af_netlink.c:2527) [ 164.698533][ T945] ? netlink_deliver_tap (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:897 net/netlink/af_netlink.c:340) [ 164.698833][ T945] ? netlink_deliver_tap (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:897 ./include/net/netns/generic.h:48 net/netlink/af_netlink.c:333) [ 164.699146][ T945] netlink_unicast (net/netlink/af_netlink.c:1319 net/netlink/af_netlink.c:1344) [ 164.699472][ T945] ? netlink_attachskb (net/netlink/af_netlink.c:1329) [ 164.699776][ T945] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 164.700094][ T945] netlink_sendmsg (net/netlink/af_netlink.c:1894) [ 164.700411][ T945] ? netlink_unicast (net/netlink/af_netlink.c:1813) [ 164.700913][ T945] ? __import_iovec (lib/iov_iter.c:1346 lib/iov_iter.c:1361) [ 164.701224][ T945] ? netlink_unicast (net/netlink/af_netlink.c:1813) [ 164.701538][ T945] ____sys_sendmsg (net/socket.c:727 net/socket.c:742 net/socket.c:2630) [ 164.702017][ T945] ? get_timestamp.constprop.0 (net/socket.c:2576) [ 164.702566][ T945] ? __copy_msghdr (net/socket.c:2556) [ 164.703052][ T945] ___sys_sendmsg (net/socket.c:2686) [ 164.703366][ T945] ? kasan_record_aux_stack (mm/kasan/generic.c:559) [ 164.703683][ T945] ? __call_rcu_common.constprop.0 (./arch/x86/include/asm/irqflags.h:26 ./arch/x86/include/asm/irqflags.h:109 ./arch/x86/include/asm/irqflags.h:127 kernel/rcu/tree.c:3125) [ 164.704229][ T945] ? copy_msghdr_from_user (net/socket.c:2673) [ 164.704558][ T945] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 164.704904][ T945] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 164.705217][ T945] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 164.705742][ T945] ? __virt_addr_valid (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:979 ./include/linux/mmzone.h:2197 arch/x86/mm/physaddr.c:65) [ 164.706074][ T945] ? __lock_release (kernel/locking/lockdep.c:5536) [ 164.706397][ T945] __sys_sendmsg (net/socket.c:2716) [ 164.706715][ T945] ? __call_rcu_common.constprop.0 (kernel/rcu/tree.c:3148) [ 164.707283][ T945] ? __sys_sendmsg_sock (net/socket.c:2701) [ 164.707606][ T945] ? rcu_is_watching (./include/linux/context_tracking.h:128 kernel/rcu/tree.c:751) [ 164.707971][ T945] do_syscall_64 (arch/x86/entry/syscall_64.c:63 arch/x86/entry/syscall_64.c:94) [ 164.708468][ T945] entry_SYSCALL_64_after_hwframe (arch/x86/entry/entry_64.S:130) [ 164.708826][ T945] RIP: 0033:0x7f41502121d7 [ 164.709158][ T945] Code: 0e 00 f7 d8 64 89 02 48 c7 c0 ff ff ff ff eb b9 0f 1f 00 f3 0f 1e fa 64 8b 04 25 18 00 00 00 85 c0 75 10 b8 2e 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 51 c3 48 83 ec 28 89 54 24 1c 48 89 74 24 10 All code ======== 0: 0e (bad) 1: 00 f7 add %dh,%bh 3: d8 64 89 02 fsubs 0x2(%rcx,%rcx,4) 7: 48 c7 c0 ff ff ff ff mov $0xffffffffffffffff,%rax e: eb b9 jmp 0xffffffffffffffc9 10: 0f 1f 00 nopl (%rax) 13: f3 0f 1e fa endbr64 17: 64 8b 04 25 18 00 00 mov %fs:0x18,%eax 1e: 00 1f: 85 c0 test %eax,%eax 21: 75 10 jne 0x33 23: b8 2e 00 00 00 mov $0x2e,%eax 28: 0f 05 syscall 2a:* 48 3d 00 f0 ff ff cmp $0xfffffffffffff000,%rax <-- trapping instruction 30: 77 51 ja 0x83 32: c3 ret 33: 48 83 ec 28 sub $0x28,%rsp 37: 89 54 24 1c mov %edx,0x1c(%rsp) 3b: 48 89 74 24 10 mov %rsi,0x10(%rsp) Code starting with the faulting instruction =========================================== 0: 48 3d 00 f0 ff ff cmp $0xfffffffffffff000,%rax 6: 77 51 ja 0x59 8: c3 ret 9: 48 83 ec 28 sub $0x28,%rsp d: 89 54 24 1c mov %edx,0x1c(%rsp) 11: 48 89 74 24 10 mov %rsi,0x10(%rsp) [ 164.710401][ T945] RSP: 002b:00007ffd5860f798 EFLAGS: 00000246 ORIG_RAX: 000000000000002e [ 164.710880][ T945] RAX: ffffffffffffffda RBX: 00007ffd5860fec0 RCX: 00007f41502121d7 [ 164.711550][ T945] RDX: 0000000000000000 RSI: 00007ffd5860f800 RDI: 0000000000000005 [ 164.712025][ T945] RBP: 0000000000000002 R08: 0000000000000003 R09: 0000000000000078 [ 164.712690][ T945] R10: 00007f415010ef60 R11: 0000000000000246 R12: 0000000000000002 Finger prints: print_report:kasan_report:kobject_put:netdev_run_todo:rtnl_dellink refcount_warn_saturate:netdev_run_todo:rtnl_dellink:rtnetlink_rcv_msg:netlink_rcv_skb