[....] Starting enhanced syslogd: rsyslogd[ 12.630223] audit: type=1400 audit(1516146508.505:5): avc: denied { syslog } for pid=3504 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: [ 17.097276] audit: type=1400 audit(1516146512.973:6): avc: denied { map } for pid=3642 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.15.242' (ECDSA) to the list of known hosts. executing program [ 23.409213] audit: type=1400 audit(1516146519.284:7): avc: denied { map } for pid=3656 comm="syzkaller895466" path="/root/syzkaller895466272" 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 [ 23.416080] ================================================================== [ 23.416098] BUG: KASAN: use-after-free in __lock_acquire+0x3d4d/0x3e00 [ 23.416104] Read of size 8 at addr ffff8801d9947870 by task syzkaller895466/3656 [ 23.416105] [ 23.416113] CPU: 1 PID: 3656 Comm: syzkaller895466 Not tainted 4.15.0-rc8+ #264 [ 23.416117] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 23.416119] Call Trace: [ 23.416131] dump_stack+0x194/0x257 [ 23.416139] ? arch_local_irq_restore+0x53/0x53 [ 23.416148] ? show_regs_print_info+0x18/0x18 [ 23.416154] ? print_irqtrace_events+0x270/0x270 [ 23.416160] ? __lock_acquire+0x664/0x3e00 [ 23.416167] ? __lock_acquire+0x3d4d/0x3e00 [ 23.416177] print_address_description+0x73/0x250 [ 23.416183] ? __lock_acquire+0x3d4d/0x3e00 [ 23.416189] kasan_report+0x25b/0x340 [ 23.416197] __asan_report_load8_noabort+0x14/0x20 [ 23.416203] __lock_acquire+0x3d4d/0x3e00 [ 23.416209] ? __lock_acquire+0x664/0x3e00 [ 23.416214] ? lock_downgrade+0x980/0x980 [ 23.416219] ? lock_downgrade+0x980/0x980 [ 23.416230] ? remove_wait_queue+0x81/0x350 [ 23.416238] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 23.416245] ? __lock_acquire+0x664/0x3e00 [ 23.416251] ? check_noncircular+0x20/0x20 [ 23.416263] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 23.416270] ? lock_acquire+0x1d5/0x580 [ 23.416276] ? lock_acquire+0x1d5/0x580 [ 23.416284] ? ep_free+0xf4/0x320 [ 23.416293] ? lock_release+0xa40/0xa40 [ 23.416300] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 23.416306] ? print_irqtrace_events+0x270/0x270 [ 23.416316] ? rcu_note_context_switch+0x710/0x710 [ 23.416324] ? __might_sleep+0x95/0x190 [ 23.416330] ? ep_free+0xf4/0x320 [ 23.416337] ? __mutex_lock+0x16f/0x1a80 [ 23.416342] ? ep_free+0xf4/0x320 [ 23.416349] ? print_irqtrace_events+0x270/0x270 [ 23.416354] ? ep_free+0xf4/0x320 [ 23.416362] lock_acquire+0x1d5/0x580 [ 23.416367] ? lock_acquire+0x1d5/0x580 [ 23.416373] ? remove_wait_queue+0x81/0x350 [ 23.416379] ? __lock_acquire+0x664/0x3e00 [ 23.416386] ? lock_release+0xa40/0xa40 [ 23.416395] ? lock_acquire+0x1d5/0x580 [ 23.416401] ? lock_acquire+0x1d5/0x580 [ 23.416407] ? ep_unregister_pollwait.isra.7+0x323/0x590 [ 23.416415] _raw_spin_lock_irqsave+0x96/0xc0 [ 23.416426] ? remove_wait_queue+0x81/0x350 [ 23.416433] remove_wait_queue+0x81/0x350 [ 23.416441] ? add_wait_queue+0x290/0x290 [ 23.416447] ? rcutorture_record_progress+0x10/0x10 [ 23.416457] ep_unregister_pollwait.isra.7+0x18c/0x590 [ 23.416466] ? __kernel_text_address+0xd/0x40 [ 23.416474] ? clear_tfile_check_list+0x370/0x370 [ 23.416482] ? check_noncircular+0x20/0x20 [ 23.416491] ? locks_remove_file+0x3fa/0x5a0 [ 23.416501] ep_free+0x13f/0x320 [ 23.416507] ? ep_remove+0x800/0x800 [ 23.416514] ? fsnotify_first_mark+0x2b0/0x2b0 [ 23.416522] ? ep_free+0x320/0x320 [ 23.416528] ep_eventpoll_release+0x44/0x60 [ 23.416537] __fput+0x327/0x7e0 [ 23.416546] ? fput+0x140/0x140 [ 23.416553] ? _raw_spin_unlock_irq+0x27/0x70 [ 23.416562] ____fput+0x15/0x20 [ 23.416568] task_work_run+0x199/0x270 [ 23.416576] ? task_work_cancel+0x210/0x210 [ 23.416582] ? _raw_spin_unlock+0x22/0x30 [ 23.416589] ? switch_task_namespaces+0x87/0xc0 [ 23.416600] do_exit+0x9bb/0x1ad0 [ 23.416612] ? binder_ioctl+0x4d1/0x1417 [ 23.416618] ? mm_update_next_owner+0x930/0x930 [ 23.416627] ? binder_ioctl_write_read.isra.38+0xcb0/0xcb0 [ 23.416638] ? avc_ss_reset+0x110/0x110 [ 23.416644] ? mutex_unlock+0xd/0x10 [ 23.416650] ? SyS_epoll_ctl+0x30a/0x1ab0 [ 23.416669] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 23.416675] ? up_read+0x1a/0x40 [ 23.416681] ? rcu_note_context_switch+0x710/0x710 [ 23.416687] ? __fd_install+0x288/0x740 [ 23.416697] ? binder_ioctl_write_read.isra.38+0xcb0/0xcb0 [ 23.416703] ? do_vfs_ioctl+0x486/0x1520 [ 23.416707] ? _cond_resched+0x14/0x30 [ 23.416715] ? ioctl_preallocate+0x2b0/0x2b0 [ 23.416723] ? selinux_capable+0x40/0x40 [ 23.416729] ? __alloc_fd+0x750/0x750 [ 23.416737] do_group_exit+0x149/0x400 [ 23.416744] ? SyS_exit+0x30/0x30 [ 23.416751] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 23.416759] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 23.416766] SyS_exit_group+0x1d/0x20 [ 23.416773] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 23.416779] RIP: 0033:0x4429f8 [ 23.416782] RSP: 002b:00007ffc54222088 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7 [ 23.416788] RAX: ffffffffffffffda RBX: 00000000004002e0 RCX: 00000000004429f8 [ 23.416792] RDX: 0000000000000000 RSI: 000000000000003c RDI: 0000000000000000 [ 23.416795] RBP: 00000000006ce018 R08: 00000000000000e7 R09: ffffffffffffffd0 [ 23.416799] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000401a40 [ 23.416802] R13: 0000000000401ad0 R14: 0000000000000000 R15: 0000000000000000 [ 23.416810] [ 23.416813] Allocated by task 3656: [ 23.416820] save_stack+0x43/0xd0 [ 23.416824] kasan_kmalloc+0xad/0xe0 [ 23.416829] kmem_cache_alloc_trace+0x136/0x750 [ 23.416835] binder_get_thread+0x1cf/0x870 [ 23.416840] binder_poll+0x8c/0x390 [ 23.416845] ep_item_poll.isra.10+0xec/0x320 [ 23.416849] ep_insert+0x6a3/0x1b10 [ 23.416854] SyS_epoll_ctl+0x12e4/0x1ab0 [ 23.416860] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 23.416861] [ 23.416863] Freed by task 3656: [ 23.416868] save_stack+0x43/0xd0 [ 23.416873] kasan_slab_free+0x71/0xc0 [ 23.416877] kfree+0xd6/0x260 [ 23.416882] binder_thread_dec_tmpref+0x27f/0x310 [ 23.416887] binder_thread_release+0x27d/0x540 [ 23.416893] binder_ioctl+0xc02/0x1417 [ 23.416897] do_vfs_ioctl+0x1b1/0x1520 [ 23.416901] SyS_ioctl+0x8f/0xc0 [ 23.416907] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 23.416908] [ 23.416912] The buggy address belongs to the object at ffff8801d99477c0 [ 23.416912] which belongs to the cache kmalloc-512 of size 512 [ 23.416917] The buggy address is located 176 bytes inside of [ 23.416917] 512-byte region [ffff8801d99477c0, ffff8801d99479c0) [ 23.416918] The buggy address belongs to the page: [ 23.416924] page:ffffea00076651c0 count:1 mapcount:0 mapping:ffff8801d9947040 index:0x0 [ 23.416930] flags: 0x2fffc0000000100(slab) [ 23.416939] raw: 02fffc0000000100 ffff8801d9947040 0000000000000000 0000000100000006 [ 23.416946] raw: ffffea000767f3e0 ffff8801dac01748 ffff8801dac00940 0000000000000000 [ 23.416948] page dumped because: kasan: bad access detected [ 23.416949] [ 23.416951] Memory state around the buggy address: [ 23.416955] ffff8801d9947700: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 23.416960] ffff8801d9947780: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb [ 23.416964] >ffff8801d9947800: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 23.416966] ^ [ 23.416971] ffff8801d9947880: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 23.416974] ffff8801d9947900: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 23.416977] ================================================================== [ 23.416979] Disabling lock debugging due to kernel taint [ 23.416983] Kernel panic - not syncing: panic_on_warn set ... [ 23.416983] [ 23.416989] CPU: 1 PID: 3656 Comm: syzkaller895466 Tainted: G B 4.15.0-rc8+ #264 [ 23.416992] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 23.416993] Call Trace: [ 23.416999] dump_stack+0x194/0x257 [ 23.417011] ? arch_local_irq_restore+0x53/0x53 [ 23.417016] ? kasan_end_report+0x32/0x50 [ 23.417022] ? lock_downgrade+0x980/0x980 [ 23.417030] ? vsnprintf+0x1ed/0x1900 [ 23.417036] ? __lock_acquire+0x3c70/0x3e00 [ 23.417042] panic+0x1e4/0x41c [ 23.417047] ? refcount_error_report+0x214/0x214 [ 23.417055] ? add_taint+0x40/0x50 [ 23.417060] ? add_taint+0x1c/0x50 [ 23.417066] ? __lock_acquire+0x3d4d/0x3e00 [ 23.417072] kasan_end_report+0x50/0x50 [ 23.417078] kasan_report+0x144/0x340 [ 23.417086] __asan_report_load8_noabort+0x14/0x20 [ 23.417092] __lock_acquire+0x3d4d/0x3e00 [ 23.417098] ? __lock_acquire+0x664/0x3e00 [ 23.417103] ? lock_downgrade+0x980/0x980 [ 23.417108] ? lock_downgrade+0x980/0x980 [ 23.417116] ? remove_wait_queue+0x81/0x350 [ 23.417125] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 23.417131] ? __lock_acquire+0x664/0x3e00 [ 23.417136] ? check_noncircular+0x20/0x20 [ 23.417148] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 23.417155] ? lock_acquire+0x1d5/0x580 [ 23.417161] ? lock_acquire+0x1d5/0x580 [ 23.417166] ? ep_free+0xf4/0x320 [ 23.417174] ? lock_release+0xa40/0xa40 [ 23.417180] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 23.417186] ? print_irqtrace_events+0x270/0x270 [ 23.417193] ? rcu_note_context_switch+0x710/0x710 [ 23.417200] ? __might_sleep+0x95/0x190 [ 23.417206] ? ep_free+0xf4/0x320 [ 23.417212] ? __mutex_lock+0x16f/0x1a80 [ 23.417217] ? ep_free+0xf4/0x320 [ 23.417224] ? print_irqtrace_events+0x270/0x270 [ 23.417229] ? ep_free+0xf4/0x320 [ 23.417237] lock_acquire+0x1d5/0x580 [ 23.417242] ? lock_acquire+0x1d5/0x580 [ 23.417248] ? remove_wait_queue+0x81/0x350 [ 23.417253] ? __lock_acquire+0x664/0x3e00 [ 23.417261] ? lock_release+0xa40/0xa40 [ 23.417270] ? lock_acquire+0x1d5/0x580 [ 23.417275] ? lock_acquire+0x1d5/0x580 [ 23.417281] ? ep_unregister_pollwait.isra.7+0x323/0x590 [ 23.417289] _raw_spin_lock_irqsave+0x96/0xc0 [ 23.417294] ? remove_wait_queue+0x81/0x350 [ 23.417301] remove_wait_queue+0x81/0x350 [ 23.417308] ? add_wait_queue+0x290/0x290 [ 23.417314] ? rcutorture_record_progress+0x10/0x10 [ 23.417324] ep_unregister_pollwait.isra.7+0x18c/0x590 [ 23.417331] ? __kernel_text_address+0xd/0x40 [ 23.417339] ? clear_tfile_check_list+0x370/0x370 [ 23.417346] ? check_noncircular+0x20/0x20 [ 23.417354] ? locks_remove_file+0x3fa/0x5a0 [ 23.417363] ep_free+0x13f/0x320 [ 23.417369] ? ep_remove+0x800/0x800 [ 23.417374] ? fsnotify_first_mark+0x2b0/0x2b0 [ 23.417382] ? ep_free+0x320/0x320 [ 23.417388] ep_eventpoll_release+0x44/0x60 [ 23.417394] __fput+0x327/0x7e0 [ 23.417402] ? fput+0x140/0x140 [ 23.417409] ? _raw_spin_unlock_irq+0x27/0x70 [ 23.417421] ____fput+0x15/0x20 [ 23.417427] task_work_run+0x199/0x270 [ 23.417434] ? task_work_cancel+0x210/0x210 [ 23.417441] ? _raw_spin_unlock+0x22/0x30 [ 23.417447] ? switch_task_namespaces+0x87/0xc0 [ 23.417454] do_exit+0x9bb/0x1ad0 [ 23.417462] ? binder_ioctl+0x4d1/0x1417 [ 23.417468] ? mm_update_next_owner+0x930/0x930 [ 23.417476] ? binder_ioctl_write_read.isra.38+0xcb0/0xcb0 [ 23.417484] ? avc_ss_reset+0x110/0x110 [ 23.417490] ? mutex_unlock+0xd/0x10 [ 23.417495] ? SyS_epoll_ctl+0x30a/0x1ab0 [ 23.417513] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 23.417518] ? up_read+0x1a/0x40 [ 23.417525] ? rcu_note_context_switch+0x710/0x710 [ 23.417530] ? __fd_install+0x288/0x740 [ 23.417539] ? binder_ioctl_write_read.isra.38+0xcb0/0xcb0 [ 23.417544] ? do_vfs_ioctl+0x486/0x1520 [ 23.417549] ? _cond_resched+0x14/0x30 [ 23.417557] ? ioctl_preallocate+0x2b0/0x2b0 [ 23.417564] ? selinux_capable+0x40/0x40 [ 23.417570] ? __alloc_fd+0x750/0x750 [ 23.417578] do_group_exit+0x149/0x400 [ 23.417585] ? SyS_exit+0x30/0x30 [ 23.417592] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 23.417598] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 23.417606] SyS_exit_group+0x1d/0x20 [ 23.417612] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 23.417616] RIP: 0033:0x4429f8 [ 23.417619] RSP: 002b:00007ffc54222088 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7 [ 23.417624] RAX: ffffffffffffffda RBX: 00000000004002e0 RCX: 00000000004429f8 [ 23.417627] RDX: 0000000000000000 RSI: 000000000000003c RDI: 0000000000000000 [ 23.417631] RBP: 00000000006ce018 R08: 00000000000000e7 R09: ffffffffffffffd0 [ 23.417634] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000401a40 [ 23.417637] R13: 0000000000401ad0 R14: 0000000000000000 R15: 0000000000000000 [ 23.435554] Dumping ftrace buffer: [ 23.435559] (ftrace buffer empty) [ 23.435562] Kernel Offset: disabled [ 24.565810] Rebooting in 86400 seconds..