[....] Starting enhanced syslogd: rsyslogd[ 13.910495] audit: type=1400 audit(1515899502.791:4): avc: denied { syslog } for pid=3178 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.15.215' (ECDSA) to the list of known hosts. executing program syzkaller login: [ 27.192874] ================================================================== [ 27.200257] BUG: KASAN: use-after-free in __lock_acquire+0x2eff/0x3640 [ 27.206892] Read of size 8 at addr ffff8801ce10afb8 by task syzkaller426572/3334 [ 27.214386] [ 27.215981] CPU: 0 PID: 3334 Comm: syzkaller426572 Not tainted 4.9.76-g8e170a5 #11 [ 27.223671] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 27.232995] ffff8801cf3af8e0 ffffffff81d93149 ffffea0007384280 ffff8801ce10afb8 [ 27.240945] 0000000000000000 ffff8801ce10afb8 ffff8801ce10afb8 ffff8801cf3af918 [ 27.248903] ffffffff8153cb43 ffff8801ce10afb8 0000000000000008 0000000000000000 [ 27.256855] Call Trace: [ 27.259414] [] dump_stack+0xc1/0x128 [ 27.264750] [] print_address_description+0x73/0x280 [ 27.271388] [] kasan_report+0x275/0x360 [ 27.276986] [] ? __lock_acquire+0x2eff/0x3640 [ 27.283097] [] __asan_report_load8_noabort+0x14/0x20 [ 27.289818] [] __lock_acquire+0x2eff/0x3640 [ 27.295772] [] ? __lock_acquire+0x629/0x3640 [ 27.301797] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 27.308776] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 27.315762] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 27.322741] [] ? mark_held_locks+0xaf/0x100 [ 27.328680] [] ? mutex_lock_nested+0x5e3/0x870 [ 27.334874] [] lock_acquire+0x12e/0x410 [ 27.340466] [] ? remove_wait_queue+0x14/0x40 [ 27.346506] [] _raw_spin_lock_irqsave+0x4e/0x70 [ 27.352803] [] ? remove_wait_queue+0x14/0x40 [ 27.358856] [] remove_wait_queue+0x14/0x40 [ 27.364711] [] ep_unregister_pollwait.isra.6+0xaf/0x240 [ 27.371706] [] ? ep_unregister_pollwait.isra.6+0x12a/0x240 [ 27.378948] [] ? ep_free+0x1b0/0x1b0 [ 27.384276] [] ep_free+0x96/0x1b0 [ 27.389343] [] ? ep_free+0x1b0/0x1b0 [ 27.394669] [] ep_eventpoll_release+0x44/0x60 [ 27.400781] [] __fput+0x28c/0x6e0 [ 27.405849] [] ____fput+0x15/0x20 [ 27.410919] [] task_work_run+0x115/0x190 [ 27.416614] [] do_exit+0x7e7/0x2a40 [ 27.421868] [] ? selinux_file_ioctl+0x355/0x530 [ 27.428153] [] ? release_task+0x1240/0x1240 [ 27.434090] [] ? SyS_epoll_create+0x190/0x190 [ 27.440201] [] ? entry_SYSCALL_64_fastpath+0x5/0xe2 [ 27.446832] [] do_group_exit+0x108/0x320 [ 27.452507] [] SyS_exit_group+0x1d/0x20 [ 27.458096] [] entry_SYSCALL_64_fastpath+0x23/0xe2 [ 27.464650] [ 27.466242] Allocated by task 3334: [ 27.469835] save_stack_trace+0x16/0x20 [ 27.473779] save_stack+0x43/0xd0 [ 27.477195] kasan_kmalloc+0xad/0xe0 [ 27.480873] kmem_cache_alloc_trace+0xfb/0x2a0 [ 27.485426] binder_get_thread+0x15d/0x750 [ 27.489626] binder_poll+0x4a/0x210 [ 27.493221] SyS_epoll_ctl+0x11d7/0x2190 [ 27.497247] entry_SYSCALL_64_fastpath+0x23/0xe2 [ 27.501964] [ 27.503561] Freed by task 3334: [ 27.506811] save_stack_trace+0x16/0x20 [ 27.510749] save_stack+0x43/0xd0 [ 27.514167] kasan_slab_free+0x72/0xc0 [ 27.518018] kfree+0x103/0x300 [ 27.521182] binder_thread_dec_tmpref+0x1cc/0x240 [ 27.525993] binder_thread_release+0x27d/0x540 [ 27.530538] binder_ioctl+0x9c0/0x11b0 [ 27.534392] do_vfs_ioctl+0x1aa/0x1140 [ 27.538243] SyS_ioctl+0x8f/0xc0 [ 27.541577] entry_SYSCALL_64_fastpath+0x23/0xe2 [ 27.546294] [ 27.547887] The buggy address belongs to the object at ffff8801ce10af00 [ 27.547887] which belongs to the cache kmalloc-512 of size 512 [ 27.560516] The buggy address is located 184 bytes inside of [ 27.560516] 512-byte region [ffff8801ce10af00, ffff8801ce10b100) [ 27.572361] The buggy address belongs to the page: [ 27.577257] page:ffffea0007384280 count:1 mapcount:0 mapping: (null) index:0x0 compound_mapcount: 0 [ 27.587435] flags: 0x8000000000004080(slab|head) [ 27.592153] page dumped because: kasan: bad access detected [ 27.597835] [ 27.599430] Memory state around the buggy address: [ 27.604322] ffff8801ce10ae80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 27.611646] ffff8801ce10af00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 27.618979] >ffff8801ce10af80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 27.626304] ^ [ 27.631458] ffff8801ce10b000: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 27.638781] ffff8801ce10b080: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 27.646105] ================================================================== [ 27.653429] Disabling lock debugging due to kernel taint [ 27.658843] Kernel panic - not syncing: panic_on_warn set ... [ 27.658843] [ 27.666171] CPU: 0 PID: 3334 Comm: syzkaller426572 Tainted: G B 4.9.76-g8e170a5 #11 [ 27.675058] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 27.684380] ffff8801cf3af838 ffffffff81d93149 ffffffff84195c17 ffff8801cf3af910 [ 27.692338] 0000000000000000 ffff8801ce10afb8 ffff8801ce10afb8 ffff8801cf3af900 [ 27.700288] ffffffff8142e371 0000000041b58ab3 ffffffff84189678 ffffffff8142e1b5 [ 27.708261] Call Trace: [ 27.710823] [] dump_stack+0xc1/0x128 [ 27.716157] [] panic+0x1bc/0x3a8 [ 27.721140] [] ? percpu_up_read_preempt_enable.constprop.53+0xd7/0xd7 [ 27.729335] [] ? add_taint+0x40/0x50 [ 27.734666] [] kasan_end_report+0x50/0x50 [ 27.740431] [] kasan_report+0x167/0x360 [ 27.746022] [] ? __lock_acquire+0x2eff/0x3640 [ 27.752140] [] __asan_report_load8_noabort+0x14/0x20 [ 27.758947] [] __lock_acquire+0x2eff/0x3640 [ 27.764884] [] ? __lock_acquire+0x629/0x3640 [ 27.770911] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 27.777894] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 27.784876] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 27.791858] [] ? mark_held_locks+0xaf/0x100 [ 27.797797] [] ? mutex_lock_nested+0x5e3/0x870 [ 27.803995] [] lock_acquire+0x12e/0x410 [ 27.809585] [] ? remove_wait_queue+0x14/0x40 [ 27.815610] [] _raw_spin_lock_irqsave+0x4e/0x70 [ 27.821902] [] ? remove_wait_queue+0x14/0x40 [ 27.827945] [] remove_wait_queue+0x14/0x40 [ 27.833797] [] ep_unregister_pollwait.isra.6+0xaf/0x240 [ 27.840950] [] ? ep_unregister_pollwait.isra.6+0x12a/0x240 [ 27.848191] [] ? ep_free+0x1b0/0x1b0 [ 27.853520] [] ep_free+0x96/0x1b0 [ 27.858594] [] ? ep_free+0x1b0/0x1b0 [ 27.863920] [] ep_eventpoll_release+0x44/0x60 [ 27.870030] [] __fput+0x28c/0x6e0 [ 27.875107] [] ____fput+0x15/0x20 [ 27.880183] [] task_work_run+0x115/0x190 [ 27.885864] [] do_exit+0x7e7/0x2a40 [ 27.891111] [] ? selinux_file_ioctl+0x355/0x530 [ 27.897396] [] ? release_task+0x1240/0x1240 [ 27.903334] [] ? SyS_epoll_create+0x190/0x190 [ 27.909455] [] ? entry_SYSCALL_64_fastpath+0x5/0xe2 [ 27.916094] [] do_group_exit+0x108/0x320 [ 27.921771] [] SyS_exit_group+0x1d/0x20 [ 27.927361] [] entry_SYSCALL_64_fastpath+0x23/0xe2 [ 27.933960] Dumping ftrace buffer: [ 27.937464] (ftrace buffer empty) [ 27.941149] Kernel Offset: disabled [ 27.944827] Rebooting in 86400 seconds..