[....] Starting enhanced syslogd: rsyslogd[ 13.001224] audit: type=1400 audit(1516984204.081:5): avc: denied { syslog } for pid=3506 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: [ 18.012833] audit: type=1400 audit(1516984209.093:6): avc: denied { map } for pid=3645 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.221' (ECDSA) to the list of known hosts. executing program [ 24.290233] audit: type=1400 audit(1516984215.371:7): avc: denied { map } for pid=3659 comm="syzkaller041216" path="/root/syzkaller041216674" 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 [ 24.294657] ================================================================== [ 24.294668] BUG: KASAN: use-after-free in __lock_acquire+0x3d4d/0x3e00 [ 24.294671] Read of size 8 at addr ffff8801d9889170 by task syzkaller041216/3659 [ 24.294672] [ 24.294677] CPU: 0 PID: 3659 Comm: syzkaller041216 Not tainted 4.15.0-rc9+ #281 [ 24.294679] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 24.294680] Call Trace: [ 24.294688] dump_stack+0x194/0x257 [ 24.294694] ? arch_local_irq_restore+0x53/0x53 [ 24.294700] ? show_regs_print_info+0x18/0x18 [ 24.294704] ? print_irqtrace_events+0x270/0x270 [ 24.294707] ? __lock_acquire+0x664/0x3e00 [ 24.294711] ? __lock_acquire+0x3d4d/0x3e00 [ 24.294718] print_address_description+0x73/0x250 [ 24.294722] ? __lock_acquire+0x3d4d/0x3e00 [ 24.294726] kasan_report+0x25b/0x340 [ 24.294730] __asan_report_load8_noabort+0x14/0x20 [ 24.294734] __lock_acquire+0x3d4d/0x3e00 [ 24.294737] ? __lock_acquire+0x664/0x3e00 [ 24.294741] ? lock_downgrade+0x980/0x980 [ 24.294744] ? lock_downgrade+0x980/0x980 [ 24.294750] ? remove_wait_queue+0x81/0x350 [ 24.294756] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 24.294760] ? __lock_acquire+0x664/0x3e00 [ 24.294763] ? check_noncircular+0x20/0x20 [ 24.294771] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 24.294775] ? lock_acquire+0x1d5/0x580 [ 24.294779] ? lock_acquire+0x1d5/0x580 [ 24.294784] ? ep_free+0xf4/0x320 [ 24.294789] ? lock_release+0xa40/0xa40 [ 24.294794] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 24.294798] ? print_irqtrace_events+0x270/0x270 [ 24.294803] ? rcu_note_context_switch+0x710/0x710 [ 24.294808] ? __might_sleep+0x95/0x190 [ 24.294811] ? ep_free+0xf4/0x320 [ 24.294816] ? __mutex_lock+0x16f/0x1a80 [ 24.294819] ? ep_free+0xf4/0x320 [ 24.294824] ? print_irqtrace_events+0x270/0x270 [ 24.294827] ? ep_free+0xf4/0x320 [ 24.294832] lock_acquire+0x1d5/0x580 [ 24.294835] ? lock_acquire+0x1d5/0x580 [ 24.294838] ? remove_wait_queue+0x81/0x350 [ 24.294842] ? __lock_acquire+0x664/0x3e00 [ 24.294846] ? lock_release+0xa40/0xa40 [ 24.294852] ? lock_acquire+0x1d5/0x580 [ 24.294855] ? lock_acquire+0x1d5/0x580 [ 24.294859] ? ep_unregister_pollwait.isra.7+0x323/0x590 [ 24.294863] _raw_spin_lock_irqsave+0x96/0xc0 [ 24.294866] ? remove_wait_queue+0x81/0x350 [ 24.294870] remove_wait_queue+0x81/0x350 [ 24.294875] ? add_wait_queue+0x290/0x290 [ 24.294879] ? rcutorture_record_progress+0x10/0x10 [ 24.294885] ep_unregister_pollwait.isra.7+0x18c/0x590 [ 24.294891] ? __kernel_text_address+0xd/0x40 [ 24.294896] ? clear_tfile_check_list+0x370/0x370 [ 24.294901] ? check_noncircular+0x20/0x20 [ 24.294907] ? locks_remove_file+0x3fa/0x5a0 [ 24.294912] ep_free+0x13f/0x320 [ 24.294916] ? ep_remove+0x800/0x800 [ 24.294920] ? fsnotify_first_mark+0x2b0/0x2b0 [ 24.294925] ? ep_free+0x320/0x320 [ 24.294928] ep_eventpoll_release+0x44/0x60 [ 24.294935] __fput+0x327/0x7e0 [ 24.294940] ? fput+0x140/0x140 [ 24.294945] ? _raw_spin_unlock_irq+0x27/0x70 [ 24.294950] ____fput+0x15/0x20 [ 24.294954] task_work_run+0x199/0x270 [ 24.294959] ? task_work_cancel+0x210/0x210 [ 24.294963] ? _raw_spin_unlock+0x22/0x30 [ 24.294967] ? switch_task_namespaces+0x87/0xc0 [ 24.294972] do_exit+0x9bb/0x1ad0 [ 24.294978] ? binder_ioctl+0x521/0x1417 [ 24.294982] ? mm_update_next_owner+0x930/0x930 [ 24.294987] ? binder_ioctl_write_read.isra.38+0xcb0/0xcb0 [ 24.294993] ? avc_ss_reset+0x110/0x110 [ 24.294997] ? mutex_unlock+0xd/0x10 [ 24.295004] ? SyS_epoll_ctl+0x30a/0x1ab0 [ 24.295017] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 24.295020] ? up_read+0x1a/0x40 [ 24.295024] ? rcu_note_context_switch+0x710/0x710 [ 24.295029] ? __fd_install+0x288/0x740 [ 24.295034] ? binder_ioctl_write_read.isra.38+0xcb0/0xcb0 [ 24.295038] ? do_vfs_ioctl+0x486/0x1520 [ 24.295041] ? _cond_resched+0x14/0x30 [ 24.295046] ? ioctl_preallocate+0x2b0/0x2b0 [ 24.295052] ? selinux_capable+0x40/0x40 [ 24.295056] ? __alloc_fd+0x750/0x750 [ 24.295061] do_group_exit+0x149/0x400 [ 24.295065] ? SyS_exit+0x30/0x30 [ 24.295069] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 24.295076] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 24.295081] SyS_exit_group+0x1d/0x20 [ 24.295085] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 24.295088] RIP: 0033:0x4429f8 [ 24.295090] RSP: 002b:00007ffeff40e1d8 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7 [ 24.295094] RAX: ffffffffffffffda RBX: 00000000004002e0 RCX: 00000000004429f8 [ 24.295097] RDX: 0000000000000000 RSI: 000000000000003c RDI: 0000000000000000 [ 24.295099] RBP: 00000000006ce018 R08: 00000000000000e7 R09: ffffffffffffffd0 [ 24.295101] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000401a40 [ 24.295103] R13: 0000000000401ad0 R14: 0000000000000000 R15: 0000000000000000 [ 24.295109] [ 24.295110] Allocated by task 3659: [ 24.295114] save_stack+0x43/0xd0 [ 24.295117] kasan_kmalloc+0xad/0xe0 [ 24.295120] kmem_cache_alloc_trace+0x136/0x750 [ 24.295126] binder_get_thread+0x1cf/0x870 [ 24.295129] binder_poll+0x8c/0x390 [ 24.295132] ep_item_poll.isra.10+0xec/0x320 [ 24.295135] ep_insert+0x6a3/0x1b10 [ 24.295138] SyS_epoll_ctl+0x12e4/0x1ab0 [ 24.295140] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 24.295141] [ 24.295142] Freed by task 3659: [ 24.295145] save_stack+0x43/0xd0 [ 24.295148] kasan_slab_free+0x71/0xc0 [ 24.295151] kfree+0xd6/0x260 [ 24.295154] binder_thread_dec_tmpref+0x27f/0x310 [ 24.295157] binder_thread_release+0x27d/0x540 [ 24.295160] binder_ioctl+0xc02/0x1417 [ 24.295162] do_vfs_ioctl+0x1b1/0x1520 [ 24.295165] SyS_ioctl+0x8f/0xc0 [ 24.295168] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 24.295168] [ 24.295171] The buggy address belongs to the object at ffff8801d98890c0 [ 24.295171] which belongs to the cache kmalloc-512 of size 512 [ 24.295174] The buggy address is located 176 bytes inside of [ 24.295174] 512-byte region [ffff8801d98890c0, ffff8801d98892c0) [ 24.295175] The buggy address belongs to the page: [ 24.295178] page:ffffea0007662240 count:1 mapcount:0 mapping:ffff8801d98890c0 index:0x0 [ 24.295181] flags: 0x2fffc0000000100(slab) [ 24.295187] raw: 02fffc0000000100 ffff8801d98890c0 0000000000000000 0000000100000006 [ 24.295191] raw: ffffea0006f01fa0 ffff8801dac01748 ffff8801dac00940 0000000000000000 [ 24.295193] page dumped because: kasan: bad access detected [ 24.295193] [ 24.295194] Memory state around the buggy address: [ 24.295197] ffff8801d9889000: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 24.295200] ffff8801d9889080: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb [ 24.295203] >ffff8801d9889100: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 24.295204] ^ [ 24.295206] ffff8801d9889180: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 24.295209] ffff8801d9889200: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 24.295210] ================================================================== [ 24.295211] Disabling lock debugging due to kernel taint [ 24.295213] Kernel panic - not syncing: panic_on_warn set ... [ 24.295213] [ 24.295217] CPU: 0 PID: 3659 Comm: syzkaller041216 Tainted: G B 4.15.0-rc9+ #281 [ 24.295219] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 24.295220] Call Trace: [ 24.295224] dump_stack+0x194/0x257 [ 24.295228] ? arch_local_irq_restore+0x53/0x53 [ 24.295232] ? kasan_end_report+0x32/0x50 [ 24.295235] ? lock_downgrade+0x980/0x980 [ 24.295240] ? vsnprintf+0x1ed/0x1900 [ 24.295244] ? __lock_acquire+0x3ca0/0x3e00 [ 24.295247] panic+0x1e4/0x41c [ 24.295251] ? refcount_error_report+0x214/0x214 [ 24.295255] ? add_taint+0x40/0x50 [ 24.295258] ? add_taint+0x1c/0x50 [ 24.295262] ? __lock_acquire+0x3d4d/0x3e00 [ 24.295265] kasan_end_report+0x50/0x50 [ 24.295269] kasan_report+0x144/0x340 [ 24.295273] __asan_report_load8_noabort+0x14/0x20 [ 24.295277] __lock_acquire+0x3d4d/0x3e00 [ 24.295280] ? __lock_acquire+0x664/0x3e00 [ 24.295283] ? lock_downgrade+0x980/0x980 [ 24.295286] ? lock_downgrade+0x980/0x980 [ 24.295291] ? remove_wait_queue+0x81/0x350 [ 24.295296] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 24.295300] ? __lock_acquire+0x664/0x3e00 [ 24.295303] ? check_noncircular+0x20/0x20 [ 24.295310] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 24.295314] ? lock_acquire+0x1d5/0x580 [ 24.295317] ? lock_acquire+0x1d5/0x580 [ 24.295320] ? ep_free+0xf4/0x320 [ 24.295325] ? lock_release+0xa40/0xa40 [ 24.295328] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 24.295332] ? print_irqtrace_events+0x270/0x270 [ 24.295336] ? rcu_note_context_switch+0x710/0x710 [ 24.295340] ? __might_sleep+0x95/0x190 [ 24.295344] ? ep_free+0xf4/0x320 [ 24.295347] ? __mutex_lock+0x16f/0x1a80 [ 24.295350] ? ep_free+0xf4/0x320 [ 24.295354] ? print_irqtrace_events+0x270/0x270 [ 24.295357] ? ep_free+0xf4/0x320 [ 24.295362] lock_acquire+0x1d5/0x580 [ 24.295365] ? lock_acquire+0x1d5/0x580 [ 24.295368] ? remove_wait_queue+0x81/0x350 [ 24.295372] ? __lock_acquire+0x664/0x3e00 [ 24.295378] ? lock_release+0xa40/0xa40 [ 24.295387] ? lock_acquire+0x1d5/0x580 [ 24.295392] ? lock_acquire+0x1d5/0x580 [ 24.295398] ? ep_unregister_pollwait.isra.7+0x323/0x590 [ 24.295410] _raw_spin_lock_irqsave+0x96/0xc0 [ 24.295413] ? remove_wait_queue+0x81/0x350 [ 24.295417] remove_wait_queue+0x81/0x350 [ 24.295421] ? add_wait_queue+0x290/0x290 [ 24.295425] ? rcutorture_record_progress+0x10/0x10 [ 24.295431] ep_unregister_pollwait.isra.7+0x18c/0x590 [ 24.295435] ? __kernel_text_address+0xd/0x40 [ 24.295439] ? clear_tfile_check_list+0x370/0x370 [ 24.295444] ? check_noncircular+0x20/0x20 [ 24.295449] ? locks_remove_file+0x3fa/0x5a0 [ 24.295454] ep_free+0x13f/0x320 [ 24.295458] ? ep_remove+0x800/0x800 [ 24.295461] ? fsnotify_first_mark+0x2b0/0x2b0 [ 24.295465] ? ep_free+0x320/0x320 [ 24.295469] ep_eventpoll_release+0x44/0x60 [ 24.295473] __fput+0x327/0x7e0 [ 24.295478] ? fput+0x140/0x140 [ 24.295482] ? _raw_spin_unlock_irq+0x27/0x70 [ 24.295487] ____fput+0x15/0x20 [ 24.295491] task_work_run+0x199/0x270 [ 24.295495] ? task_work_cancel+0x210/0x210 [ 24.295499] ? _raw_spin_unlock+0x22/0x30 [ 24.295503] ? switch_task_namespaces+0x87/0xc0 [ 24.295507] do_exit+0x9bb/0x1ad0 [ 24.295511] ? binder_ioctl+0x521/0x1417 [ 24.295515] ? mm_update_next_owner+0x930/0x930 [ 24.295519] ? binder_ioctl_write_read.isra.38+0xcb0/0xcb0 [ 24.295524] ? avc_ss_reset+0x110/0x110 [ 24.295527] ? mutex_unlock+0xd/0x10 [ 24.295531] ? SyS_epoll_ctl+0x30a/0x1ab0 [ 24.295541] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 24.295544] ? up_read+0x1a/0x40 [ 24.295548] ? rcu_note_context_switch+0x710/0x710 [ 24.295551] ? __fd_install+0x288/0x740 [ 24.295555] ? binder_ioctl_write_read.isra.38+0xcb0/0xcb0 [ 24.295558] ? do_vfs_ioctl+0x486/0x1520 [ 24.295561] ? _cond_resched+0x14/0x30 [ 24.295566] ? ioctl_preallocate+0x2b0/0x2b0 [ 24.295570] ? selinux_capable+0x40/0x40 [ 24.295574] ? __alloc_fd+0x750/0x750 [ 24.295578] do_group_exit+0x149/0x400 [ 24.295582] ? SyS_exit+0x30/0x30 [ 24.295586] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 24.295590] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 24.295594] SyS_exit_group+0x1d/0x20 [ 24.295598] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 24.295600] RIP: 0033:0x4429f8 [ 24.295602] RSP: 002b:00007ffeff40e1d8 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7 [ 24.295605] RAX: ffffffffffffffda RBX: 00000000004002e0 RCX: 00000000004429f8 [ 24.295607] RDX: 0000000000000000 RSI: 000000000000003c RDI: 0000000000000000 [ 24.295609] RBP: 00000000006ce018 R08: 00000000000000e7 R09: ffffffffffffffd0 [ 24.295611] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000401a40 [ 24.295613] R13: 0000000000401ad0 R14: 0000000000000000 R15: 0000000000000000 [ 24.317084] Dumping ftrace buffer: [ 24.317087] (ftrace buffer empty) [ 24.317089] Kernel Offset: disabled [ 25.442309] Rebooting in 86400 seconds..