syzbot


general protection fault in tcf_ife_init

Status: fixed on 2019/12/03 19:11
Reported-by: syzbot+148745e1206447da2ee7@syzkaller.appspotmail.com
Fix commit: c4c8899376c2 ife: error out when nla attributes are empty
First crash: 1953d, last: 1936d
Fix bisection: fixed by (bisect log) :
commit c4c8899376c2eb363c70b0b200434cc9abd3d34e
Author: Cong Wang <xiyou.wangcong@gmail.com>
Date: Tue Jul 23 04:43:00 2019 +0000

  ife: error out when nla attributes are empty

  
Similar bugs (2)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-4.14 general protection fault in tcf_ife_init C done 12 1944d 1953d 1/1 fixed on 2019/12/03 19:05
upstream general protection fault in tcf_ife_init C done 72 1936d 1951d 12/28 fixed on 2019/08/27 17:15

Sample crash report:
audit: type=1400 audit(1563585819.260:36): avc:  denied  { map } for  pid=7874 comm="syz-executor277" path="/root/syz-executor277433476" dev="sda1" ino=16484 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:user_home_t:s0 tclass=file permissive=1
netlink: 4 bytes leftover after parsing attributes in process `syz-executor277'.
kasan: CONFIG_KASAN_INLINE enabled
kasan: GPF could be caused by NULL-ptr deref or user memory access
general protection fault: 0000 [#1] PREEMPT SMP KASAN
CPU: 1 PID: 7874 Comm: syz-executor277 Not tainted 4.19.59 #32
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
RIP: 0010:nla_parse_nested /./include/net/netlink.h:765 [inline]
RIP: 0010:tcf_ife_init+0x221/0x17d0 /net/sched/act_ife.c:487
Code: fb 48 c7 c2 99 43 81 85 be 01 00 00 00 48 c7 c7 60 da 79 88 e8 c0 26 d1 fb 48 89 da 48 b8 00 00 00 00 00 fc ff df 48 c1 ea 03 <0f> b6 14 02 48 89 d8 83 e0 07 83 c0 01 38 d0 7c 08 84 d2 0f 85 83
RSP: 0018:ffff888096ed6ee0 EFLAGS: 00010246
RAX: dffffc0000000000 RBX: 0000000000000000 RCX: 1ffff11012e9c1b6
RDX: 0000000000000000 RSI: 0000000000000002 RDI: 0000000000000282
RBP: ffff888096ed7068 R08: ffff8880974e0540 R09: 0000000000000001
R10: ffffed1015d24732 R11: ffff8880ae923993 R12: 0000000000000001
R13: ffff88809b1eedc0 R14: ffff888096ed7040 R15: 0000000000000001
FS:  0000000001cd6880(0000) GS:ffff8880ae900000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000020000180 CR3: 00000000a0b53000 CR4: 00000000001406e0
Call Trace:
 tcf_action_init_1+0x804/0xc40 /net/sched/act_api.c:870
 tcf_action_init+0x23e/0x360 /net/sched/act_api.c:933
 tcf_action_add+0xe8/0x370 /net/sched/act_api.c:1313
 tc_ctl_action+0x37a/0x46f /net/sched/act_api.c:1365
 rtnetlink_rcv_msg+0x463/0xb00 /net/core/rtnetlink.c:4747
 netlink_rcv_skb+0x17d/0x460 /net/netlink/af_netlink.c:2454
 rtnetlink_rcv+0x1d/0x30 /net/core/rtnetlink.c:4765
 netlink_unicast_kernel /net/netlink/af_netlink.c:1317 [inline]
 netlink_unicast+0x537/0x720 /net/netlink/af_netlink.c:1343
 netlink_sendmsg+0x8ae/0xd70 /net/netlink/af_netlink.c:1908
 sock_sendmsg_nosec /net/socket.c:622 [inline]
 sock_sendmsg+0xd7/0x130 /net/socket.c:632
 ___sys_sendmsg+0x803/0x920 /net/socket.c:2115
 __sys_sendmsg+0x105/0x1d0 /net/socket.c:2153
 __do_sys_sendmsg /net/socket.c:2162 [inline]
 __se_sys_sendmsg /net/socket.c:2160 [inline]
 __x64_sys_sendmsg+0x78/0xb0 /net/socket.c:2160
 do_syscall_64+0xfd/0x620 /arch/x86/entry/common.c:293
 entry_SYSCALL_64_after_hwframe+0x49/0xbe
RIP: 0033:0x4401d9
Code: 18 89 d0 c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 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 0f 83 fb 13 fc ff c3 66 2e 0f 1f 84 00 00 00 00
RSP: 002b:00007fff4283e4c8 EFLAGS: 00000246 ORIG_RAX: 000000000000002e
RAX: ffffffffffffffda RBX: 00000000004002c8 RCX: 00000000004401d9
RDX: 0000000000000000 RSI: 0000000020000180 RDI: 0000000000000003
RBP: 00000000006ca018 R08: 0000000000000000 R09: 00000000004002c8
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000401a60
R13: 0000000000401af0 R14: 0000000000000000 R15: 0000000000000000
Modules linked in:
---[ end trace 700de6051900a398 ]---
RIP: 0010:nla_parse_nested /./include/net/netlink.h:765 [inline]
RIP: 0010:tcf_ife_init+0x221/0x17d0 /net/sched/act_ife.c:487
Code: fb 48 c7 c2 99 43 81 85 be 01 00 00 00 48 c7 c7 60 da 79 88 e8 c0 26 d1 fb 48 89 da 48 b8 00 00 00 00 00 fc ff df 48 c1 ea 03 <0f> b6 14 02 48 89 d8 83 e0 07 83 c0 01 38 d0 7c 08 84 d2 0f 85 83
RSP: 0018:ffff888096ed6ee0 EFLAGS: 00010246
RAX: dffffc0000000000 RBX: 0000000000000000 RCX: 1ffff11012e9c1b6
RDX: 0000000000000000 RSI: 0000000000000002 RDI: 0000000000000282
RBP: ffff888096ed7068 R08: ffff8880974e0540 R09: 0000000000000001
R10: ffffed1015d24732 R11: ffff8880ae923993 R12: 0000000000000001
R13: ffff88809b1eedc0 R14: ffff888096ed7040 R15: 0000000000000001
FS:  0000000001cd6880(0000) GS:ffff8880ae900000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000020000180 CR3: 00000000a0b53000 CR4: 00000000001406e0

Crashes (15):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2019/07/20 01:26 linux-4.19.y 3bd837bfe431 1656845f .config console log report syz C ci2-linux-4-19
2019/07/20 00:42 linux-4.19.y 3bd837bfe431 1656845f .config console log report syz C ci2-linux-4-19
2019/07/20 00:24 linux-4.19.y 3bd837bfe431 1656845f .config console log report syz C ci2-linux-4-19
2019/07/20 00:06 linux-4.19.y 3bd837bfe431 1656845f .config console log report syz C ci2-linux-4-19
2019/07/19 23:48 linux-4.19.y 3bd837bfe431 1656845f .config console log report syz C ci2-linux-4-19
2019/07/19 23:30 linux-4.19.y 3bd837bfe431 1656845f .config console log report syz C ci2-linux-4-19
2019/07/19 21:48 linux-4.19.y 3bd837bfe431 1656845f .config console log report syz C ci2-linux-4-19
2019/08/05 21:51 linux-4.19.y b3060a1a313f 6affd8e8 .config console log report ci2-linux-4-19
2019/08/05 21:49 linux-4.19.y b3060a1a313f 6affd8e8 .config console log report ci2-linux-4-19
2019/07/29 15:40 linux-4.19.y 64f4694072aa f67095ee .config console log report ci2-linux-4-19
2019/07/21 00:23 linux-4.19.y 3bd837bfe431 1656845f .config console log report ci2-linux-4-19
2019/07/19 23:31 linux-4.19.y 3bd837bfe431 1656845f .config console log report ci2-linux-4-19
2019/07/19 23:29 linux-4.19.y 3bd837bfe431 1656845f .config console log report ci2-linux-4-19
2019/07/19 21:25 linux-4.19.y 3bd837bfe431 1656845f .config console log report ci2-linux-4-19
2019/07/19 21:25 linux-4.19.y 3bd837bfe431 1656845f .config console log report ci2-linux-4-19
* Struck through repros no longer work on HEAD.