[....] Starting enhanced syslogd: rsyslogd[ 13.674846] audit: type=1400 audit(1516147916.659:4): avc: denied { syslog } for pid=3174 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 mcstransd: [....] Starting periodic command scheduler: cron[?25l[?1c7[ ok 8[?25h[?0c. [....] 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 Warning: Permanently added '10.128.0.4' (ECDSA) to the list of known hosts. executing program syzkaller login: [ 25.142192] ================================================================== [ 25.149595] BUG: KASAN: use-after-free in __lock_acquire+0x2eff/0x3640 [ 25.156236] Read of size 8 at addr ffff8801c90ad9b8 by task syzkaller107901/3330 [ 25.163736] [ 25.165337] CPU: 0 PID: 3330 Comm: syzkaller107901 Not tainted 4.9.76-g8dec074 #23 [ 25.173012] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 25.182336] ffff8801c8cef870 ffffffff81d93169 ffffea0007242b00 ffff8801c90ad9b8 [ 25.190384] 0000000000000000 ffff8801c90ad9b8 ffff8801c90ad9b8 ffff8801c8cef8a8 [ 25.198329] ffffffff8153cb43 ffff8801c90ad9b8 0000000000000008 0000000000000000 [ 25.206269] Call Trace: [ 25.208828] [] dump_stack+0xc1/0x128 [ 25.214336] [] print_address_description+0x73/0x280 [ 25.220973] [] kasan_report+0x275/0x360 [ 25.226566] [] ? __lock_acquire+0x2eff/0x3640 [ 25.232680] [] __asan_report_load8_noabort+0x14/0x20 [ 25.239404] [] __lock_acquire+0x2eff/0x3640 [ 25.245345] [] ? __lock_acquire+0x629/0x3640 [ 25.251373] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 25.258359] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 25.265340] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 25.272319] [] ? mark_held_locks+0xaf/0x100 [ 25.278261] [] ? mutex_lock_nested+0x5e3/0x870 [ 25.284461] [] lock_acquire+0x12e/0x410 [ 25.290050] [] ? remove_wait_queue+0x14/0x40 [ 25.296085] [] _raw_spin_lock_irqsave+0x4e/0x70 [ 25.302373] [] ? remove_wait_queue+0x14/0x40 [ 25.308400] [] remove_wait_queue+0x14/0x40 [ 25.314254] [] ep_unregister_pollwait.isra.6+0xaf/0x240 [ 25.321238] [] ? ep_unregister_pollwait.isra.6+0x12a/0x240 [ 25.328486] [] ? ep_free+0x1b0/0x1b0 [ 25.333820] [] ep_free+0x96/0x1b0 [ 25.338891] [] ? ep_free+0x1b0/0x1b0 [ 25.344231] [] ep_eventpoll_release+0x44/0x60 [ 25.350360] [] __fput+0x28c/0x6e0 [ 25.355456] [] ____fput+0x15/0x20 [ 25.360614] [] task_work_run+0x115/0x190 [ 25.366291] [] do_exit+0x7e7/0x2a40 [ 25.371544] [] ? __pmd_alloc+0x410/0x410 [ 25.377221] [] ? release_task+0x1240/0x1240 [ 25.383159] [] ? __do_page_fault+0x5ec/0xd40 [ 25.389185] [] ? up_read+0x1a/0x40 [ 25.394341] [] ? __do_page_fault+0x3bd/0xd40 [ 25.400379] [] do_group_exit+0x108/0x320 [ 25.406059] [] ? do_group_exit+0x320/0x320 [ 25.411910] [] SyS_exit_group+0x1d/0x20 [ 25.417507] [] do_fast_syscall_32+0x2f7/0x890 [ 25.423628] [] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 25.430262] [] entry_SYSENTER_compat+0x74/0x83 [ 25.436456] [ 25.438047] Allocated by task 3330: [ 25.441639] save_stack_trace+0x16/0x20 [ 25.445585] save_stack+0x43/0xd0 [ 25.449002] kasan_kmalloc+0xad/0xe0 [ 25.452854] kmem_cache_alloc_trace+0xfb/0x2a0 [ 25.457401] binder_get_thread+0x15d/0x750 [ 25.461599] binder_poll+0x4a/0x210 [ 25.465194] SyS_epoll_ctl+0x11d7/0x2190 [ 25.469228] do_fast_syscall_32+0x2f7/0x890 [ 25.473514] entry_SYSENTER_compat+0x74/0x83 [ 25.477883] [ 25.479476] Freed by task 3330: [ 25.482720] save_stack_trace+0x16/0x20 [ 25.486665] save_stack+0x43/0xd0 [ 25.490086] kasan_slab_free+0x72/0xc0 [ 25.493938] kfree+0x103/0x300 [ 25.497097] binder_thread_dec_tmpref+0x1cc/0x240 [ 25.501906] binder_thread_release+0x27d/0x540 [ 25.506453] binder_ioctl+0x9c0/0x11b0 [ 25.510311] compat_SyS_ioctl+0x15f/0x2050 [ 25.514513] do_fast_syscall_32+0x2f7/0x890 [ 25.518810] entry_SYSENTER_compat+0x74/0x83 [ 25.523185] [ 25.524786] The buggy address belongs to the object at ffff8801c90ad900 [ 25.524786] which belongs to the cache kmalloc-512 of size 512 [ 25.537410] The buggy address is located 184 bytes inside of [ 25.537410] 512-byte region [ffff8801c90ad900, ffff8801c90adb00) [ 25.549259] The buggy address belongs to the page: [ 25.554162] page:ffffea0007242b00 count:1 mapcount:0 mapping: (null) index:0x0 compound_mapcount: 0 [ 25.564315] flags: 0x8000000000004080(slab|head) [ 25.569032] page dumped because: kasan: bad access detected [ 25.574704] [ 25.576296] Memory state around the buggy address: [ 25.581197] ffff8801c90ad880: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 25.588522] ffff8801c90ad900: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 25.595847] >ffff8801c90ad980: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 25.604242] ^ [ 25.609430] ffff8801c90ada00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 25.616761] ffff8801c90ada80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 25.624084] ================================================================== [ 25.631405] Disabling lock debugging due to kernel taint [ 25.636819] Kernel panic - not syncing: panic_on_warn set ... [ 25.636819] [ 25.644153] CPU: 0 PID: 3330 Comm: syzkaller107901 Tainted: G B 4.9.76-g8dec074 #23 [ 25.653050] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 25.662381] ffff8801c8cef7c8 ffffffff81d93169 ffffffff84195c2f ffff8801c8cef8a0 [ 25.670325] 0000000000000000 ffff8801c90ad9b8 ffff8801c90ad9b8 ffff8801c8cef890 [ 25.678266] ffffffff8142e371 0000000041b58ab3 ffffffff84189690 ffffffff8142e1b5 [ 25.686213] Call Trace: [ 25.688772] [] dump_stack+0xc1/0x128 [ 25.694106] [] panic+0x1bc/0x3a8 [ 25.699090] [] ? percpu_up_read_preempt_enable.constprop.53+0xd7/0xd7 [ 25.707289] [] ? add_taint+0x40/0x50 [ 25.712621] [] kasan_end_report+0x50/0x50 [ 25.718383] [] kasan_report+0x167/0x360 [ 25.723985] [] ? __lock_acquire+0x2eff/0x3640 [ 25.730115] [] __asan_report_load8_noabort+0x14/0x20 [ 25.736836] [] __lock_acquire+0x2eff/0x3640 [ 25.742774] [] ? __lock_acquire+0x629/0x3640 [ 25.748801] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 25.755780] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 25.762757] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 25.769743] [] ? mark_held_locks+0xaf/0x100 [ 25.775695] [] ? mutex_lock_nested+0x5e3/0x870 [ 25.781894] [] lock_acquire+0x12e/0x410 [ 25.787483] [] ? remove_wait_queue+0x14/0x40 [ 25.793507] [] _raw_spin_lock_irqsave+0x4e/0x70 [ 25.799790] [] ? remove_wait_queue+0x14/0x40 [ 25.805815] [] remove_wait_queue+0x14/0x40 [ 25.811667] [] ep_unregister_pollwait.isra.6+0xaf/0x240 [ 25.818647] [] ? ep_unregister_pollwait.isra.6+0x12a/0x240 [ 25.825899] [] ? ep_free+0x1b0/0x1b0 [ 25.831240] [] ep_free+0x96/0x1b0 [ 25.836314] [] ? ep_free+0x1b0/0x1b0 [ 25.841651] [] ep_eventpoll_release+0x44/0x60 [ 25.847773] [] __fput+0x28c/0x6e0 [ 25.852853] [] ____fput+0x15/0x20 [ 25.857939] [] task_work_run+0x115/0x190 [ 25.863622] [] do_exit+0x7e7/0x2a40 [ 25.868866] [] ? __pmd_alloc+0x410/0x410 [ 25.874545] [] ? release_task+0x1240/0x1240 [ 25.880482] [] ? __do_page_fault+0x5ec/0xd40 [ 25.886510] [] ? up_read+0x1a/0x40 [ 25.891669] [] ? __do_page_fault+0x3bd/0xd40 [ 25.897698] [] do_group_exit+0x108/0x320 [ 25.903386] [] ? do_group_exit+0x320/0x320 [ 25.909236] [] SyS_exit_group+0x1d/0x20 [ 25.914831] [] do_fast_syscall_32+0x2f7/0x890 [ 25.920951] [] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 25.927597] [] entry_SYSENTER_compat+0x74/0x83 [ 25.933839] Dumping ftrace buffer: [ 25.937350] (ftrace buffer empty) [ 25.941028] Kernel Offset: disabled [ 25.944620] Rebooting in 86400 seconds..