INIT: Entering runlevel: 2 [info] Using makefile-style concurrent boot in runlevel 2. [....] Starting enhanced syslogd: rsyslogd[?25l[?1c7[ ok 8[?25h[?0c. [....] Starting periodic command scheduler: cron[?25l[?1c7[ ok 8[?25h[?0c. [....] Starting OpenBSD Secure Shell server: sshd[?25l[?1c7[ ok 8[?25h[?0c. Debian GNU/Linux 7 syzkaller ttyS0 Warning: Permanently added 'ci-upstream-kasan-gce-6,10.128.0.37' (ECDSA) to the list of known hosts. 2017/08/21 11:40:33 parsed 1 programs 2017/08/21 11:40:33 executed programs: 0 2017/08/21 11:40:38 executed programs: 829 2017/08/21 11:40:43 executed programs: 1497 2017/08/21 11:40:48 executed programs: 2170 2017/08/21 11:40:53 executed programs: 2862 2017/08/21 11:40:58 executed programs: 3556 2017/08/21 11:41:03 executed programs: 4242 2017/08/21 11:41:08 executed programs: 4938 2017/08/21 11:41:13 executed programs: 5648 2017/08/21 11:41:18 executed programs: 6355 2017/08/21 11:41:23 executed programs: 7071 2017/08/21 11:41:28 executed programs: 7779 2017/08/21 11:41:33 executed programs: 8471 syzkaller login: [ 880.805716] ================================================================== [ 880.806955] BUG: KASAN: use-after-free in free_ldt_struct.part.2+0x10a/0x150 [ 880.808438] Read of size 4 at addr ffff8801c39572c8 by task syz-executor3/30693 [ 880.809547] [ 880.809819] CPU: 1 PID: 30693 Comm: syz-executor3 Not tainted 4.13.0-rc6+ #44 [ 880.810826] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 880.812064] Call Trace: [ 880.812506] dump_stack+0x194/0x257 [ 880.813120] ? arch_local_irq_restore+0x53/0x53 [ 880.813978] ? show_regs_print_info+0x65/0x65 [ 880.814889] ? free_ldt_struct.part.2+0x10a/0x150 [ 880.815564] print_address_description+0x73/0x250 [ 880.816233] ? free_ldt_struct.part.2+0x10a/0x150 [ 880.816921] kasan_report+0x24e/0x340 [ 880.817469] __asan_report_load4_noabort+0x14/0x20 [ 880.818146] free_ldt_struct.part.2+0x10a/0x150 [ 880.818880] ? rcu_pm_notify+0xc0/0xc0 [ 880.819664] destroy_context_ldt+0x60/0x80 [ 880.820604] __mmdrop+0xe9/0x530 [ 880.821127] ? sighand_ctor+0x50/0x50 [ 880.821738] ? trace_hardirqs_on+0xd/0x10 [ 880.822443] ? percpu_counter_add_batch+0xce/0x130 [ 880.823389] ? free_modinfo_version+0x70/0x70 [ 880.824496] ? __khugepaged_exit+0x43d/0x650 [ 880.825643] ? SyS_munmap+0x30/0x30 [ 880.828550] ? ___might_sleep+0x1/0x470 [ 880.832560] ? __might_sleep+0x95/0x190 [ 880.836540] mmput+0x541/0x6e0 [ 880.839736] ? get_task_exe_file+0xc0/0xc0 [ 880.843979] ? is_current_pgrp_orphaned+0xa0/0xa0 [ 880.848808] ? do_exit+0x979/0x1b10 [ 880.852442] ? lock_downgrade+0x990/0x990 [ 880.856603] ? do_raw_spin_trylock+0x190/0x190 [ 880.861189] ? down_read+0x96/0x150 [ 880.864806] ? do_exit+0x49c/0x1b10 [ 880.868428] ? __down_interruptible+0x6a0/0x6a0 [ 880.873088] ? trace_hardirqs_on+0xd/0x10 [ 880.877227] ? _raw_spin_unlock_irq+0x27/0x70 [ 880.881739] do_exit+0x989/0x1b10 [ 880.885189] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 880.890387] ? mm_update_next_owner+0x930/0x930 [ 880.895054] ? perf_trace_run_bpf_submit+0x1a7/0x290 [ 880.900138] ? perf_trace_run_bpf_submit+0x1a7/0x290 [ 880.905210] ? perf_trace_run_bpf_submit+0x1ae/0x290 [ 880.910287] ? perf_tp_event+0xae0/0xae0 [ 880.914324] ? memset+0x31/0x40 [ 880.917584] ? perf_trace_lock+0x3e9/0x860 [ 880.921806] ? check_noncircular+0x20/0x20 [ 880.926054] ? get_futex_value_locked+0xc3/0xf0 [ 880.930711] ? find_held_lock+0x35/0x1d0 [ 880.934757] ? get_signal+0x855/0x17e0 [ 880.938617] ? lock_downgrade+0x990/0x990 [ 880.942751] do_group_exit+0x149/0x400 [ 880.946608] ? __lock_is_held+0xb6/0x140 [ 880.950638] ? SyS_exit+0x30/0x30 [ 880.954062] ? _raw_spin_unlock_irq+0x27/0x70 [ 880.958531] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 880.963526] get_signal+0x7e8/0x17e0 [ 880.967266] ? ptrace_notify+0x130/0x130 [ 880.971309] ? do_futex+0x781/0x20a0 [ 880.975006] ? lock_release+0xa40/0xa40 [ 880.978963] ? __lock_is_held+0xb6/0x140 [ 880.983024] do_signal+0x94/0x1ee0 [ 880.986536] ? __fget+0x35c/0x570 [ 880.989968] ? _do_fork+0x1ef/0xfb0 [ 880.993564] ? _do_fork+0x2dc/0xfb0 [ 880.997166] ? setup_sigcontext+0x7d0/0x7d0 [ 881.001460] ? fork_idle+0x2d0/0x2d0 [ 881.005150] ? newque+0x577/0x790 [ 881.008580] ? find_held_lock+0x35/0x1d0 [ 881.012629] ? __fget_light+0x297/0x380 [ 881.016576] ? fget_raw+0x20/0x20 [ 881.020010] ? exit_to_usermode_loop+0x98/0x300 [ 881.024669] exit_to_usermode_loop+0x224/0x300 [ 881.029239] ? trace_event_raw_event_sys_exit+0x260/0x260 [ 881.034764] do_syscall_64+0x5d4/0x800 [ 881.038633] ? syscall_return_slowpath+0x450/0x450 [ 881.043539] ? do_futex+0x20a0/0x20a0 [ 881.047312] ? entry_SYSCALL_64_fastpath+0x5/0xbe [ 881.052134] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 881.056950] ? sys_vfork+0x30/0x30 [ 881.060465] entry_SYSCALL64_slow_path+0x25/0x25 [ 881.065187] RIP: 0033:0x4512e9 [ 881.068344] RSP: 002b:00007fc99d3a5c08 EFLAGS: 00000216 ORIG_RAX: 0000000000000038 [ 881.076028] RAX: fffffffffffffdff RBX: 0000000000718000 RCX: 00000000004512e9 [ 881.083279] RDX: 0000000020507ffc RSI: 00000000208a8f43 RDI: 0000000000800000 [ 881.090521] RBP: 00000000000003b0 R08: 0000000020a8a000 R09: 0000000000000000 [ 881.097759] R10: 0000000020117ffc R11: 0000000000000216 R12: 00000000004b65e0 [ 881.104997] R13: 00000000ffffffff R14: 0000000000800000 R15: 00000000208a8f43 [ 881.112271] [ 881.113871] Allocated by task 30693: [ 881.117553] save_stack_trace+0x16/0x20 [ 881.121494] save_stack+0x43/0xd0 [ 881.124917] kasan_kmalloc+0xad/0xe0 [ 881.128609] kmem_cache_alloc_trace+0x12f/0x740 [ 881.133245] alloc_ldt_struct+0x52/0x140 [ 881.137273] write_ldt+0x7b4/0xac0 [ 881.140782] sys_modify_ldt+0x1ef/0x240 [ 881.144722] entry_SYSCALL_64_fastpath+0x1f/0xbe [ 881.149440] [ 881.151037] Freed by task 30693: [ 881.154374] save_stack_trace+0x16/0x20 [ 881.158313] save_stack+0x43/0xd0 [ 881.161735] kasan_slab_free+0x71/0xc0 [ 881.165590] kfree+0xca/0x250 [ 881.168662] free_ldt_struct.part.2+0xdd/0x150 [ 881.173211] destroy_context_ldt+0x60/0x80 [ 881.177411] __mmdrop+0xe9/0x530 [ 881.180743] mmput+0x541/0x6e0 [ 881.183904] copy_process.part.34+0x2315/0x4bd0 [ 881.188539] _do_fork+0x1ef/0xfb0 [ 881.191959] SyS_clone+0x37/0x50 [ 881.195294] do_syscall_64+0x26c/0x800 [ 881.199149] return_from_SYSCALL_64+0x0/0x7a [ 881.203521] [ 881.205117] The buggy address belongs to the object at ffff8801c39572c0 [ 881.205117] which belongs to the cache kmalloc-32 of size 32 [ 881.217566] The buggy address is located 8 bytes inside of [ 881.217566] 32-byte region [ffff8801c39572c0, ffff8801c39572e0) [ 881.229145] The buggy address belongs to the page: [ 881.234046] page:ffffea00070e55c0 count:1 mapcount:0 mapping:ffff8801c3957000 index:0xffff8801c3957fc1 [ 881.243464] flags: 0x200000000000100(slab) [ 881.247671] raw: 0200000000000100 ffff8801c3957000 ffff8801c3957fc1 000000010000003f [ 881.255518] raw: ffffea00070e3fa0 ffffea000730bba0 ffff8801dac001c0 0000000000000000 [ 881.263363] page dumped because: kasan: bad access detected [ 881.269040] [ 881.270637] Memory state around the buggy address: [ 881.275531] ffff8801c3957180: 00 fc fc fc fc fc fc fc fb fb fb fb fc fc fc fc [ 881.282855] ffff8801c3957200: fb fb fb fb fc fc fc fc fb fb fb fb fc fc fc fc [ 881.290181] >ffff8801c3957280: 00 fc fc fc fc fc fc fc fb fb fb fb fc fc fc fc [ 881.297510] ^ [ 881.303187] ffff8801c3957300: fb fb fb fb fc fc fc fc fb fb fb fb fc fc fc fc [ 881.310512] ffff8801c3957380: fb fb fb fb fc fc fc fc fb fb fb fb fc fc fc fc [ 881.317835] ================================================================== [ 881.325161] Disabling lock debugging due to kernel taint [ 881.330700] Kernel panic - not syncing: panic_on_warn set ... [ 881.330700] [ 881.338053] CPU: 1 PID: 30693 Comm: syz-executor3 Tainted: G B 4.13.0-rc6+ #44 [ 881.346518] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 881.355840] Call Trace: [ 881.358398] dump_stack+0x194/0x257 [ 881.361997] ? arch_local_irq_restore+0x53/0x53 [ 881.366639] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 881.371369] ? free_ldt_struct.part.2+0x30/0x150 [ 881.376093] panic+0x1e4/0x417 [ 881.379254] ? __warn+0x1d9/0x1d9 [ 881.382693] ? free_ldt_struct.part.2+0x10a/0x150 [ 881.387512] kasan_end_report+0x50/0x50 [ 881.391458] kasan_report+0x137/0x340 [ 881.395232] __asan_report_load4_noabort+0x14/0x20 [ 881.400128] free_ldt_struct.part.2+0x10a/0x150 [ 881.404764] ? rcu_pm_notify+0xc0/0xc0 [ 881.408620] destroy_context_ldt+0x60/0x80 [ 881.412822] __mmdrop+0xe9/0x530 [ 881.416160] ? sighand_ctor+0x50/0x50 [ 881.419927] ? trace_hardirqs_on+0xd/0x10 [ 881.424047] ? percpu_counter_add_batch+0xce/0x130 [ 881.428954] ? free_modinfo_version+0x70/0x70 [ 881.433414] ? __khugepaged_exit+0x43d/0x650 [ 881.437793] ? SyS_munmap+0x30/0x30 [ 881.441390] ? ___might_sleep+0x1/0x470 [ 881.445345] ? __might_sleep+0x95/0x190 [ 881.449291] mmput+0x541/0x6e0 [ 881.452456] ? get_task_exe_file+0xc0/0xc0 [ 881.456667] ? is_current_pgrp_orphaned+0xa0/0xa0 [ 881.461474] ? do_exit+0x979/0x1b10 [ 881.465069] ? lock_downgrade+0x990/0x990 [ 881.469192] ? do_raw_spin_trylock+0x190/0x190 [ 881.473753] ? down_read+0x96/0x150 [ 881.477344] ? do_exit+0x49c/0x1b10 [ 881.480938] ? __down_interruptible+0x6a0/0x6a0 [ 881.485576] ? trace_hardirqs_on+0xd/0x10 [ 881.489690] ? _raw_spin_unlock_irq+0x27/0x70 [ 881.494162] do_exit+0x989/0x1b10 [ 881.497585] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 881.502759] ? mm_update_next_owner+0x930/0x930 [ 881.507413] ? perf_trace_run_bpf_submit+0x1a7/0x290 [ 881.512489] ? perf_trace_run_bpf_submit+0x1a7/0x290 [ 881.517558] ? perf_trace_run_bpf_submit+0x1ae/0x290 [ 881.522631] ? perf_tp_event+0xae0/0xae0 [ 881.526668] ? memset+0x31/0x40 [ 881.529927] ? perf_trace_lock+0x3e9/0x860 [ 881.534141] ? check_noncircular+0x20/0x20 [ 881.538363] ? get_futex_value_locked+0xc3/0xf0 [ 881.543013] ? find_held_lock+0x35/0x1d0 [ 881.547056] ? get_signal+0x855/0x17e0 [ 881.550911] ? lock_downgrade+0x990/0x990 [ 881.555043] do_group_exit+0x149/0x400 [ 881.558899] ? __lock_is_held+0xb6/0x140 [ 881.562929] ? SyS_exit+0x30/0x30 [ 881.566350] ? _raw_spin_unlock_irq+0x27/0x70 [ 881.570815] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 881.575805] get_signal+0x7e8/0x17e0 [ 881.579526] ? ptrace_notify+0x130/0x130 [ 881.583565] ? do_futex+0x781/0x20a0 [ 881.587249] ? lock_release+0xa40/0xa40 [ 881.591196] ? __lock_is_held+0xb6/0x140 [ 881.595242] do_signal+0x94/0x1ee0 [ 881.598748] ? __fget+0x35c/0x570 [ 881.602180] ? _do_fork+0x1ef/0xfb0 [ 881.605774] ? _do_fork+0x2dc/0xfb0 [ 881.609369] ? setup_sigcontext+0x7d0/0x7d0 [ 881.613660] ? fork_idle+0x2d0/0x2d0 [ 881.617344] ? newque+0x577/0x790 [ 881.620767] ? find_held_lock+0x35/0x1d0 [ 881.624809] ? __fget_light+0x297/0x380 [ 881.628753] ? fget_raw+0x20/0x20 [ 881.632179] ? exit_to_usermode_loop+0x98/0x300 [ 881.636825] exit_to_usermode_loop+0x224/0x300 [ 881.641382] ? trace_event_raw_event_sys_exit+0x260/0x260 [ 881.646902] do_syscall_64+0x5d4/0x800 [ 881.650766] ? syscall_return_slowpath+0x450/0x450 [ 881.655670] ? do_futex+0x20a0/0x20a0 [ 881.659438] ? entry_SYSCALL_64_fastpath+0x5/0xbe [ 881.664255] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 881.669065] ? sys_vfork+0x30/0x30 [ 881.672577] entry_SYSCALL64_slow_path+0x25/0x25 [ 881.677299] RIP: 0033:0x4512e9 [ 881.680456] RSP: 002b:00007fc99d3a5c08 EFLAGS: 00000216 ORIG_RAX: 0000000000000038 [ 881.688130] RAX: fffffffffffffdff RBX: 0000000000718000 RCX: 00000000004512e9 [ 881.695367] RDX: 0000000020507ffc RSI: 00000000208a8f43 RDI: 0000000000800000 [ 881.702602] RBP: 00000000000003b0 R08: 0000000020a8a000 R09: 0000000000000000 [ 881.709839] R10: 0000000020117ffc R11: 0000000000000216 R12: 00000000004b65e0 [ 881.717075] R13: 00000000ffffffff R14: 0000000000800000 R15: 00000000208a8f43 [ 881.724792] Dumping ftrace buffer: [ 881.728302] (ftrace buffer empty) [ 881.731977] Kernel Offset: disabled [ 881.735572] Rebooting in 86400 seconds..