aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitry Vyukov <dvyukov@google.com>2019-11-06 18:06:12 +0100
committerDmitry Vyukov <dvyukov@google.com>2019-11-06 18:06:12 +0100
commitd797d2018f9550530c469ce03b5ae36cfa1ebd23 (patch)
treea537b346fc1bc0c3abce2ee9a2c8ae4ed009ec7a
parentda505f84d3e8fc3bb7c54fea76eb5574987ee01a (diff)
downloadsyzkaller-d797d2018f9550530c469ce03b5ae36cfa1ebd23.tar.gz
pkg/report: fix up panic handling
Obviously there is an exception to every exception in kernel output parsing...
-rw-r--r--pkg/report/report.go5
-rw-r--r--pkg/report/testdata/linux/report/44872
2 files changed, 76 insertions, 1 deletions
diff --git a/pkg/report/report.go b/pkg/report/report.go
index 4528a0404..c9832c9af 100644
--- a/pkg/report/report.go
+++ b/pkg/report/report.go
@@ -606,6 +606,9 @@ var commonOopses = []*oops{
noStackTrace: true,
},
},
- []*regexp.Regexp{},
+ []*regexp.Regexp{
+ // This can match some kernel functions (skb_panic, skb_over_panic).
+ compile("_panic:"),
+ },
},
}
diff --git a/pkg/report/testdata/linux/report/448 b/pkg/report/testdata/linux/report/448
new file mode 100644
index 000000000..a72060a42
--- /dev/null
+++ b/pkg/report/testdata/linux/report/448
@@ -0,0 +1,72 @@
+TITLE: kernel BUG at net/core/skbuff.c:LINE!
+
+[ 666.846118][T27281] skbuff: skb_over_panic: text:00000000db6cba37 len:1744 put:72 head:0000000092f15526 data:0000000092f15526 tail:0x6d0 end:0x6c0 dev:<NULL>
+[ 666.877381][T27281] ------------[ cut here ]------------
+[ 666.882879][T27281] kernel BUG at net/core/skbuff.c:108!
+[ 666.945527][T27281] invalid opcode: 0000 [#1] PREEMPT SMP KASAN
+[ 666.947856][ T4000] kobject: 'loop3' (000000001cf84d51): kobject_uevent_env
+[ 666.951639][T27281] CPU: 1 PID: 27281 Comm: syz-executor.2 Not tainted 5.4.0-rc6-next-20191106 #0
+[ 666.967725][T27281] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
+[ 666.977894][T27281] RIP: 0010:skb_panic+0x176/0x178
+[ 666.982936][T27281] Code: 40 03 fc 4c 8b 4d b8 8b 4b 70 41 57 45 89 f0 4c 89 ea ff 75 d0 4c 89 e6 48 c7 c7 20 9d 48 88 ff 75 c8 ff 75 c0 e8 c2 a5 b0 fb <0f> 0b e8 57 16 c7 fb 4c 8b 6d 08 e8 8e 37 03 fc 48 c7 c1 c0 a9 48
+[ 667.002552][T27281] RSP: 0018:ffff888050cb6ab8 EFLAGS: 00010282
+[ 667.008625][T27281] RAX: 0000000000000089 RBX: ffff8880996952c0 RCX: 0000000000000000
+[ 667.016612][T27281] RDX: 0000000000000000 RSI: ffffffff815d0b86 RDI: ffffed100a196d49
+[ 667.024588][T27281] RBP: ffff888050cb6b20 R08: 0000000000000089 R09: ffffed1015d26161
+[ 667.032567][T27281] R10: ffffed1015d26160 R11: ffff8880ae930b07 R12: ffffffff8848aa00
+[ 667.040521][T27281] R13: ffffffff867161e9 R14: 0000000000000048 R15: ffffffff88489ce0
+[ 667.048476][T27281] FS: 00007faa05750700(0000) GS:ffff8880ae900000(0000) knlGS:0000000000000000
+[ 667.057387][T27281] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
+[ 667.063959][T27281] CR2: 0000001b2f121000 CR3: 00000000a15c7000 CR4: 00000000001406e0
+[ 667.071918][T27281] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
+[ 667.079872][T27281] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
+[ 667.087823][T27281] Call Trace:
+[ 667.096556][T27281] skb_put.cold+0x23/0x23
+[ 667.100871][T27281] pfkey_send_acquire+0x1bd9/0x2620
+[ 667.106099][T27281] km_query+0xcb/0x210
+[ 667.110181][T27281] xfrm_state_find+0x2d06/0x5030
+[ 667.124844][T27281] xfrm_tmpl_resolve+0x32a/0xc90
+[ 667.177557][T27281] xfrm_resolve_and_create_bundle+0x137/0x2660
+[ 667.231869][T27281] xfrm_lookup_with_ifid+0x278/0x1fb0
+[ 667.269646][T27281] xfrm_lookup_route+0x3b/0x1e0
+[ 667.274486][T27281] ip_route_output_flow+0xad/0xc0
+[ 667.279523][T27281] udp_sendmsg+0x1bcd/0x2810
+[ 667.348210][T27281] udpv6_sendmsg+0x13a6/0x2990
+[ 667.442027][T27281] inet6_sendmsg+0x9e/0xe0
+[ 667.455623][T27281] sock_sendmsg+0xd7/0x130
+[ 667.460028][T27281] ___sys_sendmsg+0x3e2/0x920
+[ 667.527903][T27281] __sys_sendmmsg+0x1bf/0x4d0
+[ 667.575025][T27281] __x64_sys_sendmmsg+0x9d/0x100
+[ 667.584610][T27281] do_syscall_64+0xfa/0x760
+[ 667.589100][T27281] entry_SYSCALL_64_after_hwframe+0x49/0xbe
+[ 667.594973][T27281] RIP: 0033:0x45a219
+[ 667.598856][T27281] Code: ad b6 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 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 0f 83 7b b6 fb ff c3 66 2e 0f 1f 84 00 00 00 00
+[ 667.618442][T27281] RSP: 002b:00007faa0574fc78 EFLAGS: 00000246 ORIG_RAX: 0000000000000133
+[ 667.626841][T27281] RAX: ffffffffffffffda RBX: 0000000000000004 RCX: 000000000045a219
+[ 667.634794][T27281] RDX: 00000000000005c3 RSI: 0000000020000240 RDI: 0000000000000004
+[ 667.642751][T27281] RBP: 000000000075bf20 R08: 0000000000000000 R09: 0000000000000000
+[ 667.650716][T27281] R10: 00000000000003e8 R11: 0000000000000246 R12: 00007faa057506d4
+[ 667.658670][T27281] R13: 00000000004c7f9d R14: 00000000004de3c8 R15: 00000000ffffffff
+[ 667.666637][T27281] Modules linked in:
+[ 667.679068][ T4000] kobject: 'loop3' (000000001cf84d51): fill_kobj_path: path = '/devices/virtual/block/loop3'
+[ 667.826025][ T4000] kobject: 'loop4' (0000000063730daf): kobject_uevent_env
+[ 667.845799][ T4000] kobject: 'loop4' (0000000063730daf): fill_kobj_path: path = '/devices/virtual/block/loop4'
+[ 667.861727][T27281] ---[ end trace 20c16582a7cd5c2d ]---
+[ 667.917781][T27281] RIP: 0010:skb_panic+0x176/0x178
+[ 667.918664][ T4000] kobject: 'loop0' (00000000e965cba2): kobject_uevent_env
+[ 667.929125][T27281] Code: 40 03 fc 4c 8b 4d b8 8b 4b 70 41 57 45 89 f0 4c 89 ea ff 75 d0 4c 89 e6 48 c7 c7 20 9d 48 88 ff 75 c8 ff 75 c0 e8 c2 a5 b0 fb <0f> 0b e8 57 16 c7 fb 4c 8b 6d 08 e8 8e 37 03 fc 48 c7 c1 c0 a9 48
+[ 667.987391][T27281] RSP: 0018:ffff888050cb6ab8 EFLAGS: 00010282
+[ 667.988328][ T4000] kobject: 'loop0' (00000000e965cba2): fill_kobj_path: path = '/devices/virtual/block/loop0'
+[ 667.994025][T27281] RAX: 0000000000000089 RBX: ffff8880996952c0 RCX: 0000000000000000
+[ 668.020454][T27281] RDX: 0000000000000000 RSI: ffffffff815d0b86 RDI: ffffed100a196d49
+[ 668.028871][T27281] RBP: ffff888050cb6b20 R08: 0000000000000089 R09: ffffed1015d26161
+[ 668.037260][T27281] R10: ffffed1015d26160 R11: ffff8880ae930b07 R12: ffffffff8848aa00
+[ 668.057550][T27281] R13: ffffffff867161e9 R14: 0000000000000048 R15: ffffffff88489ce0
+[ 668.071083][T27281] FS: 00007faa05750700(0000) GS:ffff8880ae800000(0000) knlGS:0000000000000000
+[ 668.091098][T27281] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
+[ 668.098039][T27281] CR2: 00007ffe277e1dcc CR3: 00000000a15c7000 CR4: 00000000001406f0
+[ 668.108229][T27281] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
+[ 668.116480][T27281] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
+[ 668.124703][T27281] Kernel panic - not syncing: Fatal exception
+[ 668.132190][T27281] Kernel Offset: disabled
+[ 668.136526][T27281] Rebooting in 86400 seconds..