[....] Starting enhanced syslogd: rsyslogd[ 13.298749] audit: type=1400 audit(1515500418.616:5): avc: denied { syslog } for pid=3342 comm="rsyslogd" capability=34 scontext=system_u:system_r:kernel_t:s0 tcontext=system_u:system_r:kernel_t:s0 tclass=capability2 permissive=1 [?25l[?1c7[ ok 8[?25h[?0c. [....] Starting periodic command scheduler: cron[?25l[?1c7[ ok 8[?25h[?0c. Starting mcstransd: [....] Starting file context maintaining daemon: restorecond[?25l[?1c7[ ok 8[?25h[?0c. [....] Starting OpenBSD Secure Shell server: sshd[?25l[?1c7[ ok 8[?25h[?0c. Debian GNU/Linux 7 syzkaller ttyS0 syzkaller login: [ 18.936721] audit: type=1400 audit(1515500424.254:6): avc: denied { map } for pid=3481 comm="bash" path="/bin/bash" dev="sda1" ino=1457 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=system_u:object_r:file_t:s0 tclass=file permissive=1 Warning: Permanently added '10.128.0.60' (ECDSA) to the list of known hosts. executing program [ 28.342233] audit: type=1400 audit(1515500433.660:7): avc: denied { map } for pid=3497 comm="syzkaller261749" path="/root/syzkaller261749947" dev="sda1" ino=16481 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:user_home_t:s0 tclass=file permissive=1 [ 28.347026] ================================================================== [ 28.347041] BUG: KASAN: use-after-free in __lock_acquire+0x3d4d/0x3e00 [ 28.347047] Read of size 8 at addr ffff8801cbd74b30 by task syzkaller261749/3497 [ 28.347048] [ 28.347055] CPU: 1 PID: 3497 Comm: syzkaller261749 Not tainted 4.15.0-rc7+ #163 [ 28.347058] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 28.347061] Call Trace: [ 28.347070] dump_stack+0x194/0x257 [ 28.347077] ? arch_local_irq_restore+0x53/0x53 [ 28.347085] ? show_regs_print_info+0x18/0x18 [ 28.347091] ? print_irqtrace_events+0x270/0x270 [ 28.347097] ? __lock_acquire+0x664/0x3e00 [ 28.347104] ? __lock_acquire+0x3d4d/0x3e00 [ 28.347112] print_address_description+0x73/0x250 [ 28.347118] ? __lock_acquire+0x3d4d/0x3e00 [ 28.347124] kasan_report+0x25b/0x340 [ 28.347133] __asan_report_load8_noabort+0x14/0x20 [ 28.347138] __lock_acquire+0x3d4d/0x3e00 [ 28.347144] ? __lock_acquire+0x664/0x3e00 [ 28.347150] ? lock_downgrade+0x980/0x980 [ 28.347155] ? lock_downgrade+0x980/0x980 [ 28.347162] ? print_irqtrace_events+0x270/0x270 [ 28.347168] ? remove_wait_queue+0x81/0x350 [ 28.347177] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 28.347184] ? __lock_acquire+0x664/0x3e00 [ 28.347191] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 28.347203] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 28.347210] ? lock_acquire+0x256/0x580 [ 28.347219] ? lock_release+0xa40/0xa40 [ 28.347226] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 28.347231] ? print_irqtrace_events+0x270/0x270 [ 28.347237] ? print_irqtrace_events+0x270/0x270 [ 28.347244] ? rcu_note_context_switch+0x710/0x710 [ 28.347252] ? __might_sleep+0x95/0x190 [ 28.347258] ? ep_free+0xf4/0x320 [ 28.347265] ? __mutex_lock+0x16f/0x1a80 [ 28.347270] ? ep_free+0xf4/0x320 [ 28.347277] ? print_irqtrace_events+0x270/0x270 [ 28.347282] ? ep_free+0xf4/0x320 [ 28.347290] lock_acquire+0x1d5/0x580 [ 28.347296] ? lock_acquire+0x1d5/0x580 [ 28.347302] ? remove_wait_queue+0x81/0x350 [ 28.347310] ? lock_release+0xa40/0xa40 [ 28.347319] ? lock_acquire+0x1d5/0x580 [ 28.347324] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 28.347329] ? lock_acquire+0x1d5/0x580 [ 28.347336] ? ep_unregister_pollwait.isra.7+0x323/0x590 [ 28.347345] _raw_spin_lock_irqsave+0x96/0xc0 [ 28.347350] ? remove_wait_queue+0x81/0x350 [ 28.347357] remove_wait_queue+0x81/0x350 [ 28.347364] ? depot_save_stack+0x3b5/0x490 [ 28.347371] ? add_wait_queue+0x290/0x290 [ 28.347376] ? rcutorture_record_progress+0x10/0x10 [ 28.347382] ? lock_release+0xa40/0xa40 [ 28.347391] ep_unregister_pollwait.isra.7+0x18c/0x590 [ 28.347399] ? __kernel_text_address+0xd/0x40 [ 28.347407] ? clear_tfile_check_list+0x370/0x370 [ 28.347414] ? check_noncircular+0x20/0x20 [ 28.347423] ? locks_remove_file+0x3fa/0x5a0 [ 28.347432] ep_free+0x13f/0x320 [ 28.347438] ? ep_remove+0x800/0x800 [ 28.347444] ? fsnotify_first_mark+0x2b0/0x2b0 [ 28.347452] ? ep_free+0x320/0x320 [ 28.347458] ep_eventpoll_release+0x44/0x60 [ 28.347465] __fput+0x327/0x7e0 [ 28.347473] ? fput+0x140/0x140 [ 28.347480] ? _raw_spin_unlock_irq+0x27/0x70 [ 28.347488] ____fput+0x15/0x20 [ 28.347494] task_work_run+0x199/0x270 [ 28.347502] ? task_work_cancel+0x210/0x210 [ 28.347508] ? _raw_spin_unlock+0x22/0x30 [ 28.347514] ? switch_task_namespaces+0x87/0xc0 [ 28.347523] do_exit+0x9bb/0x1ad0 [ 28.347530] ? __handle_mm_fault+0x2330/0x3ce0 [ 28.347537] ? mm_update_next_owner+0x930/0x930 [ 28.347548] ? do_raw_spin_trylock+0x190/0x190 [ 28.347555] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 28.347561] ? check_noncircular+0x20/0x20 [ 28.347568] ? _raw_spin_unlock+0x22/0x30 [ 28.347574] ? __handle_mm_fault+0x80e/0x3ce0 [ 28.347582] ? check_noncircular+0x20/0x20 [ 28.347586] ? __pmd_alloc+0x4e0/0x4e0 [ 28.347596] ? lock_downgrade+0x980/0x980 [ 28.347604] ? find_held_lock+0x35/0x1d0 [ 28.347612] ? handle_mm_fault+0x248/0x8d0 [ 28.347620] ? find_held_lock+0x35/0x1d0 [ 28.347630] ? __do_page_fault+0x5f7/0xc90 [ 28.347636] ? lock_downgrade+0x980/0x980 [ 28.347645] ? handle_mm_fault+0x410/0x8d0 [ 28.347649] ? down_read_trylock+0xdb/0x170 [ 28.347655] ? __do_page_fault+0x32d/0xc90 [ 28.347661] ? __handle_mm_fault+0x3ce0/0x3ce0 [ 28.347667] ? vmacache_find+0x5f/0x280 [ 28.347676] do_group_exit+0x149/0x400 [ 28.347682] ? __do_page_fault+0x3d6/0xc90 [ 28.347688] ? SyS_exit+0x30/0x30 [ 28.347696] ? do_fast_syscall_32+0x156/0xf9d [ 28.347702] ? do_group_exit+0x400/0x400 [ 28.347708] SyS_exit_group+0x1d/0x20 [ 28.347714] do_fast_syscall_32+0x3ee/0xf9d [ 28.347723] ? do_int80_syscall_32+0x9d0/0x9d0 [ 28.347729] ? kasan_check_read+0x11/0x20 [ 28.347736] ? syscall_return_slowpath+0x550/0x550 [ 28.347743] ? SyS_rt_sigaction+0x94/0x1b0 [ 28.347749] ? SyS_sigprocmask+0x4b0/0x4b0 [ 28.347755] ? SyS_read+0x184/0x220 [ 28.347761] ? retint_user+0x18/0x18 [ 28.347769] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 28.347777] entry_SYSENTER_compat+0x54/0x63 [ 28.347782] RIP: 0023:0xf7f2ec79 [ 28.347785] RSP: 002b:00000000ff8436bc EFLAGS: 00000296 ORIG_RAX: 00000000000000fc [ 28.347791] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00000000080f0298 [ 28.347795] RDX: 0000000000000000 RSI: 00000000080d9ad8 RDI: 00000000080f02a0 [ 28.347798] RBP: 0000000000000001 R08: 0000000000000000 R09: 0000000000000000 [ 28.347801] R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000 [ 28.347804] R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 [ 28.347813] [ 28.347816] Allocated by task 3497: [ 28.347821] save_stack+0x43/0xd0 [ 28.347825] kasan_kmalloc+0xad/0xe0 [ 28.347830] kmem_cache_alloc_trace+0x136/0x750 [ 28.347836] binder_get_thread+0x1cf/0x870 [ 28.347840] binder_poll+0x8c/0x390 [ 28.347846] ep_item_poll.isra.10+0xec/0x320 [ 28.347850] ep_insert+0x6a3/0x1b10 [ 28.347855] SyS_epoll_ctl+0x12e4/0x1ab0 [ 28.347860] do_fast_syscall_32+0x3ee/0xf9d [ 28.347864] entry_SYSENTER_compat+0x54/0x63 [ 28.347865] [ 28.347867] Freed by task 3497: [ 28.347872] save_stack+0x43/0xd0 [ 28.347877] kasan_slab_free+0x71/0xc0 [ 28.347881] kfree+0xd6/0x260 [ 28.347886] binder_thread_dec_tmpref+0x27f/0x310 [ 28.347890] binder_thread_release+0x27d/0x540 [ 28.347895] binder_ioctl+0xc02/0x1417 [ 28.347900] compat_SyS_ioctl+0x151/0x2a30 [ 28.347905] do_fast_syscall_32+0x3ee/0xf9d [ 28.347909] entry_SYSENTER_compat+0x54/0x63 [ 28.347910] [ 28.347914] The buggy address belongs to the object at ffff8801cbd74a80 [ 28.347914] which belongs to the cache kmalloc-512 of size 512 [ 28.347919] The buggy address is located 176 bytes inside of [ 28.347919] 512-byte region [ffff8801cbd74a80, ffff8801cbd74c80) [ 28.347921] The buggy address belongs to the page: [ 28.347926] page:ffffea00072f5d00 count:1 mapcount:0 mapping:ffff8801cbd74080 index:0x0 [ 28.347931] flags: 0x2fffc0000000100(slab) [ 28.347940] raw: 02fffc0000000100 ffff8801cbd74080 0000000000000000 0000000100000006 [ 28.347947] raw: ffffea0007254520 ffffea00072c1fe0 ffff8801dac00940 0000000000000000 [ 28.347950] page dumped because: kasan: bad access detected [ 28.347951] [ 28.347952] Memory state around the buggy address: [ 28.347957] ffff8801cbd74a00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 28.347961] ffff8801cbd74a80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 28.347966] >ffff8801cbd74b00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 28.347968] ^ [ 28.347972] ffff8801cbd74b80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 28.347977] ffff8801cbd74c00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 28.347978] ================================================================== [ 28.347980] Disabling lock debugging due to kernel taint [ 28.347983] Kernel panic - not syncing: panic_on_warn set ... [ 28.347983] [ 28.347989] CPU: 1 PID: 3497 Comm: syzkaller261749 Tainted: G B 4.15.0-rc7+ #163 [ 28.347992] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 28.347994] Call Trace: [ 28.348000] dump_stack+0x194/0x257 [ 28.348010] ? arch_local_irq_restore+0x53/0x53 [ 28.348015] ? kasan_end_report+0x32/0x50 [ 28.348021] ? lock_downgrade+0x980/0x980 [ 28.348027] ? vsnprintf+0x1ed/0x1900 [ 28.348034] ? __lock_acquire+0x3cb0/0x3e00 [ 28.348039] panic+0x1e4/0x41c [ 28.348045] ? refcount_error_report+0x214/0x214 [ 28.348052] ? add_taint+0x40/0x50 [ 28.348057] ? add_taint+0x1c/0x50 [ 28.348064] ? __lock_acquire+0x3d4d/0x3e00 [ 28.348070] kasan_end_report+0x50/0x50 [ 28.348075] kasan_report+0x144/0x340 [ 28.348083] __asan_report_load8_noabort+0x14/0x20 [ 28.348089] __lock_acquire+0x3d4d/0x3e00 [ 28.348094] ? __lock_acquire+0x664/0x3e00 [ 28.348100] ? lock_downgrade+0x980/0x980 [ 28.348105] ? lock_downgrade+0x980/0x980 [ 28.348112] ? print_irqtrace_events+0x270/0x270 [ 28.348117] ? remove_wait_queue+0x81/0x350 [ 28.348126] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 28.348132] ? __lock_acquire+0x664/0x3e00 [ 28.348139] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 28.348150] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 28.348158] ? lock_acquire+0x256/0x580 [ 28.348166] ? lock_release+0xa40/0xa40 [ 28.348172] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 28.348178] ? print_irqtrace_events+0x270/0x270 [ 28.348184] ? print_irqtrace_events+0x270/0x270 [ 28.348190] ? rcu_note_context_switch+0x710/0x710 [ 28.348197] ? __might_sleep+0x95/0x190 [ 28.348203] ? ep_free+0xf4/0x320 [ 28.348208] ? __mutex_lock+0x16f/0x1a80 [ 28.348213] ? ep_free+0xf4/0x320 [ 28.348220] ? print_irqtrace_events+0x270/0x270 [ 28.348225] ? ep_free+0xf4/0x320 [ 28.348233] lock_acquire+0x1d5/0x580 [ 28.348239] ? lock_acquire+0x1d5/0x580 [ 28.348245] ? remove_wait_queue+0x81/0x350 [ 28.348253] ? lock_release+0xa40/0xa40 [ 28.348261] ? lock_acquire+0x1d5/0x580 [ 28.348267] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 28.348272] ? lock_acquire+0x1d5/0x580 [ 28.348278] ? ep_unregister_pollwait.isra.7+0x323/0x590 [ 28.348286] _raw_spin_lock_irqsave+0x96/0xc0 [ 28.348291] ? remove_wait_queue+0x81/0x350 [ 28.348298] remove_wait_queue+0x81/0x350 [ 28.348303] ? depot_save_stack+0x3b5/0x490 [ 28.348310] ? add_wait_queue+0x290/0x290 [ 28.348316] ? rcutorture_record_progress+0x10/0x10 [ 28.348322] ? lock_release+0xa40/0xa40 [ 28.348331] ep_unregister_pollwait.isra.7+0x18c/0x590 [ 28.348337] ? __kernel_text_address+0xd/0x40 [ 28.348345] ? clear_tfile_check_list+0x370/0x370 [ 28.348352] ? check_noncircular+0x20/0x20 [ 28.348360] ? locks_remove_file+0x3fa/0x5a0 [ 28.348369] ep_free+0x13f/0x320 [ 28.348375] ? ep_remove+0x800/0x800 [ 28.348381] ? fsnotify_first_mark+0x2b0/0x2b0 [ 28.348388] ? ep_free+0x320/0x320 [ 28.348394] ep_eventpoll_release+0x44/0x60 [ 28.348400] __fput+0x327/0x7e0 [ 28.348409] ? fput+0x140/0x140 [ 28.348416] ? _raw_spin_unlock_irq+0x27/0x70 [ 28.348424] ____fput+0x15/0x20 [ 28.348430] task_work_run+0x199/0x270 [ 28.348438] ? task_work_cancel+0x210/0x210 [ 28.348444] ? _raw_spin_unlock+0x22/0x30 [ 28.348450] ? switch_task_namespaces+0x87/0xc0 [ 28.348457] do_exit+0x9bb/0x1ad0 [ 28.348463] ? __handle_mm_fault+0x2330/0x3ce0 [ 28.348470] ? mm_update_next_owner+0x930/0x930 [ 28.348479] ? do_raw_spin_trylock+0x190/0x190 [ 28.348487] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 28.348492] ? check_noncircular+0x20/0x20 [ 28.348499] ? _raw_spin_unlock+0x22/0x30 [ 28.348505] ? __handle_mm_fault+0x80e/0x3ce0 [ 28.348513] ? check_noncircular+0x20/0x20 [ 28.348518] ? __pmd_alloc+0x4e0/0x4e0 [ 28.348523] ? lock_downgrade+0x980/0x980 [ 28.348531] ? find_held_lock+0x35/0x1d0 [ 28.348539] ? handle_mm_fault+0x248/0x8d0 [ 28.348545] ? find_held_lock+0x35/0x1d0 [ 28.348554] ? __do_page_fault+0x5f7/0xc90 [ 28.348561] ? lock_downgrade+0x980/0x980 [ 28.348569] ? handle_mm_fault+0x410/0x8d0 [ 28.348574] ? down_read_trylock+0xdb/0x170 [ 28.348580] ? __do_page_fault+0x32d/0xc90 [ 28.348586] ? __handle_mm_fault+0x3ce0/0x3ce0 [ 28.348596] ? vmacache_find+0x5f/0x280 [ 28.348604] do_group_exit+0x149/0x400 [ 28.348610] ? __do_page_fault+0x3d6/0xc90 [ 28.348616] ? SyS_exit+0x30/0x30 [ 28.348623] ? do_fast_syscall_32+0x156/0xf9d [ 28.348629] ? do_group_exit+0x400/0x400 [ 28.348636] SyS_exit_group+0x1d/0x20 [ 28.348642] do_fast_syscall_32+0x3ee/0xf9d [ 28.348650] ? do_int80_syscall_32+0x9d0/0x9d0 [ 28.348656] ? kasan_check_read+0x11/0x20 [ 28.348663] ? syscall_return_slowpath+0x550/0x550 [ 28.348670] ? SyS_rt_sigaction+0x94/0x1b0 [ 28.348676] ? SyS_sigprocmask+0x4b0/0x4b0 [ 28.348681] ? SyS_read+0x184/0x220 [ 28.348687] ? retint_user+0x18/0x18 [ 28.348695] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 28.348703] entry_SYSENTER_compat+0x54/0x63 [ 28.348706] RIP: 0023:0xf7f2ec79 [ 28.348709] RSP: 002b:00000000ff8436bc EFLAGS: 00000296 ORIG_RAX: 00000000000000fc [ 28.348715] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00000000080f0298 [ 28.348718] RDX: 0000000000000000 RSI: 00000000080d9ad8 RDI: 00000000080f02a0 [ 28.348721] RBP: 0000000000000001 R08: 0000000000000000 R09: 0000000000000000 [ 28.348724] R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000 [ 28.348727] R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 [ 28.368567] Dumping ftrace buffer: [ 28.368572] (ftrace buffer empty) [ 28.368575] Kernel Offset: disabled [ 29.636384] Rebooting in 86400 seconds..