syzbot


WARNING: refcount bug in inet_csk_listen_stop

Status: auto-obsoleted due to no activity on 2024/05/31 23:30
Reported-by: syzbot+73d8b1fcd3283eb75a65@syzkaller.appspotmail.com
First crash: 189d, last: 123d
Similar bugs (1)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream WARNING: refcount bug in inet_csk_listen_stop net 2 1962d 2168d 0/27 closed as invalid on 2019/04/19 22:15

Sample crash report:
------------[ cut here ]------------
refcount_t: addition on 0; use-after-free.
WARNING: CPU: 1 PID: 8105 at lib/refcount.c:25 refcount_warn_saturate+0x132/0x1a0 lib/refcount.c:25
Modules linked in:
CPU: 1 PID: 8105 Comm: syz-executor.1 Not tainted 6.1.78-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/25/2024
RIP: 0010:refcount_warn_saturate+0x132/0x1a0 lib/refcount.c:25
Code: 0a 01 48 c7 c7 a0 d1 3c 8b e8 1a c4 1a fd 0f 0b eb a9 e8 b1 c6 52 fd c6 05 e3 91 27 0a 01 48 c7 c7 00 d2 3c 8b e8 fe c3 1a fd <0f> 0b eb 8d e8 95 c6 52 fd c6 05 c8 91 27 0a 01 48 c7 c7 60 d2 3c
RSP: 0018:ffffc90004a2fa88 EFLAGS: 00010246
RAX: a56f9487468fca00 RBX: 0000000000000002 RCX: ffff88807e1ebb80
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: 0000000000000002 R08: ffffffff81527d8e R09: fffff52000945eb1
R10: 0000000000000000 R11: dffffc0000000001 R12: dffffc0000000000
R13: ffff88807ccb0000 R14: ffff888029e5cc80 R15: ffff8880311661e0
FS:  0000555556e3f480(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000001b33228000 CR3: 000000002ac1a000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 __refcount_inc include/linux/refcount.h:250 [inline]
 refcount_inc include/linux/refcount.h:267 [inline]
 sock_hold include/net/sock.h:773 [inline]
 inet_csk_listen_stop+0x88b/0xae0 net/ipv4/inet_connection_sock.c:1395
 mptcp_check_listen_stop+0x19d/0x2a0 net/mptcp/protocol.c:3010
 __mptcp_close+0xaf/0x960 net/mptcp/protocol.c:3024
 mptcp_close+0x26/0x120 net/mptcp/protocol.c:3089
 inet_release+0x174/0x1f0 net/ipv4/af_inet.c:432
 __sock_release net/socket.c:654 [inline]
 sock_close+0xcd/0x230 net/socket.c:1400
 __fput+0x3b7/0x890 fs/file_table.c:320
 task_work_run+0x246/0x300 kernel/task_work.c:179
 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline]
 exit_to_user_mode_loop+0xde/0x100 kernel/entry/common.c:171
 exit_to_user_mode_prepare+0xb1/0x140 kernel/entry/common.c:204
 __syscall_exit_to_user_mode_work kernel/entry/common.c:286 [inline]
 syscall_exit_to_user_mode+0x60/0x270 kernel/entry/common.c:297
 do_syscall_64+0x49/0xb0 arch/x86/entry/common.c:87
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7f270b87cc9a
Code: 48 3d 00 f0 ff ff 77 48 c3 0f 1f 80 00 00 00 00 48 83 ec 18 89 7c 24 0c e8 03 7f 02 00 8b 7c 24 0c 89 c2 b8 03 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 36 89 d7 89 44 24 0c e8 63 7f 02 00 8b 44 24
RSP: 002b:00007fff0899c510 EFLAGS: 00000293 ORIG_RAX: 0000000000000003
RAX: 0000000000000000 RBX: 0000000000000004 RCX: 00007f270b87cc9a
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000003
RBP: 0000000000000032 R08: 0000001b33820000 R09: 00000000000002af
R10: 00000000813291ad R11: 0000000000000293 R12: 00007f270b4005f8
R13: ffffffffffffffff R14: 00007f270b400000 R15: 000000000031086e
 </TASK>

Crashes (2):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/02/21 23:30 linux-6.1.y 8b4118fabd6e 345111b5 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan WARNING: refcount bug in inet_csk_listen_stop
2023/12/18 21:19 linux-6.1.y ba6f5fb46511 924661f4 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan WARNING: refcount bug in inet_csk_listen_stop
* Struck through repros no longer work on HEAD.