syzbot


WARNING in tcp_recvmsg_locked (2)

Status: upstream: reported C repro on 2023/12/05 17:53
Subsystems: net
[Documentation on labels]
Reported-by: syzbot+06dbd397158ec0ea4983@syzkaller.appspotmail.com
First crash: 312d, last: 11d
Cause bisection: introduced by (bisect log) :
commit 965b57b469a589d64d81b1688b38dcb537011bb0
Author: Cong Wang <cong.wang@bytedance.com>
Date: Wed Jun 15 16:20:12 2022 +0000

  net: Introduce a new proto_ops ->read_skb()

Crash: WARNING in tcp_recvmsg_locked (log)
Repro: C syz .config
  
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [net?] WARNING in tcp_recvmsg_locked (2) 1 (2) 2023/12/05 18:38
Similar bugs (2)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream WARNING in tcp_recvmsg_locked net 1 453d 453d 0/28 auto-obsoleted due to no activity on 2023/11/06 08:49
linux-6.1 WARNING in tcp_recvmsg_locked origin:upstream C error 1 125d 191d 0/3 upstream: reported C repro on 2024/04/04 07:11
Last patch testing requests (5)
Created Duration User Patch Repo Result
2024/09/15 09:05 11m retest repro upstream report log
2024/07/22 02:10 17m retest repro net-next report log
2024/07/07 08:47 17m retest repro upstream report log
2024/05/04 09:48 20m retest repro net-next report log
2023/12/18 12:46 14m retest repro net-next report log
Fix bisection attempts (3)
Created Duration User Patch Repo Result
2024/08/21 02:40 2h53m bisect fix net-next OK (0) job log log
2024/02/24 06:46 2h56m bisect fix net-next OK (0) job log log
2024/01/18 14:44 6h50m bisect fix net-next OK (0) job log log

Sample crash report:
------------[ cut here ]------------
TCP recvmsg seq # bug 2: copied 898E7F1E, seq 898E7EE6, rcvnxt 898E7EE7, fl 40
WARNING: CPU: 0 PID: 5562 at net/ipv4/tcp.c:2647 tcp_recvmsg_locked+0xad1/0x2780 net/ipv4/tcp.c:2647
Modules linked in:
CPU: 0 UID: 0 PID: 5562 Comm: syz-executor821 Not tainted 6.12.0-rc1-syzkaller #0
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014
RIP: 0010:tcp_recvmsg_locked+0xad1/0x2780 net/ipv4/tcp.c:2647
Code: 07 83 c0 03 38 d0 7c 08 84 d2 0f 85 b3 1b 00 00 48 8b 04 24 89 da 48 c7 c7 40 f8 a7 8c 44 8b 44 24 30 8b 30 e8 e0 f9 c5 f7 90 <0f> 0b 90 90 e9 1c fa ff ff e8 31 11 05 f8 49 8d 5f 60 be 08 00 00
RSP: 0018:ffffc90004bb7408 EFLAGS: 00010282
RAX: 0000000000000000 RBX: 00000000898e7ee6 RCX: ffffffff814e7329
RDX: ffff88802c180000 RSI: ffffffff814e7336 RDI: 0000000000000001
RBP: 0000000000000001 R08: 0000000000000001 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: dffffc0000000000
R13: ffff88802cefb2f0 R14: ffff88802cefb324 R15: ffff88802cefb318
FS:  00005555608e6380(0000) GS:ffff88806a600000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000000002000cf3d CR3: 0000000027be4000 CR4: 0000000000352ef0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 receive_fallback_to_copy net/ipv4/tcp.c:1890 [inline]
 tcp_zerocopy_receive+0x1483/0x2620 net/ipv4/tcp.c:2122
 do_tcp_getsockopt+0x1803/0x2970 net/ipv4/tcp.c:4582
 tcp_getsockopt net/ipv4/tcp.c:4672 [inline]
 tcp_getsockopt+0xdf/0x100 net/ipv4/tcp.c:4663
 do_sock_getsockopt+0x3fe/0x800 net/socket.c:2391
 __sys_getsockopt+0x1a1/0x270 net/socket.c:2420
 __do_sys_getsockopt net/socket.c:2430 [inline]
 __se_sys_getsockopt net/socket.c:2427 [inline]
 __x64_sys_getsockopt+0xbd/0x160 net/socket.c:2427
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0xcd/0x250 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fda22922079
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 c1 17 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007fff1ea265c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000037
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007fda22922079
RDX: 0000000000000023 RSI: 0000000000000006 RDI: 0000000000000003
RBP: 0000000000000000 R08: 00000000200004c0 R09: 0000000000000006
R10: 0000000020000380 R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000001 R15: 0000000000000001
 </TASK>

Crashes (7):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/09/30 21:59 upstream 9852d85ec9d4 179f4029 .config console log report syz / log C [disk image (non-bootable)] [vmlinux] [kernel image] ci-qemu-upstream WARNING in tcp_recvmsg_locked
2024/06/23 08:39 upstream 563a50672d8a c2e07261 .config console log report syz / log C [disk image (non-bootable)] [vmlinux] [kernel image] ci-qemu-upstream WARNING in tcp_recvmsg_locked
2023/12/04 12:46 net-next 8470e4368b0f f819d6f7 .config strace log report syz C [disk image] [vmlinux] [kernel image] ci-upstream-net-kasan-gce WARNING in tcp_recvmsg_locked
2024/09/19 16:24 upstream a430d95c5efa 6f888b75 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-selinux-root WARNING in tcp_recvmsg_locked
2024/06/23 03:29 upstream 563a50672d8a c2e07261 .config console log report info [disk image (non-bootable)] [vmlinux] [kernel image] ci-qemu-upstream WARNING in tcp_recvmsg_locked
2024/03/14 07:29 net d7d75124965a f919f202 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-net-this-kasan-gce WARNING in tcp_recvmsg_locked
2023/12/04 09:44 net-next 8470e4368b0f f819d6f7 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-net-kasan-gce WARNING in tcp_recvmsg_locked
* Struck through repros no longer work on HEAD.