[....] Starting enhanced syslogd: rsyslogd[ 10.241218] audit: type=1400 audit(1514087384.430:4): avc: denied { syslog } for pid=3180 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 'ci-android-49-kasan-gce-7,10.128.0.4' (ECDSA) to the list of known hosts. executing program syzkaller login: [ 28.321153] ================================================================== [ 28.322326] BUG: KASAN: use-after-free in __lock_acquire+0x2eff/0x3640 [ 28.323214] Read of size 8 at addr ffff8801cca625b8 by task syzkaller088689/3338 [ 28.324198] [ 28.324432] CPU: 1 PID: 3338 Comm: syzkaller088689 Not tainted 4.9.71-g2506378 #113 [ 28.325461] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 28.326699] ffff8801c81078e0 ffffffff81d922b9 ffffea0007329880 ffff8801cca625b8 [ 28.327895] 0000000000000000 ffff8801cca625b8 ffff8801cca625b8 ffff8801c8107918 [ 28.329077] ffffffff8153bab3 ffff8801cca625b8 0000000000000008 0000000000000000 [ 28.330226] Call Trace: [ 28.330622] [] dump_stack+0xc1/0x128 [ 28.331356] [] print_address_description+0x73/0x280 [ 28.332233] [] kasan_report+0x275/0x360 [ 28.332980] [] ? __lock_acquire+0x2eff/0x3640 [ 28.333832] [] __asan_report_load8_noabort+0x14/0x20 [ 28.334723] [] __lock_acquire+0x2eff/0x3640 [ 28.335512] [] ? __lock_acquire+0x629/0x3640 [ 28.336310] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 28.337254] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 28.338195] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 28.339127] [] ? mark_held_locks+0xaf/0x100 [ 28.339916] [] ? mutex_lock_nested+0x5e3/0x870 [ 28.340754] [] lock_acquire+0x12e/0x410 [ 28.341495] [] ? remove_wait_queue+0x14/0x40 [ 28.347530] [] _raw_spin_lock_irqsave+0x4e/0x70 [ 28.353817] [] ? remove_wait_queue+0x14/0x40 [ 28.359847] [] remove_wait_queue+0x14/0x40 [ 28.365699] [] ep_unregister_pollwait.isra.6+0xaf/0x240 [ 28.372677] [] ? ep_unregister_pollwait.isra.6+0x12a/0x240 [ 28.379918] [] ? ep_free+0x1b0/0x1b0 [ 28.385257] [] ep_free+0x96/0x1b0 [ 28.390334] [] ? ep_free+0x1b0/0x1b0 [ 28.395665] [] ep_eventpoll_release+0x44/0x60 [ 28.401779] [] __fput+0x28c/0x6e0 [ 28.406848] [] ____fput+0x15/0x20 [ 28.411916] [] task_work_run+0x115/0x190 [ 28.417592] [] do_exit+0x7e7/0x2a40 [ 28.422839] [] ? selinux_file_ioctl+0x355/0x530 [ 28.429134] [] ? release_task+0x1240/0x1240 [ 28.435071] [] ? SyS_epoll_create+0x190/0x190 [ 28.441192] [] ? entry_SYSCALL_64_fastpath+0x5/0xc6 [ 28.447827] [] do_group_exit+0x108/0x320 [ 28.453505] [] SyS_exit_group+0x1d/0x20 [ 28.459095] [] entry_SYSCALL_64_fastpath+0x23/0xc6 [ 28.465638] [ 28.467235] Allocated by task 3338: [ 28.470833] save_stack_trace+0x16/0x20 [ 28.474774] save_stack+0x43/0xd0 [ 28.478197] kasan_kmalloc+0xad/0xe0 [ 28.481888] kmem_cache_alloc_trace+0xfb/0x2a0 [ 28.486440] binder_get_thread+0x15d/0x750 [ 28.490656] binder_poll+0x4a/0x210 [ 28.494261] SyS_epoll_ctl+0x11d7/0x2190 [ 28.498288] entry_SYSCALL_64_fastpath+0x23/0xc6 [ 28.503006] [ 28.504601] Freed by task 3338: [ 28.507847] save_stack_trace+0x16/0x20 [ 28.511787] save_stack+0x43/0xd0 [ 28.515208] kasan_slab_free+0x72/0xc0 [ 28.519064] kfree+0x103/0x300 [ 28.522223] binder_thread_dec_tmpref+0x1cc/0x240 [ 28.527032] binder_thread_release+0x27d/0x540 [ 28.531591] binder_ioctl+0x9c0/0x11b0 [ 28.535443] do_vfs_ioctl+0x1aa/0x1140 [ 28.542165] SyS_ioctl+0x8f/0xc0 [ 28.545496] entry_SYSCALL_64_fastpath+0x23/0xc6 [ 28.550212] [ 28.551807] The buggy address belongs to the object at ffff8801cca62500 [ 28.551807] which belongs to the cache kmalloc-512 of size 512 [ 28.564427] The buggy address is located 184 bytes inside of [ 28.564427] 512-byte region [ffff8801cca62500, ffff8801cca62700) [ 28.576285] The buggy address belongs to the page: [ 28.582318] page:ffffea0007329880 count:1 mapcount:0 mapping: (null) index:0x0 compound_mapcount: 0 [ 28.592479] flags: 0x8000000000004080(slab|head) [ 28.597199] page dumped because: kasan: bad access detected [ 28.602869] [ 28.604461] Memory state around the buggy address: [ 28.609369] ffff8801cca62480: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 28.616691] ffff8801cca62500: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 28.624019] >ffff8801cca62580: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 28.631354] ^ [ 28.636506] ffff8801cca62600: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 28.643829] ffff8801cca62680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 28.651164] ================================================================== [ 28.658486] Disabling lock debugging due to kernel taint [ 28.663909] Kernel panic - not syncing: panic_on_warn set ... [ 28.663909] [ 28.671240] CPU: 1 PID: 3338 Comm: syzkaller088689 Tainted: G B 4.9.71-g2506378 #113 [ 28.680230] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 28.689568] ffff8801c8107838 ffffffff81d922b9 ffffffff84194b3f ffff8801c8107910 [ 28.697529] 0000000000000000 ffff8801cca625b8 ffff8801cca625b8 ffff8801c8107900 [ 28.705484] ffffffff8142d741 0000000041b58ab3 ffffffff84188580 ffffffff8142d585 [ 28.713444] Call Trace: [ 28.716006] [] dump_stack+0xc1/0x128 [ 28.721348] [] panic+0x1bc/0x3a8 [ 28.726333] [] ? percpu_up_read_preempt_enable.constprop.53+0xd7/0xd7 [ 28.734539] [] ? add_taint+0x40/0x50 [ 28.740306] [] kasan_end_report+0x50/0x50 [ 28.746069] [] kasan_report+0x167/0x360 [ 28.751660] [] ? __lock_acquire+0x2eff/0x3640 [ 28.757771] [] __asan_report_load8_noabort+0x14/0x20 [ 28.764520] [] __lock_acquire+0x2eff/0x3640 [ 28.770462] [] ? __lock_acquire+0x629/0x3640 [ 28.776485] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 28.783473] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 28.790461] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 28.797452] [] ? mark_held_locks+0xaf/0x100 [ 28.803393] [] ? mutex_lock_nested+0x5e3/0x870 [ 28.809593] [] lock_acquire+0x12e/0x410 [ 28.815180] [] ? remove_wait_queue+0x14/0x40 [ 28.821466] [] _raw_spin_lock_irqsave+0x4e/0x70 [ 28.827758] [] ? remove_wait_queue+0x14/0x40 [ 28.833780] [] remove_wait_queue+0x14/0x40 [ 28.839646] [] ep_unregister_pollwait.isra.6+0xaf/0x240 [ 28.846625] [] ? ep_unregister_pollwait.isra.6+0x12a/0x240 [ 28.853861] [] ? ep_free+0x1b0/0x1b0 [ 28.859278] [] ep_free+0x96/0x1b0 [ 28.864346] [] ? ep_free+0x1b0/0x1b0 [ 28.869690] [] ep_eventpoll_release+0x44/0x60 [ 28.875804] [] __fput+0x28c/0x6e0 [ 28.880883] [] ____fput+0x15/0x20 [ 28.885954] [] task_work_run+0x115/0x190 [ 28.891631] [] do_exit+0x7e7/0x2a40 [ 28.896877] [] ? selinux_file_ioctl+0x355/0x530 [ 28.903163] [] ? release_task+0x1240/0x1240 [ 28.909111] [] ? SyS_epoll_create+0x190/0x190 [ 28.915222] [] ? entry_SYSCALL_64_fastpath+0x5/0xc6 [ 28.921853] [] do_group_exit+0x108/0x320 [ 28.927532] [] SyS_exit_group+0x1d/0x20 [ 28.933799] [] entry_SYSCALL_64_fastpath+0x23/0xc6 [ 28.940402] Dumping ftrace buffer: [ 28.943927] (ftrace buffer empty) [ 28.947603] Kernel Offset: disabled [ 28.951198] Rebooting in 86400 seconds..