================================================================== BUG: KASAN: use-after-free in rxrpc_send_keepalive+0x83e/0x8e0 net/rxrpc/output.c:637 Read of size 8 at addr ffff8880a0b11698 by task kworker/1:2/2741 CPU: 1 PID: 2741 Comm: kworker/1:2 Not tainted 4.19.72 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: krxrpcd rxrpc_peer_keepalive_worker Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x172/0x1f0 lib/dump_stack.c:113 print_address_description.cold+0x7c/0x20d mm/kasan/report.c:256 kasan_report_error mm/kasan/report.c:354 [inline] kasan_report mm/kasan/report.c:412 [inline] kasan_report.cold+0x8c/0x2ba mm/kasan/report.c:396 __asan_report_load8_noabort+0x14/0x20 mm/kasan/report.c:433 rxrpc_send_keepalive+0x83e/0x8e0 net/rxrpc/output.c:637 rxrpc_peer_keepalive_dispatch net/rxrpc/peer_event.c:366 [inline] rxrpc_peer_keepalive_worker+0x7be/0xd02 net/rxrpc/peer_event.c:427 process_one_work+0x989/0x1750 kernel/workqueue.c:2153 worker_thread+0x98/0xe40 kernel/workqueue.c:2296 kthread+0x354/0x420 kernel/kthread.c:246 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:415 Allocated by task 11537: save_stack+0x45/0xd0 mm/kasan/kasan.c:448 set_track mm/kasan/kasan.c:460 [inline] kasan_kmalloc mm/kasan/kasan.c:553 [inline] kasan_kmalloc+0xce/0xf0 mm/kasan/kasan.c:531 kmem_cache_alloc_trace+0x152/0x760 mm/slab.c:3625 kmalloc include/linux/slab.h:515 [inline] kzalloc include/linux/slab.h:709 [inline] rxrpc_alloc_connection+0x6a/0x5e0 net/rxrpc/conn_object.c:45 rxrpc_alloc_client_connection net/rxrpc/conn_client.c:181 [inline] rxrpc_get_client_conn net/rxrpc/conn_client.c:344 [inline] rxrpc_connect_call+0x641/0x48d0 net/rxrpc/conn_client.c:701 rxrpc_new_client_call+0x8e7/0x1880 net/rxrpc/call_object.c:291 rxrpc_new_client_call_for_sendmsg net/rxrpc/sendmsg.c:596 [inline] rxrpc_do_sendmsg+0xfbe/0x1c8f net/rxrpc/sendmsg.c:652 rxrpc_sendmsg+0x4a0/0x5b0 net/rxrpc/af_rxrpc.c:592 sock_sendmsg_nosec net/socket.c:622 [inline] sock_sendmsg+0xd7/0x130 net/socket.c:632 ___sys_sendmsg+0x3e2/0x920 net/socket.c:2115 __sys_sendmmsg+0x1bf/0x4e0 net/socket.c:2210 __do_sys_sendmmsg net/socket.c:2239 [inline] __se_sys_sendmmsg net/socket.c:2236 [inline] __x64_sys_sendmmsg+0x9d/0x100 net/socket.c:2236 do_syscall_64+0xfd/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe Freed by task 7581: save_stack+0x45/0xd0 mm/kasan/kasan.c:448 set_track mm/kasan/kasan.c:460 [inline] __kasan_slab_free+0x102/0x150 mm/kasan/kasan.c:521 kasan_slab_free+0xe/0x10 mm/kasan/kasan.c:528 __cache_free mm/slab.c:3503 [inline] kfree+0xcf/0x220 mm/slab.c:3822 rxrpc_destroy_connection+0x1f2/0x2d0 net/rxrpc/conn_object.c:375 __rcu_reclaim kernel/rcu/rcu.h:236 [inline] rcu_do_batch kernel/rcu/tree.c:2584 [inline] invoke_rcu_callbacks kernel/rcu/tree.c:2897 [inline] __rcu_process_callbacks kernel/rcu/tree.c:2864 [inline] rcu_process_callbacks+0xba0/0x1a30 kernel/rcu/tree.c:2881 __do_softirq+0x25c/0x921 kernel/softirq.c:292 The buggy address belongs to the object at ffff8880a0b11680 which belongs to the cache kmalloc-1024 of size 1024 The buggy address is located 24 bytes inside of 1024-byte region [ffff8880a0b11680, ffff8880a0b11a80) The buggy address belongs to the page: page:ffffea000282c400 count:1 mapcount:0 mapping:ffff88812c3f0ac0 index:0xffff8880a0b10d80 compound_mapcount: 0 flags: 0x1fffc0000008100(slab|head) raw: 01fffc0000008100 ffffea0002356b08 ffffea000294fa08 ffff88812c3f0ac0 raw: ffff8880a0b10d80 ffff8880a0b10000 0000000100000006 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8880a0b11580: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff8880a0b11600: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff8880a0b11680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff8880a0b11700: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff8880a0b11780: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ==================================================================