[....] Starting enhanced syslogd: rsyslogd[ 12.614913] audit: type=1400 audit(1516138307.980: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 periodic command scheduler: cron[?25l[?1c7[ ok 8[?25h[?0c. Starting mcstransd: [....] Starting OpenBSD Secure Shell server: sshd[?25l[?1c7[ ok 8[?25h[?0c. [....] Starting file context maintaining daemon: restorecond[?25l[?1c7[ ok 8[?25h[?0c. Debian GNU/Linux 7 syzkaller ttyS0 Warning: Permanently added '10.128.0.13' (ECDSA) to the list of known hosts. executing program syzkaller login: [ 21.831243] ================================================================== [ 21.838629] BUG: KASAN: use-after-free in __lock_acquire+0x2eff/0x3640 [ 21.845264] Read of size 8 at addr ffff8801c8b10838 by task syzkaller799073/3323 [ 21.852759] [ 21.854363] CPU: 0 PID: 3323 Comm: syzkaller799073 Not tainted 4.9.76-g8dec074 #23 [ 21.862034] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 21.871359] ffff8801c9487870 ffffffff81d93169 ffffea000722c400 ffff8801c8b10838 [ 21.879323] 0000000000000000 ffff8801c8b10838 ffff8801c8b10838 ffff8801c94878a8 [ 21.887286] ffffffff8153cb43 ffff8801c8b10838 0000000000000008 0000000000000000 [ 21.895242] Call Trace: [ 21.897797] [] dump_stack+0xc1/0x128 [ 21.903129] [] print_address_description+0x73/0x280 [ 21.909763] [] kasan_report+0x275/0x360 [ 21.915358] [] ? __lock_acquire+0x2eff/0x3640 [ 21.921477] [] __asan_report_load8_noabort+0x14/0x20 [ 21.928198] [] __lock_acquire+0x2eff/0x3640 [ 21.934134] [] ? __lock_acquire+0x629/0x3640 [ 21.940163] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 21.947146] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 21.954127] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 21.961106] [] ? mark_held_locks+0xaf/0x100 [ 21.967043] [] ? mutex_lock_nested+0x5e3/0x870 [ 21.973255] [] lock_acquire+0x12e/0x410 [ 21.978845] [] ? remove_wait_queue+0x14/0x40 [ 21.984868] [] _raw_spin_lock_irqsave+0x4e/0x70 [ 21.991151] [] ? remove_wait_queue+0x14/0x40 [ 21.997180] [] remove_wait_queue+0x14/0x40 [ 22.003035] [] ep_unregister_pollwait.isra.6+0xaf/0x240 [ 22.010014] [] ? ep_unregister_pollwait.isra.6+0x12a/0x240 [ 22.017254] [] ? ep_free+0x1b0/0x1b0 [ 22.022586] [] ep_free+0x96/0x1b0 [ 22.027657] [] ? ep_free+0x1b0/0x1b0 [ 22.032986] [] ep_eventpoll_release+0x44/0x60 [ 22.039098] [] __fput+0x28c/0x6e0 [ 22.044168] [] ____fput+0x15/0x20 [ 22.049237] [] task_work_run+0x115/0x190 [ 22.054916] [] do_exit+0x7e7/0x2a40 [ 22.060162] [] ? __pmd_alloc+0x410/0x410 [ 22.065854] [] ? release_task+0x1240/0x1240 [ 22.071794] [] ? __do_page_fault+0x5ec/0xd40 [ 22.077820] [] ? up_read+0x1a/0x40 [ 22.082975] [] ? __do_page_fault+0x3bd/0xd40 [ 22.088999] [] do_group_exit+0x108/0x320 [ 22.094685] [] ? do_group_exit+0x320/0x320 [ 22.100541] [] SyS_exit_group+0x1d/0x20 [ 22.106133] [] do_fast_syscall_32+0x2f7/0x890 [ 22.112244] [] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 22.118878] [] entry_SYSENTER_compat+0x74/0x83 [ 22.125075] [ 22.126673] Allocated by task 3323: [ 22.130268] save_stack_trace+0x16/0x20 [ 22.134207] save_stack+0x43/0xd0 [ 22.137631] kasan_kmalloc+0xad/0xe0 [ 22.141313] kmem_cache_alloc_trace+0xfb/0x2a0 [ 22.145865] binder_get_thread+0x15d/0x750 [ 22.150067] binder_poll+0x4a/0x210 [ 22.153751] SyS_epoll_ctl+0x11d7/0x2190 [ 22.157778] do_fast_syscall_32+0x2f7/0x890 [ 22.162065] entry_SYSENTER_compat+0x74/0x83 [ 22.166437] [ 22.168030] Freed by task 3323: [ 22.171276] save_stack_trace+0x16/0x20 [ 22.175216] save_stack+0x43/0xd0 [ 22.178637] kasan_slab_free+0x72/0xc0 [ 22.182489] kfree+0x103/0x300 [ 22.185648] binder_thread_dec_tmpref+0x1cc/0x240 [ 22.190455] binder_thread_release+0x27d/0x540 [ 22.195000] binder_ioctl+0x9c0/0x11b0 [ 22.198855] compat_SyS_ioctl+0x15f/0x2050 [ 22.203063] do_fast_syscall_32+0x2f7/0x890 [ 22.207353] entry_SYSENTER_compat+0x74/0x83 [ 22.211726] [ 22.213323] The buggy address belongs to the object at ffff8801c8b10780 [ 22.213323] which belongs to the cache kmalloc-512 of size 512 [ 22.225944] The buggy address is located 184 bytes inside of [ 22.225944] 512-byte region [ffff8801c8b10780, ffff8801c8b10980) [ 22.237781] The buggy address belongs to the page: [ 22.242677] page:ffffea000722c400 count:1 mapcount:0 mapping: (null) index:0x0 compound_mapcount: 0 [ 22.253185] flags: 0x8000000000004080(slab|head) [ 22.257903] page dumped because: kasan: bad access detected [ 22.264015] [ 22.265611] Memory state around the buggy address: [ 22.270507] ffff8801c8b10700: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 22.277832] ffff8801c8b10780: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 22.285169] >ffff8801c8b10800: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 22.292492] ^ [ 22.297645] ffff8801c8b10880: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 22.304970] ffff8801c8b10900: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 22.312291] ================================================================== [ 22.319613] Disabling lock debugging due to kernel taint [ 22.325033] Kernel panic - not syncing: panic_on_warn set ... [ 22.325033] [ 22.332372] CPU: 0 PID: 3323 Comm: syzkaller799073 Tainted: G B 4.9.76-g8dec074 #23 [ 22.341265] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 22.350588] ffff8801c94877c8 ffffffff81d93169 ffffffff84195c2f ffff8801c94878a0 [ 22.358568] 0000000000000000 ffff8801c8b10838 ffff8801c8b10838 ffff8801c9487890 [ 22.366525] ffffffff8142e371 0000000041b58ab3 ffffffff84189690 ffffffff8142e1b5 [ 22.374490] Call Trace: [ 22.377046] [] dump_stack+0xc1/0x128 [ 22.382377] [] panic+0x1bc/0x3a8 [ 22.387361] [] ? percpu_up_read_preempt_enable.constprop.53+0xd7/0xd7 [ 22.395555] [] ? add_taint+0x40/0x50 [ 22.400884] [] kasan_end_report+0x50/0x50 [ 22.406649] [] kasan_report+0x167/0x360 [ 22.412240] [] ? __lock_acquire+0x2eff/0x3640 [ 22.418357] [] __asan_report_load8_noabort+0x14/0x20 [ 22.425076] [] __lock_acquire+0x2eff/0x3640 [ 22.431016] [] ? __lock_acquire+0x629/0x3640 [ 22.437040] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 22.444018] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 22.451000] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 22.457978] [] ? mark_held_locks+0xaf/0x100 [ 22.463921] [] ? mutex_lock_nested+0x5e3/0x870 [ 22.470122] [] lock_acquire+0x12e/0x410 [ 22.475714] [] ? remove_wait_queue+0x14/0x40 [ 22.481742] [] _raw_spin_lock_irqsave+0x4e/0x70 [ 22.488030] [] ? remove_wait_queue+0x14/0x40 [ 22.494053] [] remove_wait_queue+0x14/0x40 [ 22.499905] [] ep_unregister_pollwait.isra.6+0xaf/0x240 [ 22.506888] [] ? ep_unregister_pollwait.isra.6+0x12a/0x240 [ 22.514130] [] ? ep_free+0x1b0/0x1b0 [ 22.519460] [] ep_free+0x96/0x1b0 [ 22.524531] [] ? ep_free+0x1b0/0x1b0 [ 22.529873] [] ep_eventpoll_release+0x44/0x60 [ 22.535989] [] __fput+0x28c/0x6e0 [ 22.541057] [] ____fput+0x15/0x20 [ 22.546125] [] task_work_run+0x115/0x190 [ 22.551804] [] do_exit+0x7e7/0x2a40 [ 22.557055] [] ? __pmd_alloc+0x410/0x410 [ 22.562732] [] ? release_task+0x1240/0x1240 [ 22.568670] [] ? __do_page_fault+0x5ec/0xd40 [ 22.574696] [] ? up_read+0x1a/0x40 [ 22.579851] [] ? __do_page_fault+0x3bd/0xd40 [ 22.585877] [] do_group_exit+0x108/0x320 [ 22.591554] [] ? do_group_exit+0x320/0x320 [ 22.597406] [] SyS_exit_group+0x1d/0x20 [ 22.602996] [] do_fast_syscall_32+0x2f7/0x890 [ 22.609109] [] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 22.615746] [] entry_SYSENTER_compat+0x74/0x83 [ 22.622379] Dumping ftrace buffer: [ 22.625888] (ftrace buffer empty) [ 22.629573] Kernel Offset: disabled [ 22.633169] Rebooting in 86400 seconds..