====================================== | [ 116.678758][ T2120] ================================================================== | [ 116.679116][ T2120] BUG: KASAN: slab-use-after-free in kobject_put (lib/kobject.c:733) | [ 116.679428][ T2120] Read of size 1 at addr ffff8880148f26ac by task ip/2120 | [ 116.679649][ T2120] [ 116.679778][ T2120] Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011 [ 116.679781][ T2120] Call Trace: [ 116.679783][ T2120] [ 116.679786][ T2120] dump_stack_lvl (lib/dump_stack.c:123) [ 116.679793][ T2120] print_address_description.constprop.0 (mm/kasan/report.c:379) [ 116.679800][ T2120] ? kobject_put (lib/kobject.c:733) [ 116.679805][ T2120] print_report (mm/kasan/report.c:483) [ 116.679807][ T2120] ? kobject_put (lib/kobject.c:733) [ 116.679811][ T2120] ? kasan_addr_to_slab (./include/linux/mm.h:1245 mm/kasan/../slab.h:191 mm/kasan/common.c:47) [ 116.679814][ T2120] ? kobject_put (lib/kobject.c:733) [ 116.679817][ T2120] kasan_report (mm/kasan/report.c:597) [ 116.679821][ T2120] ? kobject_put (lib/kobject.c:733) [ 116.679827][ T2120] kobject_put (lib/kobject.c:733) [ 116.679830][ T2120] netdev_run_todo (./include/linux/list.h:381 net/core/dev.c:11670) [ 116.679836][ T2120] ? dev_ingress_queue_create (net/core/dev.c:12299) [ 116.679839][ T2120] ? generic_xdp_install (net/core/dev.c:11630) [ 116.679842][ T2120] ? kernfs_put.part.0 (./arch/x86/include/asm/atomic.h:67 ./include/linux/atomic/atomic-arch-fallback.h:2278 ./include/linux/atomic/atomic-instrumented.h:1384 fs/kernfs/dir.c:595) [ 116.679848][ T2120] ? unregister_netdevice_many (net/core/dev.c:12241) [ 116.679855][ T2120] ? br_dev_delete (net/bridge/br_if.c:397) bridge [ 116.679890][ T2120] rtnl_dellink (net/core/rtnetlink.c:3580) [ 116.679896][ T2120] ? valid_bridge_getlink_req.constprop.0 (net/core/rtnetlink.c:3536) [ 116.679914][ T2120] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 116.679922][ T2120] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 116.679929][ T2120] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 116.679933][ T2120] ? rtnetlink_rcv_msg (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:897 net/core/rtnetlink.c:6956) [ 116.679935][ T2120] ? __lock_release (kernel/locking/lockdep.c:5536) [ 116.679940][ T2120] ? valid_bridge_getlink_req.constprop.0 (net/core/rtnetlink.c:3536) [ 116.679944][ T2120] rtnetlink_rcv_msg (net/core/rtnetlink.c:6958) [ 116.679947][ T2120] ? rtnl_port_fill (net/core/rtnetlink.c:6861) [ 116.679950][ T2120] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 116.679957][ T2120] netlink_rcv_skb (net/netlink/af_netlink.c:2550) [ 116.679962][ T2120] ? rtnl_port_fill (net/core/rtnetlink.c:6861) [ 116.679965][ T2120] ? netlink_ack (net/netlink/af_netlink.c:2527) [ 116.679972][ T2120] ? netlink_deliver_tap (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:897 net/netlink/af_netlink.c:340) [ 116.679975][ T2120] ? 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) [ 116.679978][ T2120] netlink_unicast (net/netlink/af_netlink.c:1319 net/netlink/af_netlink.c:1344) [ 116.679982][ T2120] ? netlink_attachskb (net/netlink/af_netlink.c:1329) [ 116.679986][ T2120] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 116.679992][ T2120] netlink_sendmsg (net/netlink/af_netlink.c:1894) [ 116.679996][ T2120] ? netlink_unicast (net/netlink/af_netlink.c:1813) [ 116.680000][ T2120] ? __import_iovec (lib/iov_iter.c:1346 lib/iov_iter.c:1361) [ 116.680005][ T2120] ? netlink_unicast (net/netlink/af_netlink.c:1813) [ 116.680009][ T2120] ____sys_sendmsg (net/socket.c:727 net/socket.c:742 net/socket.c:2630) [ 116.680017][ T2120] ? get_timestamp.constprop.0 (net/socket.c:2576) [ 116.680020][ T2120] ? __copy_msghdr (net/socket.c:2556) [ 116.680027][ T2120] ___sys_sendmsg (net/socket.c:2686) [ 116.680030][ T2120] ? kasan_record_aux_stack (mm/kasan/generic.c:559) [ 116.680033][ T2120] ? __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) [ 116.680042][ T2120] ? copy_msghdr_from_user (net/socket.c:2673) [ 116.680047][ T2120] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 116.680051][ T2120] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 116.680057][ T2120] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 116.680060][ T2120] ? __virt_addr_valid (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:979 ./include/linux/mmzone.h:2197 arch/x86/mm/physaddr.c:65) [ 116.680069][ T2120] ? __lock_release (kernel/locking/lockdep.c:5536) [ 116.680076][ T2120] __sys_sendmsg (net/socket.c:2716) [ 116.680079][ T2120] ? __call_rcu_common.constprop.0 (kernel/rcu/tree.c:3148) [ 116.680083][ T2120] ? __sys_sendmsg_sock (net/socket.c:2701) [ 116.680090][ T2120] ? rcu_is_watching (./include/linux/context_tracking.h:128 kernel/rcu/tree.c:751) [ 116.680094][ T2120] do_syscall_64 (arch/x86/entry/syscall_64.c:63 arch/x86/entry/syscall_64.c:94) [ 116.680101][ T2120] entry_SYSCALL_64_after_hwframe (arch/x86/entry/entry_64.S:130) [ 116.680107][ T2120] RIP: 0033:0x7fe5231da1d7 [ 116.680112][ T2120] 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) [ 116.680115][ T2120] RSP: 002b:00007ffcea0e2688 EFLAGS: 00000246 ORIG_RAX: 000000000000002e [ 116.680120][ T2120] RAX: ffffffffffffffda RBX: 00007ffcea0e2db0 RCX: 00007fe5231da1d7 [ 116.680122][ T2120] RDX: 0000000000000000 RSI: 00007ffcea0e26f0 RDI: 0000000000000005 [ 116.680124][ T2120] RBP: 0000000000000002 R08: 0000000000000003 R09: 0000000000000078 [ 116.680126][ T2120] R10: 00007fe5230d6f60 R11: 0000000000000246 R12: 0000000000000002 [ 116.680129][ T2120] R13: 00000000690df0ee R14: 0000000000499600 R15: 0000000000000000 | [ 116.720125][ T2120] refcount_t: underflow; use-after-free. | [ 116.720372][ T2120] WARNING: CPU: 0 PID: 2120 at lib/refcount.c:28 refcount_warn_saturate (lib/refcount.c:28 (discriminator 3)) | [ 116.720714][ T2120] Modules linked in: bridge stp llc 8021q vrf veth | [ 116.721364][ T2120] Tainted: [B]=BAD_PAGE [ 116.721519][ T2120] Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011 [ 116.721780][ T2120] RIP: 0010:refcount_warn_saturate (lib/refcount.c:28 (discriminator 3)) [ 116.722019][ T2120] 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 85 b5 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 85 b5 mov $0xffffffffb5858d60,%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 [ 116.722678][ T2120] RSP: 0018:ffffc90003bb71f0 EFLAGS: 00010286 [ 116.722889][ T2120] RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000000 [ 116.723168][ T2120] RDX: 0000000000000002 RSI: 0000000000000004 RDI: 0000000000000001 [ 116.723409][ T2120] RBP: 0000000000000003 R08: 0000000000000000 R09: fffffbfff6c3e134 [ 116.723663][ T2120] R10: 0000000000000003 R11: ffffc90003bb6d80 R12: 0000000000000001 [ 116.723957][ T2120] R13: dffffc0000000000 R14: dead000000000122 R15: dead000000000100 [ 116.724231][ T2120] FS: 00007fe52300c800(0000) GS:ffff88807ebf2000(0000) knlGS:0000000000000000 [ 116.724569][ T2120] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 116.724794][ T2120] CR2: 000055732125adec CR3: 0000000015487005 CR4: 0000000000772ef0 [ 116.725064][ T2120] PKRU: 55555554 [ 116.725187][ T2120] Call Trace: [ 116.725312][ T2120] [ 116.725397][ T2120] netdev_run_todo (./include/linux/list.h:381 net/core/dev.c:11670) [ 116.725571][ T2120] ? dev_ingress_queue_create (net/core/dev.c:12299) [ 116.725747][ T2120] ? generic_xdp_install (net/core/dev.c:11630) [ 116.725907][ T2120] ? kernfs_put.part.0 (./arch/x86/include/asm/atomic.h:67 ./include/linux/atomic/atomic-arch-fallback.h:2278 ./include/linux/atomic/atomic-instrumented.h:1384 fs/kernfs/dir.c:595) [ 116.726089][ T2120] ? unregister_netdevice_many (net/core/dev.c:12241) [ 116.726269][ T2120] ? br_dev_delete (net/bridge/br_if.c:397) bridge [ 116.726486][ T2120] rtnl_dellink (net/core/rtnetlink.c:3580) [ 116.726679][ T2120] ? valid_bridge_getlink_req.constprop.0 (net/core/rtnetlink.c:3536) [ 116.726901][ T2120] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 116.727070][ T2120] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 116.727337][ T2120] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 116.727506][ T2120] ? rtnetlink_rcv_msg (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:897 net/core/rtnetlink.c:6956) [ 116.727692][ T2120] ? __lock_release (kernel/locking/lockdep.c:5536) [ 116.727885][ T2120] ? valid_bridge_getlink_req.constprop.0 (net/core/rtnetlink.c:3536) [ 116.728221][ T2120] rtnetlink_rcv_msg (net/core/rtnetlink.c:6958) [ 116.728391][ T2120] ? rtnl_port_fill (net/core/rtnetlink.c:6861) [ 116.728552][ T2120] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 116.728858][ T2120] netlink_rcv_skb (net/netlink/af_netlink.c:2550) [ 116.729030][ T2120] ? rtnl_port_fill (net/core/rtnetlink.c:6861) [ 116.729193][ T2120] ? netlink_ack (net/netlink/af_netlink.c:2527) [ 116.729371][ T2120] ? netlink_deliver_tap (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:897 net/netlink/af_netlink.c:340) [ 116.729643][ T2120] ? 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) [ 116.729813][ T2120] netlink_unicast (net/netlink/af_netlink.c:1319 net/netlink/af_netlink.c:1344) [ 116.729975][ T2120] ? netlink_attachskb (net/netlink/af_netlink.c:1329) [ 116.730190][ T2120] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 116.730447][ T2120] netlink_sendmsg (net/netlink/af_netlink.c:1894) [ 116.730625][ T2120] ? netlink_unicast (net/netlink/af_netlink.c:1813) [ 116.730845][ T2120] ? __import_iovec (lib/iov_iter.c:1346 lib/iov_iter.c:1361) [ 116.731076][ T2120] ? netlink_unicast (net/netlink/af_netlink.c:1813) [ 116.732881][ T2120] ____sys_sendmsg (net/socket.c:727 net/socket.c:742 net/socket.c:2630) [ 116.733201][ T2120] ? get_timestamp.constprop.0 (net/socket.c:2576) [ 116.733524][ T2120] ? __copy_msghdr (net/socket.c:2556) [ 116.733799][ T2120] ___sys_sendmsg (net/socket.c:2686) [ 116.734090][ T2120] ? kasan_record_aux_stack (mm/kasan/generic.c:559) [ 116.734358][ T2120] ? __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) [ 116.734718][ T2120] ? copy_msghdr_from_user (net/socket.c:2673) [ 116.734988][ T2120] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 116.735261][ T2120] ? __lock_acquire (kernel/locking/lockdep.c:5237) [ 116.735529][ T2120] ? find_held_lock (kernel/locking/lockdep.c:5350) [ 116.735808][ T2120] ? __virt_addr_valid (./include/linux/rcupdate.h:341 ./include/linux/rcupdate.h:979 ./include/linux/mmzone.h:2197 arch/x86/mm/physaddr.c:65) [ 116.736086][ T2120] ? __lock_release (kernel/locking/lockdep.c:5536) [ 116.736363][ T2120] __sys_sendmsg (net/socket.c:2716) [ 116.736648][ T2120] ? __call_rcu_common.constprop.0 (kernel/rcu/tree.c:3148) [ 116.737004][ T2120] ? __sys_sendmsg_sock (net/socket.c:2701) [ 116.737280][ T2120] ? rcu_is_watching (./include/linux/context_tracking.h:128 kernel/rcu/tree.c:751) [ 116.737562][ T2120] do_syscall_64 (arch/x86/entry/syscall_64.c:63 arch/x86/entry/syscall_64.c:94) [ 116.737856][ T2120] entry_SYSCALL_64_after_hwframe (arch/x86/entry/entry_64.S:130) [ 116.738175][ T2120] RIP: 0033:0x7fe5231da1d7 [ 116.738453][ T2120] 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) [ 116.739374][ T2120] RSP: 002b:00007ffcea0e2688 EFLAGS: 00000246 ORIG_RAX: 000000000000002e [ 116.739772][ T2120] RAX: ffffffffffffffda RBX: 00007ffcea0e2db0 RCX: 00007fe5231da1d7 [ 116.740161][ T2120] RDX: 0000000000000000 RSI: 00007ffcea0e26f0 RDI: 0000000000000005 [ 116.740531][ T2120] RBP: 0000000000000002 R08: 0000000000000003 R09: 0000000000000078 [ 116.740930][ T2120] R10: 00007fe5230d6f60 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