====================================== | [ 34.635997][ T403] ================================================================== | [ 34.636374][ T403] BUG: KASAN: slab-use-after-free in kobject_put (lib/kobject.c:733) | [ 34.636662][ T403] Read of size 1 at addr ffff8880076416ac by task ip/403 | [ 34.636898][ T403] [ 34.637008][ T403] Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011 [ 34.637011][ T403] Call Trace: [ 34.637013][ T403] [ 34.637015][ T403] dump_stack_lvl (lib/dump_stack.c:123) [ 34.637022][ T403] print_address_description.constprop.0 (mm/kasan/report.c:379) [ 34.637029][ T403] ? kobject_put (lib/kobject.c:733) [ 34.637033][ T403] print_report (mm/kasan/report.c:483) [ 34.637036][ T403] ? kobject_put (lib/kobject.c:733) [ 34.637040][ T403] ? kasan_addr_to_slab (./include/linux/mm.h:1245 mm/kasan/../slab.h:191 mm/kasan/common.c:47) [ 34.637043][ T403] ? kobject_put (lib/kobject.c:733) [ 34.637046][ T403] kasan_report (mm/kasan/report.c:597) [ 34.637050][ T403] ? kobject_put (lib/kobject.c:733) [ 34.637055][ T403] kobject_put (lib/kobject.c:733) [ 34.637059][ T403] netdev_run_todo (./include/linux/list.h:381 net/core/dev.c:11670) [ 34.637064][ T403] ? dev_ingress_queue_create (net/core/dev.c:12299) [ 34.637067][ T403] ? generic_xdp_install (net/core/dev.c:11630) [ 34.637072][ T403] ? vrf_dellink (drivers/net/vrf.c:1667) vrf [ 34.637080][ T403] ? vrf_map_unregister_dev (drivers/net/vrf.c:1667) vrf [ 34.637085][ T403] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 34.637094][ T403] rtnl_dellink (net/core/rtnetlink.c:3580) [ 34.637100][ T403] ? valid_bridge_getlink_req.constprop.0 (net/core/rtnetlink.c:3536) [ 34.637118][ T403] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 34.637123][ T403] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 34.637129][ T403] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 34.637133][ T403] ? rtnetlink_rcv_msg (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:897 net/core/rtnetlink.c:6956) [ 34.637135][ T403] ? __lock_release (kernel/locking/lockdep.c:5536) [ 34.637140][ T403] ? valid_bridge_getlink_req.constprop.0 (net/core/rtnetlink.c:3536) [ 34.637143][ T403] rtnetlink_rcv_msg (net/core/rtnetlink.c:6958) [ 34.637147][ T403] ? rtnl_port_fill (net/core/rtnetlink.c:6861) [ 34.637150][ T403] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 34.637157][ T403] netlink_rcv_skb (net/netlink/af_netlink.c:2550) [ 34.637162][ T403] ? rtnl_port_fill (net/core/rtnetlink.c:6861) [ 34.637165][ T403] ? netlink_ack (net/netlink/af_netlink.c:2527) [ 34.637172][ T403] ? netlink_deliver_tap (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:897 net/netlink/af_netlink.c:340) [ 34.637174][ T403] ? 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) [ 34.637178][ T403] netlink_unicast (net/netlink/af_netlink.c:1319 net/netlink/af_netlink.c:1344) [ 34.637183][ T403] ? netlink_attachskb (net/netlink/af_netlink.c:1329) [ 34.637187][ T403] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 34.637192][ T403] netlink_sendmsg (net/netlink/af_netlink.c:1894) [ 34.637196][ T403] ? netlink_unicast (net/netlink/af_netlink.c:1813) [ 34.637200][ T403] ? __import_iovec (lib/iov_iter.c:1346 lib/iov_iter.c:1361) [ 34.637207][ T403] ? netlink_unicast (net/netlink/af_netlink.c:1813) [ 34.637210][ T403] ____sys_sendmsg (net/socket.c:727 net/socket.c:742 net/socket.c:2630) [ 34.637217][ T403] ? get_timestamp.constprop.0 (net/socket.c:2576) [ 34.637220][ T403] ? __copy_msghdr (net/socket.c:2556) [ 34.637228][ T403] ___sys_sendmsg (net/socket.c:2686) [ 34.637231][ T403] ? kasan_record_aux_stack (mm/kasan/generic.c:559) [ 34.637234][ T403] ? __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) [ 34.637240][ T403] ? copy_msghdr_from_user (net/socket.c:2673) [ 34.637245][ T403] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 34.637249][ T403] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 34.637254][ T403] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 34.637258][ T403] ? __virt_addr_valid (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:979 ./include/linux/mmzone.h:2197 arch/x86/mm/physaddr.c:65) [ 34.637262][ T403] ? __lock_release (kernel/locking/lockdep.c:5536) [ 34.637269][ T403] __sys_sendmsg (net/socket.c:2716) [ 34.637272][ T403] ? __call_rcu_common.constprop.0 (kernel/rcu/tree.c:3148) [ 34.637275][ T403] ? __sys_sendmsg_sock (net/socket.c:2701) [ 34.637283][ T403] ? rcu_is_watching (./include/linux/context_tracking.h:128 kernel/rcu/tree.c:751) [ 34.637287][ T403] do_syscall_64 (arch/x86/entry/syscall_64.c:63 arch/x86/entry/syscall_64.c:94) [ 34.637293][ T403] entry_SYSCALL_64_after_hwframe (arch/x86/entry/entry_64.S:130) [ 34.637297][ T403] RIP: 0033:0x7f04b1e961d7 [ 34.637302][ T403] 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) [ 34.637305][ T403] RSP: 002b:00007ffd214eec88 EFLAGS: 00000246 ORIG_RAX: 000000000000002e [ 34.637310][ T403] RAX: ffffffffffffffda RBX: 00007ffd214ef3b0 RCX: 00007f04b1e961d7 [ 34.637312][ T403] RDX: 0000000000000000 RSI: 00007ffd214eecf0 RDI: 0000000000000005 [ 34.637314][ T403] RBP: 0000000000000002 R08: 0000000000000003 R09: 0000000000000078 [ 34.637315][ T403] R10: 00007f04b1d92f60 R11: 0000000000000246 R12: 0000000000000002 [ 34.637317][ T403] R13: 00000000690defa3 R14: 0000000000499600 R15: 0000000000000000 | [ 34.663532][ T403] refcount_t: underflow; use-after-free. | [ 34.663747][ T403] WARNING: CPU: 0 PID: 403 at lib/refcount.c:28 refcount_warn_saturate (lib/refcount.c:28 (discriminator 3)) | [ 34.664115][ T403] Modules linked in: act_gact cls_flower sch_ingress vrf veth | [ 34.664788][ T403] Tainted: [B]=BAD_PAGE [ 34.664933][ T403] Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011 [ 34.665205][ T403] RIP: 0010:refcount_warn_saturate (lib/refcount.c:28 (discriminator 3)) [ 34.665458][ T403] 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 25 98 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 25 98 mov $0xffffffff98258d60,%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 [ 34.666113][ T403] RSP: 0018:ffffc900005671f0 EFLAGS: 00010286 [ 34.666336][ T403] RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000000 [ 34.666622][ T403] RDX: 0000000000000002 RSI: 0000000000000004 RDI: 0000000000000001 [ 34.666910][ T403] RBP: 0000000000000003 R08: 0000000000000000 R09: fffffbfff317e134 [ 34.667210][ T403] R10: 0000000000000003 R11: ffffc90000566d80 R12: 0000000000000001 [ 34.667471][ T403] R13: dffffc0000000000 R14: dead000000000122 R15: dead000000000100 [ 34.667786][ T403] FS: 00007f04b1cc8800(0000) GS:ffff8880965f2000(0000) knlGS:0000000000000000 [ 34.668137][ T403] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 34.668365][ T403] CR2: 000056024f399dec CR3: 000000000ac72006 CR4: 0000000000772ef0 [ 34.668668][ T403] PKRU: 55555554 [ 34.668807][ T403] Call Trace: [ 34.668949][ T403] [ 34.669075][ T403] netdev_run_todo (./include/linux/list.h:381 net/core/dev.c:11670) [ 34.669290][ T403] ? dev_ingress_queue_create (net/core/dev.c:12299) [ 34.669482][ T403] ? generic_xdp_install (net/core/dev.c:11630) [ 34.669679][ T403] ? vrf_dellink (drivers/net/vrf.c:1667) vrf [ 34.669875][ T403] ? vrf_map_unregister_dev (drivers/net/vrf.c:1667) vrf [ 34.670108][ T403] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 34.670287][ T403] rtnl_dellink (net/core/rtnetlink.c:3580) [ 34.670475][ T403] ? valid_bridge_getlink_req.constprop.0 (net/core/rtnetlink.c:3536) [ 34.670752][ T403] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 34.670933][ T403] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 34.671135][ T403] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 34.671321][ T403] ? rtnetlink_rcv_msg (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:897 net/core/rtnetlink.c:6956) [ 34.671506][ T403] ? __lock_release (kernel/locking/lockdep.c:5536) [ 34.671706][ T403] ? valid_bridge_getlink_req.constprop.0 (net/core/rtnetlink.c:3536) [ 34.671931][ T403] rtnetlink_rcv_msg (net/core/rtnetlink.c:6958) [ 34.672118][ T403] ? rtnl_port_fill (net/core/rtnetlink.c:6861) [ 34.672289][ T403] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 34.672459][ T403] netlink_rcv_skb (net/netlink/af_netlink.c:2550) [ 34.672664][ T403] ? rtnl_port_fill (net/core/rtnetlink.c:6861) [ 34.672850][ T403] ? netlink_ack (net/netlink/af_netlink.c:2527) [ 34.673036][ T403] ? netlink_deliver_tap (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:897 net/netlink/af_netlink.c:340) [ 34.673203][ T403] ? 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) [ 34.673379][ T403] netlink_unicast (net/netlink/af_netlink.c:1319 net/netlink/af_netlink.c:1344) [ 34.673578][ T403] ? netlink_attachskb (net/netlink/af_netlink.c:1329) [ 34.673768][ T403] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 34.673935][ T403] netlink_sendmsg (net/netlink/af_netlink.c:1894) [ 34.674121][ T403] ? netlink_unicast (net/netlink/af_netlink.c:1813) [ 34.674293][ T403] ? __import_iovec (lib/iov_iter.c:1346 lib/iov_iter.c:1361) [ 34.674663][ T403] ? netlink_unicast (net/netlink/af_netlink.c:1813) [ 34.674844][ T403] ____sys_sendmsg (net/socket.c:727 net/socket.c:742 net/socket.c:2630) [ 34.675057][ T403] ? get_timestamp.constprop.0 (net/socket.c:2576) [ 34.675372][ T403] ? __copy_msghdr (net/socket.c:2556) [ 34.675572][ T403] ___sys_sendmsg (net/socket.c:2686) [ 34.675765][ T403] ? kasan_record_aux_stack (mm/kasan/generic.c:559) [ 34.675930][ T403] ? __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) [ 34.676299][ T403] ? copy_msghdr_from_user (net/socket.c:2673) [ 34.676698][ T403] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 34.676901][ T403] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 34.677091][ T403] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 34.677363][ T403] ? __virt_addr_valid (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:979 ./include/linux/mmzone.h:2197 arch/x86/mm/physaddr.c:65) [ 34.677556][ T403] ? __lock_release (kernel/locking/lockdep.c:5536) [ 34.677762][ T403] __sys_sendmsg (net/socket.c:2716) [ 34.677928][ T403] ? __call_rcu_common.constprop.0 (kernel/rcu/tree.c:3148) [ 34.678257][ T403] ? __sys_sendmsg_sock (net/socket.c:2701) [ 34.678448][ T403] ? rcu_is_watching (./include/linux/context_tracking.h:128 kernel/rcu/tree.c:751) [ 34.678662][ T403] do_syscall_64 (arch/x86/entry/syscall_64.c:63 arch/x86/entry/syscall_64.c:94) [ 34.678854][ T403] entry_SYSCALL_64_after_hwframe (arch/x86/entry/entry_64.S:130) [ 34.679074][ T403] RIP: 0033:0x7f04b1e961d7 [ 34.679254][ T403] 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) [ 34.680166][ T403] RSP: 002b:00007ffd214eec88 EFLAGS: 00000246 ORIG_RAX: 000000000000002e [ 34.680549][ T403] RAX: ffffffffffffffda RBX: 00007ffd214ef3b0 RCX: 00007f04b1e961d7 [ 34.680933][ T403] RDX: 0000000000000000 RSI: 00007ffd214eecf0 RDI: 0000000000000005 [ 34.681253][ T403] RBP: 0000000000000002 R08: 0000000000000003 R09: 0000000000000078 [ 34.681525][ T403] R10: 00007f04b1d92f60 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