================================================================== BUG: KASAN: use-after-free in __read_once_size include/linux/compiler.h:252 [inline] BUG: KASAN: use-after-free in list_empty include/linux/list.h:282 [inline] BUG: KASAN: use-after-free in waitqueue_active include/linux/wait.h:127 [inline] BUG: KASAN: use-after-free in wq_has_sleeper include/linux/wait.h:161 [inline] BUG: KASAN: use-after-free in skwq_has_sleeper include/net/sock.h:2143 [inline] BUG: KASAN: use-after-free in sock_def_write_space+0x613/0x640 net/core/sock.c:2924 Read of size 8 at addr ffff88804e8b95c0 by task syz-executor.3/14090 CPU: 1 PID: 14090 Comm: syz-executor.3 Not tainted 5.7.0-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x188/0x20d lib/dump_stack.c:118 print_address_description.constprop.0.cold+0xd3/0x413 mm/kasan/report.c:383 __kasan_report mm/kasan/report.c:513 [inline] kasan_report.cold+0x1f/0x37 mm/kasan/report.c:530 __read_once_size include/linux/compiler.h:252 [inline] list_empty include/linux/list.h:282 [inline] waitqueue_active include/linux/wait.h:127 [inline] wq_has_sleeper include/linux/wait.h:161 [inline] skwq_has_sleeper include/net/sock.h:2143 [inline] sock_def_write_space+0x613/0x640 net/core/sock.c:2924 sock_wfree+0x1cc/0x240 net/core/sock.c:2058 skb_release_head_state+0xe2/0x250 net/core/skbuff.c:651 skb_release_all+0x11/0x60 net/core/skbuff.c:662 __kfree_skb net/core/skbuff.c:678 [inline] kfree_skb net/core/skbuff.c:696 [inline] kfree_skb+0xfa/0x410 net/core/skbuff.c:690 skb_queue_purge+0x14/0x30 net/core/skbuff.c:3077 qrtr_tun_release+0x40/0x60 net/qrtr/tun.c:118 __fput+0x33e/0x880 fs/file_table.c:281 task_work_run+0xf4/0x1b0 kernel/task_work.c:123 tracehook_notify_resume include/linux/tracehook.h:188 [inline] exit_to_usermode_loop+0x2fa/0x360 arch/x86/entry/common.c:165 prepare_exit_to_usermode arch/x86/entry/common.c:196 [inline] syscall_return_slowpath arch/x86/entry/common.c:279 [inline] do_syscall_64+0x6b1/0x7d0 arch/x86/entry/common.c:305 entry_SYSCALL_64_after_hwframe+0x49/0xb3 RIP: 0033:0x416651 Code: 75 14 b8 03 00 00 00 0f 05 48 3d 01 f0 ff ff 0f 83 04 1b 00 00 c3 48 83 ec 08 e8 0a fc ff ff 48 89 04 24 b8 03 00 00 00 0f 05 <48> 8b 3c 24 48 89 c2 e8 53 fc ff ff 48 89 d0 48 83 c4 08 48 3d 01 RSP: 002b:0000000000c9fbe0 EFLAGS: 00000293 ORIG_RAX: 0000000000000003 RAX: 0000000000000000 RBX: 0000000000000004 RCX: 0000000000416651 RDX: 0000001b2f020000 RSI: 0000000000001688 RDI: 0000000000000003 RBP: 0000000000000001 R08: 00000000f369568c R09: 0000000000000000 R10: 0000000000c9fcd0 R11: 0000000000000293 R12: 000000000078c900 R13: 000000000078c900 R14: ffffffffffffffff R15: 000000000078c0ec Allocated by task 14083: save_stack+0x1b/0x40 mm/kasan/common.c:48 set_track mm/kasan/common.c:56 [inline] __kasan_kmalloc mm/kasan/common.c:494 [inline] __kasan_kmalloc.constprop.0+0xbf/0xd0 mm/kasan/common.c:467 slab_post_alloc_hook mm/slab.h:586 [inline] slab_alloc mm/slab.c:3320 [inline] kmem_cache_alloc+0x11b/0x740 mm/slab.c:3484 sock_alloc_inode+0x18/0x1c0 net/socket.c:253 alloc_inode+0x61/0x1e0 fs/inode.c:232 new_inode_pseudo+0x14/0xe0 fs/inode.c:928 sock_alloc+0x3c/0x260 net/socket.c:573 __sock_create+0xba/0x730 net/socket.c:1392 sock_create net/socket.c:1479 [inline] __sys_socket+0xef/0x200 net/socket.c:1521 __do_sys_socket net/socket.c:1530 [inline] __se_sys_socket net/socket.c:1528 [inline] __x64_sys_socket+0x6f/0xb0 net/socket.c:1528 do_syscall_64+0xf6/0x7d0 arch/x86/entry/common.c:295 entry_SYSCALL_64_after_hwframe+0x49/0xb3 Freed by task 14076: save_stack+0x1b/0x40 mm/kasan/common.c:48 set_track mm/kasan/common.c:56 [inline] kasan_set_free_info mm/kasan/common.c:316 [inline] __kasan_slab_free+0xf7/0x140 mm/kasan/common.c:455 __cache_free mm/slab.c:3426 [inline] kmem_cache_free+0x7f/0x320 mm/slab.c:3694 i_callback+0x3f/0x70 fs/inode.c:221 rcu_do_batch kernel/rcu/tree.c:2396 [inline] rcu_core+0x59f/0x1370 kernel/rcu/tree.c:2623 __do_softirq+0x26c/0x9f7 kernel/softirq.c:292 The buggy address belongs to the object at ffff88804e8b9540 which belongs to the cache sock_inode_cache of size 1216 The buggy address is located 128 bytes inside of 1216-byte region [ffff88804e8b9540, ffff88804e8b9a00) The buggy address belongs to the page: page:ffffea00013a2e40 refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff88804e8b9ffd flags: 0xfffe0000000200(slab) raw: 00fffe0000000200 ffffea000229d5c8 ffffea00013a1608 ffff8880a9768700 raw: ffff88804e8b9ffd ffff88804e8b9000 0000000100000003 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff88804e8b9480: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc ffff88804e8b9500: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb >ffff88804e8b9580: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff88804e8b9600: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff88804e8b9680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ==================================================================