syzbot


BUG: unable to handle kernel paging request in dummy_set_vf_vlan

Status: fixed on 2019/12/16 09:09
Reported-by: syzbot+8e5106343b09a9654381@syzkaller.appspotmail.com
Fix commit: 9ed49fc95f37 net: rtnetlink: prevent underflows in do_setvfinfo()
First crash: 1713d, last: 1619d
Fix bisection: fixed by (bisect log) :
commit 9ed49fc95f37a457d940324c033c20d85cefb930
Author: Dan Carpenter <dan.carpenter@oracle.com>
Date: Wed Nov 20 12:34:38 2019 +0000

  net: rtnetlink: prevent underflows in do_setvfinfo()

  

Sample crash report:
random: sshd: uninitialized urandom read (32 bytes read)
random: sshd: uninitialized urandom read (32 bytes read)
random: sshd: uninitialized urandom read (32 bytes read)
audit: type=1400 audit(1565476458.950:36): avc:  denied  { map } for  pid=6922 comm="syz-executor929" path="/root/syz-executor929461843" dev="sda1" ino=16483 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:user_home_t:s0 tclass=file permissive=1
device dummy0 entered promiscuous mode
BUG: unable to handle kernel paging request at fffffff850000006
IP: dummy_set_vf_vlan+0xb8/0x180 drivers/net/dummy.c:192
PGD 766d067 P4D 766d067 PUD 0 
Oops: 0002 [#1] PREEMPT SMP KASAN
Modules linked in:
CPU: 1 PID: 6922 Comm: syz-executor929 Not tainted 4.14.138 #34
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
task: ffff8880a0a26700 task.stack: ffff888085e50000
RIP: 0010:dummy_set_vf_vlan+0xb8/0x180 drivers/net/dummy.c:192
RSP: 0018:ffff888085e57298 EFLAGS: 00010246
RAX: 0000000000000007 RBX: fffffff850000000 RCX: 0000000000000000
RDX: fffffff850000000 RSI: 00000000ae000000 RDI: fffffff850000006
RBP: ffff888085e572c8 R08: 0000000000000081 R09: ffff888085e574c8
R10: ffffed1010bcaea5 R11: ffff888085e5752f R12: 0000000000000000
R13: ffff8880a19d8a00 R14: 00000000000002fd R15: 0000000000000081
FS:  0000000000e7d880(0000) GS:ffff8880aef00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: fffffff850000006 CR3: 000000008bca6000 CR4: 00000000001406e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 do_setvfinfo net/core/rtnetlink.c:1783 [inline]
 do_setlink+0x11ba/0x2d50 net/core/rtnetlink.c:2135
 rtnl_setlink+0x225/0x320 net/core/rtnetlink.c:2303
 rtnetlink_rcv_msg+0x3eb/0xb70 net/core/rtnetlink.c:4285
 netlink_rcv_skb+0x14f/0x3c0 net/netlink/af_netlink.c:2432
 rtnetlink_rcv+0x1d/0x30 net/core/rtnetlink.c:4297
 netlink_unicast_kernel net/netlink/af_netlink.c:1286 [inline]
 netlink_unicast+0x45d/0x640 net/netlink/af_netlink.c:1312
 netlink_sendmsg+0x7c4/0xc60 net/netlink/af_netlink.c:1877
 sock_sendmsg_nosec net/socket.c:646 [inline]
 sock_sendmsg+0xce/0x110 net/socket.c:656
 ___sys_sendmsg+0x70a/0x840 net/socket.c:2062
 __sys_sendmsg+0xb9/0x140 net/socket.c:2096
 SYSC_sendmsg net/socket.c:2107 [inline]
 SyS_sendmsg+0x2d/0x50 net/socket.c:2103
 do_syscall_64+0x1e8/0x640 arch/x86/entry/common.c:292
 entry_SYSCALL_64_after_hwframe+0x42/0xb7
RIP: 0033:0x440239
RSP: 002b:00007ffcacb452b8 EFLAGS: 00000246 ORIG_RAX: 000000000000002e
RAX: ffffffffffffffda RBX: 00000000004002c8 RCX: 0000000000440239
RDX: 0000000000000000 RSI: 000000002000a000 RDI: 0000000000000003
RBP: 00000000006ca018 R08: 00000000004002c8 R09: 00000000004002c8
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000401ac0
R13: 0000000000401b50 R14: 0000000000000000 R15: 0000000000000000
Code: 48 c1 e3 03 48 01 da 48 8d 7a 06 48 89 f9 48 c1 e9 03 0f b6 0c 01 48 89 f8 83 e0 07 83 c0 01 38 c8 7c 08 84 c9 0f 85 92 00 00 00 <66> 44 89 72 06 4d 8b b5 c0 0a 00 00 45 0f b6 e4 48 b8 00 00 00 
RIP: dummy_set_vf_vlan+0xb8/0x180 drivers/net/dummy.c:192 RSP: ffff888085e57298
CR2: fffffff850000006
---[ end trace d18da892bd3253f9 ]---

Crashes (5):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2019/08/10 22:37 linux-4.14.y 3ffe1e79c174 acb51638 .config console log report syz C ci2-linux-4-14
2019/11/12 17:08 linux-4.14.y 4762bcd451a9 048f2d49 .config console log report ci2-linux-4-14
2019/09/05 21:04 linux-4.14.y 01fd1694b93c bf6bcce4 .config console log report ci2-linux-4-14
2019/08/19 22:43 linux-4.14.y 45f092f9e9cb ae348fb7 .config console log report ci2-linux-4-14
2019/08/10 22:12 linux-4.14.y 3ffe1e79c174 acb51638 .config console log report ci2-linux-4-14
* Struck through repros no longer work on HEAD.