syzbot


general protection fault in pause_prepare_data

Status: fixed on 2023/06/08 14:41
Subsystems: net
[Documentation on labels]
Reported-by: syzbot+9d44aae2720fc40b8474@syzkaller.appspotmail.com
Fix commit: f5be9caf7bf0 net: ethtool: fix NULL pointer dereference in pause_prepare_data()
First crash: 622d, last: 620d
Cause bisection: failed (error log, bisect log)
  
Discussions (2)
Title Replies (including bot) Last reply
[PATCH net-next] net: ethtool: fix NULL pointer dereference in pause_prepare_data() 3 (3) 2023/01/25 10:00
[syzbot] general protection fault in pause_prepare_data 0 (2) 2023/01/24 08:25

Sample crash report:
general protection fault, probably for non-canonical address 0xdffffc0000000008: 0000 [#1] PREEMPT SMP KASAN
KASAN: null-ptr-deref in range [0x0000000000000040-0x0000000000000047]
CPU: 0 PID: 5071 Comm: syz-executor396 Not tainted 6.2.0-rc4-syzkaller-00687-g32e54254bab8 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/12/2023
RIP: 0010:pause_prepare_data+0x60/0x400 net/ethtool/pause.c:59
Code: 0f b6 04 02 84 c0 74 08 3c 03 0f 8e 02 03 00 00 48 8d 7d 40 45 8b 6c 24 18 48 b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 <80> 3c 02 00 0f 85 14 03 00 00 48 8b 45 40 48 89 da 48 c1 ea 03 48
RSP: 0018:ffffc90003c0f270 EFLAGS: 00010202
RAX: dffffc0000000000 RBX: ffff888021b55c00 RCX: 0000000000000000
RDX: 0000000000000008 RSI: ffffffff880744d0 RDI: 0000000000000040
RBP: 0000000000000000 R08: 0000000000000000 R09: ffffffff8e7326d7
R10: fffffbfff1ce64da R11: 0000000000000000 R12: ffff8880218e7d00
R13: 0000000000000000 R14: ffff88807de6c598 R15: ffffffff880744b0
FS:  000055555715c300(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00000000006691e0 CR3: 000000007b781000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 ethnl_default_dump_one net/ethtool/netlink.c:446 [inline]
 ethnl_default_dumpit+0x4a8/0xe80 net/ethtool/netlink.c:498
 netlink_dump+0x570/0xc50 net/netlink/af_netlink.c:2286
 __netlink_dump_start+0x64b/0x910 net/netlink/af_netlink.c:2391
 genl_family_rcv_msg_dumpit+0x2be/0x310 net/netlink/genetlink.c:929
 genl_family_rcv_msg net/netlink/genetlink.c:1045 [inline]
 genl_rcv_msg+0x419/0x7e0 net/netlink/genetlink.c:1065
 netlink_rcv_skb+0x165/0x440 net/netlink/af_netlink.c:2564
 genl_rcv+0x28/0x40 net/netlink/genetlink.c:1076
 netlink_unicast_kernel net/netlink/af_netlink.c:1330 [inline]
 netlink_unicast+0x547/0x7f0 net/netlink/af_netlink.c:1356
 netlink_sendmsg+0x91b/0xe10 net/netlink/af_netlink.c:1932
 sock_sendmsg_nosec net/socket.c:722 [inline]
 sock_sendmsg+0xde/0x190 net/socket.c:745
 ____sys_sendmsg+0x71c/0x900 net/socket.c:2501
 ___sys_sendmsg+0x110/0x1b0 net/socket.c:2555
 __sys_sendmsg+0xf7/0x1c0 net/socket.c:2584
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x39/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7f620fd6c589
Code: 28 c3 e8 4a 15 00 00 66 2e 0f 1f 84 00 00 00 00 00 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 c0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffdab95a158 EFLAGS: 00000246 ORIG_RAX: 000000000000002e
RAX: ffffffffffffffda RBX: 00007ffdab95a168 RCX: 00007f620fd6c589
RDX: 0000000000000000 RSI: 0000000020000540 RDI: 0000000000000003
RBP: 0000000000000003 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 00007ffdab95a170
R13: 00007ffdab95a190 R14: 0000000000000000 R15: 0000000000000000
 </TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:pause_prepare_data+0x60/0x400 net/ethtool/pause.c:59
Code: 0f b6 04 02 84 c0 74 08 3c 03 0f 8e 02 03 00 00 48 8d 7d 40 45 8b 6c 24 18 48 b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 <80> 3c 02 00 0f 85 14 03 00 00 48 8b 45 40 48 89 da 48 c1 ea 03 48
RSP: 0018:ffffc90003c0f270 EFLAGS: 00010202
RAX: dffffc0000000000 RBX: ffff888021b55c00 RCX: 0000000000000000
RDX: 0000000000000008 RSI: ffffffff880744d0 RDI: 0000000000000040
RBP: 0000000000000000 R08: 0000000000000000 R09: ffffffff8e7326d7
R10: fffffbfff1ce64da R11: 0000000000000000 R12: ffff8880218e7d00
R13: 0000000000000000 R14: ffff88807de6c598 R15: ffffffff880744b0
FS:  000055555715c300(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000055e77403a658 CR3: 000000007b781000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
   0:	0f b6 04 02          	movzbl (%rdx,%rax,1),%eax
   4:	84 c0                	test   %al,%al
   6:	74 08                	je     0x10
   8:	3c 03                	cmp    $0x3,%al
   a:	0f 8e 02 03 00 00    	jle    0x312
  10:	48 8d 7d 40          	lea    0x40(%rbp),%rdi
  14:	45 8b 6c 24 18       	mov    0x18(%r12),%r13d
  19:	48 b8 00 00 00 00 00 	movabs $0xdffffc0000000000,%rax
  20:	fc ff df
  23:	48 89 fa             	mov    %rdi,%rdx
  26:	48 c1 ea 03          	shr    $0x3,%rdx
* 2a:	80 3c 02 00          	cmpb   $0x0,(%rdx,%rax,1) <-- trapping instruction
  2e:	0f 85 14 03 00 00    	jne    0x348
  34:	48 8b 45 40          	mov    0x40(%rbp),%rax
  38:	48 89 da             	mov    %rbx,%rdx
  3b:	48 c1 ea 03          	shr    $0x3,%rdx
  3f:	48                   	rex.W

Crashes (34):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/01/24 08:25 net-next-old 32e54254bab8 9dfcf09c .config strace log report syz C ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/26 00:10 net-next-old d0671115869d 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 23:13 net-next-old d0671115869d 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 21:22 net-next-old d0671115869d 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 16:32 net-next-old d0671115869d 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 14:29 net-next-old d0671115869d 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 14:27 net-next-old d0671115869d 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 13:51 net-next-old d0671115869d 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 12:33 net-next-old d0671115869d 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 12:33 net-next-old d0671115869d 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 12:31 net-next-old d0671115869d 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 09:38 net-next-old c554520f2cbe 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 09:38 net-next-old c554520f2cbe 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 08:15 net-next-old c554520f2cbe 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 06:59 net-next-old c554520f2cbe 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 06:34 net-next-old c554520f2cbe 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 06:34 net-next-old c554520f2cbe 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 04:48 net-next-old c554520f2cbe 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 04:14 net-next-old c554520f2cbe 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/25 03:52 net-next-old c554520f2cbe 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/24 23:35 net-next-old c554520f2cbe 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/24 22:16 net-next-old c554520f2cbe 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/24 18:08 net-next-old 32e54254bab8 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/24 17:57 net-next-old 32e54254bab8 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/24 12:31 net-next-old 32e54254bab8 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/24 11:51 net-next-old 32e54254bab8 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/24 11:51 net-next-old 32e54254bab8 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/24 11:51 net-next-old 32e54254bab8 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/24 07:32 net-next-old 32e54254bab8 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/24 07:04 net-next-old 32e54254bab8 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/24 06:52 net-next-old 32e54254bab8 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/24 06:26 net-next-old 32e54254bab8 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/24 06:13 net-next-old 32e54254bab8 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
2023/01/24 05:04 net-next-old 32e54254bab8 9dfcf09c .config console log report info ci-upstream-net-kasan-gce general protection fault in pause_prepare_data
* Struck through repros no longer work on HEAD.