syzbot


general protection fault in trie_get_next_key

Status: fixed on 2018/02/02 04:39
Subsystems: bpf
[Documentation on labels]
Fix commit: 6dd1ec6c7a2c bpf: fix kernel page fault in lpm map trie_get_next_key
First crash: 2274d, last: 2274d
Discussions (1)
Title Replies (including bot) Last reply
[PATCH bpf-next 0/2] bpf: implement MAP_GET_NEXT_KEY command for LPM_TRIE map 8 (8) 2018/01/26 16:50

Sample crash report:
kasan: CONFIG_KASAN_INLINE enabled
kasan: GPF could be caused by NULL-ptr deref or user memory access
general protection fault: 0000 [#1] SMP KASAN
Dumping ftrace buffer:
   (ftrace buffer empty)
Modules linked in:
CPU: 0 PID: 9674 Comm: syzkaller878858 Not tainted 4.15.0-rc8+ #5
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
RIP: 0010:trie_get_next_key+0x3c2/0xf10 kernel/bpf/lpm_trie.c:682
RSP: 0018:ffff8801d099f628 EFLAGS: 00010202
RAX: dffffc0000000000 RBX: 0000000000000000 RCX: ffffffff81829a9d
RDX: 0000000000000004 RSI: ffffffff86941580 RDI: 0000000000000020
RBP: ffff8801d099f8b0 R08: 0000000000000000 R09: 1ffff1003a133e24
R10: 000000009bd72077 R11: 00000000c3e6aa31 R12: 0000000000000000
R13: 1ffff1003a133f01 R14: fffffffffffffff4 R15: 0000000000000000
FS:  00007f681e65b700(0000) GS:ffff8801db200000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000020013f33 CR3: 00000001d067d003 CR4: 00000000001606f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 map_get_next_key kernel/bpf/syscall.c:842 [inline]
 SYSC_bpf kernel/bpf/syscall.c:1881 [inline]
 SyS_bpf+0x11b4/0x4860 kernel/bpf/syscall.c:1846
 entry_SYSCALL_64_fastpath+0x29/0xa0
RIP: 0033:0x445e99
RSP: 002b:00007f681e65adb8 EFLAGS: 00000246 ORIG_RAX: 0000000000000141
RAX: ffffffffffffffda RBX: 00000000006dbc3c RCX: 0000000000445e99
RDX: 0000000000000018 RSI: 000000002000e000 RDI: 0000000000000004
RBP: 00000000006dbc38 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007ffffef970bf R14: 00007f681e65b9c0 R15: 0000000000000007
Code: 19 d3 ff e8 81 98 ed ff 4d 85 e4 0f 85 30 ff ff ff e8 73 98 ed ff 49 8d 7f 20 48 b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 <0f> b6 04 02 84 c0 74 08 3c 03 0f 8e f2 0a 00 00 48 8b b5 98 fd 
RIP: trie_get_next_key+0x3c2/0xf10 kernel/bpf/lpm_trie.c:682 RSP: ffff8801d099f628
---[ end trace dc48fb2803e7b0a3 ]---
Kernel panic - not syncing: Fatal exception
Dumping ftrace buffer:
   (ftrace buffer empty)
Kernel Offset: disabled
Rebooting in 86400 seconds..

Crashes (3):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2018/01/26 11:30 bpf-next 82f1e0f3acf0 1d18b112 .config console log report syz C ci-upstream-bpf-next-kasan-gce
2018/01/26 11:14 bpf-next 82f1e0f3acf0 1d18b112 .config console log report ci-upstream-bpf-next-kasan-gce
2018/01/26 00:18 bpf-next e9dcd80b9d77 1d18b112 .config console log report ci-upstream-bpf-next-kasan-gce
* Struck through repros no longer work on HEAD.