Debian GNU/Linux 7 syzkaller ttyS0 2017/10/28 09:06:50 parsed 1 programs 2017/10/28 09:06:50 executed programs: 0 syzkaller login: [ 21.725014] ================================================================== [ 21.725649] BUG: KASAN: use-after-free in packet_getsockopt+0xc72/0xe00 [ 21.726150] Read of size 8 at addr ffff88003d316798 by task syz-executor0/3012 [ 21.726772] [ 21.726910] CPU: 3 PID: 3012 Comm: syz-executor0 Not tainted 4.14.0-rc5-next-20171018+ #8 [ 21.727492] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Bochs 01/01/2011 [ 21.728067] Call Trace: [ 21.728278] dump_stack+0x194/0x257 [ 21.728617] ? arch_local_irq_restore+0x53/0x53 [ 21.729049] ? show_regs_print_info+0x65/0x65 [ 21.729464] ? lock_release+0xa40/0xa40 [ 21.729837] ? packet_getsockopt+0xc72/0xe00 [ 21.730153] print_address_description+0x73/0x250 [ 21.730497] ? packet_getsockopt+0xc72/0xe00 [ 21.730814] kasan_report+0x25b/0x340 [ 21.731167] __asan_report_load8_noabort+0x14/0x20 [ 21.731619] packet_getsockopt+0xc72/0xe00 [ 21.731994] ? packet_notifier+0x950/0x950 [ 21.732308] ? SYSC_perf_event_open+0x4c3/0x2e00 [ 21.732666] ? __fget_light+0x297/0x380 [ 21.732959] ? sock_has_perm+0x29c/0x400 [ 21.733263] ? selinux_secmark_relabel_packet+0xc0/0xc0 [ 21.733659] ? perf_event_set_output+0x5a0/0x5a0 [ 21.734011] ? sk_free+0x2f/0x40 [ 21.734273] ? selinux_socket_getsockopt+0x36/0x40 [ 21.734637] ? security_socket_getsockopt+0x89/0xb0 [ 21.735010] SyS_getsockopt+0x178/0x340 [ 21.735337] ? SyS_setsockopt+0x360/0x360 [ 21.735684] ? entry_SYSCALL_64_fastpath+0x5/0xbe [ 21.736046] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 21.736416] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 21.736771] entry_SYSCALL_64_fastpath+0x1f/0xbe [ 21.737122] RIP: 0033:0x447c89 [ 21.737354] RSP: 002b:00007f48262e6bd8 EFLAGS: 00000246 ORIG_RAX: 0000000000000037 [ 21.737931] RAX: ffffffffffffffda RBX: 00007f48262e76cc RCX: 0000000000447c89 [ 21.738467] RDX: 0000000000000015 RSI: 0000000000000107 RDI: 0000000000000011 [ 21.739082] RBP: 0000000000000082 R08: 00000000208a5000 R09: 0000000000000000 [ 21.739742] R10: 0000000020ec8000 R11: 0000000000000246 R12: 0000000000000000 [ 21.740400] R13: 0000000000000000 R14: 00007f48262e79c0 R15: 00007f48262e7700 [ 21.741071] [ 21.741220] Allocated by task 3011: [ 21.741518] save_stack+0x43/0xd0 [ 21.741775] kasan_kmalloc+0xad/0xe0 [ 21.742023] kmem_cache_alloc_trace+0x136/0x750 [ 21.742310] fanout_add+0x27e/0x1480 [ 21.742862] packet_setsockopt+0xfdc/0x1e80 [ 21.743183] SyS_setsockopt+0x189/0x360 [ 21.743479] entry_SYSCALL_64_fastpath+0x1f/0xbe [ 21.743824] [ 21.743945] Freed by task 3011: [ 21.744181] save_stack+0x43/0xd0 [ 21.744435] kasan_slab_free+0x71/0xc0 [ 21.744720] kfree+0xca/0x250 [ 21.744947] fanout_add+0x432/0x1480 [ 21.745196] packet_setsockopt+0xfdc/0x1e80 [ 21.745455] SyS_setsockopt+0x189/0x360 [ 21.745690] entry_SYSCALL_64_fastpath+0x1f/0xbe [ 21.745965] [ 21.746064] The buggy address belongs to the object at ffff88003d316780 [ 21.746064] which belongs to the cache kmalloc-128 of size 128 [ 21.746954] The buggy address is located 24 bytes inside of [ 21.746954] 128-byte region [ffff88003d316780, ffff88003d316800) [ 21.747810] The buggy address belongs to the page: [ 21.748170] page:ffffea0000f4c580 count:1 mapcount:0 mapping:ffff88003d316000 index:0x0 [ 21.748765] flags: 0x100000000000100(slab) [ 21.749078] raw: 0100000000000100 ffff88003d316000 0000000000000000 0000000100000015 [ 21.749657] raw: ffffea0000f54a60 ffffea0000f23320 ffff88003e800640 0000000000000000 [ 21.750228] page dumped because: kasan: bad access detected [ 21.750644] [ 21.750764] Memory state around the buggy address: [ 21.751126] ffff88003d316680: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb [ 21.751666] ffff88003d316700: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc [ 21.752204] >ffff88003d316780: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 21.752746] ^ [ 21.753037] ffff88003d316800: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb [ 21.753545] ffff88003d316880: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc [ 21.754135] ================================================================== [ 21.754676] Disabling lock debugging due to kernel taint [ 21.755087] Kernel panic - not syncing: panic_on_warn set ... [ 21.755087] [ 21.755647] CPU: 3 PID: 3012 Comm: syz-executor0 Tainted: G B 4.14.0-rc5-next-20171018+ #8 [ 21.756375] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Bochs 01/01/2011 [ 21.757049] Call Trace: [ 21.757298] dump_stack+0x194/0x257 [ 21.757578] ? arch_local_irq_restore+0x53/0x53 [ 21.757962] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 21.758426] ? vsnprintf+0x1ed/0x1900 [ 21.758775] ? packet_getsockopt+0xbf0/0xe00 [ 21.759163] panic+0x1e4/0x41c [ 21.759430] ? refcount_error_report+0x214/0x214 [ 21.759790] ? add_taint+0x1c/0x50 [ 21.760066] ? add_taint+0x1c/0x50 [ 21.760410] ? packet_getsockopt+0xc72/0xe00 [ 21.760801] kasan_end_report+0x50/0x50 [ 21.761151] kasan_report+0x144/0x340 [ 21.761446] __asan_report_load8_noabort+0x14/0x20 [ 21.761832] packet_getsockopt+0xc72/0xe00 [ 21.762154] ? packet_notifier+0x950/0x950 [ 21.762524] ? SYSC_perf_event_open+0x4c3/0x2e00 [ 21.762901] ? __fget_light+0x297/0x380 [ 21.763192] ? sock_has_perm+0x29c/0x400 [ 21.763907] ? selinux_secmark_relabel_packet+0xc0/0xc0 [ 21.764354] ? perf_event_set_output+0x5a0/0x5a0 [ 21.764789] ? sk_free+0x2f/0x40 [ 21.765104] ? selinux_socket_getsockopt+0x36/0x40 [ 21.765557] ? security_socket_getsockopt+0x89/0xb0 [ 21.766019] SyS_getsockopt+0x178/0x340 [ 21.766423] ? SyS_setsockopt+0x360/0x360 [ 21.766832] ? entry_SYSCALL_64_fastpath+0x5/0xbe [ 21.767271] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 21.767596] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 21.767878] entry_SYSCALL_64_fastpath+0x1f/0xbe [ 21.768158] RIP: 0033:0x447c89 [ 21.768345] RSP: 002b:00007f48262e6bd8 EFLAGS: 00000246 ORIG_RAX: 0000000000000037 [ 21.768820] RAX: ffffffffffffffda RBX: 00007f48262e76cc RCX: 0000000000447c89 [ 21.769290] RDX: 0000000000000015 RSI: 0000000000000107 RDI: 0000000000000011 [ 21.769850] RBP: 0000000000000082 R08: 00000000208a5000 R09: 0000000000000000 [ 21.770383] R10: 0000000020ec8000 R11: 0000000000000246 R12: 0000000000000000 [ 21.770912] R13: 0000000000000000 R14: 00007f48262e79c0 R15: 00007f48262e7700 [ 21.771500] Dumping ftrace buffer: [ 21.771760] (ftrace buffer empty) [ 21.772028] Kernel Offset: disabled [ 21.772296] Rebooting in 86400 seconds..