[....] Starting enhanced syslogd: rsyslogd[ 11.280420] audit: type=1400 audit(1514242257.707:5): avc: denied { syslog } for pid=2999 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 mcstransd: [....] Starting periodic command scheduler: cron[?25l[?1c7[ ok 8[?25h[?0c. [....] 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: [ 13.991656] audit: type=1400 audit(1514242260.418:6): avc: denied { map } for pid=3137 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 'ci-upstream-kasan-gce-386-2,10.128.0.45' (ECDSA) to the list of known hosts. executing program [ 20.158179] audit: type=1400 audit(1514242266.584:7): avc: denied { map } for pid=3151 comm="syzkaller031224" path="/root/syzkaller031224998" 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 [ 20.162503] ================================================================== [ 20.162517] BUG: KASAN: use-after-free in __lock_acquire+0x3d4d/0x3e00 [ 20.162522] Read of size 8 at addr ffff8801c94c15f0 by task syzkaller031224/3151 [ 20.162523] [ 20.162529] CPU: 1 PID: 3151 Comm: syzkaller031224 Not tainted 4.15.0-rc5+ #147 [ 20.162533] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 20.162535] Call Trace: [ 20.162544] dump_stack+0x194/0x257 [ 20.162551] ? arch_local_irq_restore+0x53/0x53 [ 20.162559] ? show_regs_print_info+0x18/0x18 [ 20.162564] ? print_irqtrace_events+0x270/0x270 [ 20.162571] ? __lock_acquire+0x664/0x3e00 [ 20.162577] ? __lock_acquire+0x3d4d/0x3e00 [ 20.162585] print_address_description+0x73/0x250 [ 20.162591] ? __lock_acquire+0x3d4d/0x3e00 [ 20.162602] kasan_report+0x25b/0x340 [ 20.162610] __asan_report_load8_noabort+0x14/0x20 [ 20.162616] __lock_acquire+0x3d4d/0x3e00 [ 20.162622] ? __lock_acquire+0x664/0x3e00 [ 20.162627] ? lock_downgrade+0x980/0x980 [ 20.162633] ? lock_downgrade+0x980/0x980 [ 20.162639] ? print_irqtrace_events+0x270/0x270 [ 20.162646] ? remove_wait_queue+0x81/0x350 [ 20.162654] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 20.162661] ? __lock_acquire+0x664/0x3e00 [ 20.162666] ? check_noncircular+0x20/0x20 [ 20.162678] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 20.162685] ? lock_acquire+0x1d5/0x580 [ 20.162690] ? lock_acquire+0x1d5/0x580 [ 20.162696] ? ep_free+0xf4/0x320 [ 20.162705] ? lock_release+0xa40/0xa40 [ 20.162711] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 20.162717] ? print_irqtrace_events+0x270/0x270 [ 20.162722] ? print_irqtrace_events+0x270/0x270 [ 20.162729] ? rcu_note_context_switch+0x710/0x710 [ 20.162737] ? __might_sleep+0x95/0x190 [ 20.162742] ? ep_free+0xf4/0x320 [ 20.162748] ? __mutex_lock+0x16f/0x1a80 [ 20.162753] ? ep_free+0xf4/0x320 [ 20.162759] ? print_irqtrace_events+0x270/0x270 [ 20.162764] ? ep_free+0xf4/0x320 [ 20.162772] lock_acquire+0x1d5/0x580 [ 20.162777] ? lock_acquire+0x1d5/0x580 [ 20.162783] ? remove_wait_queue+0x81/0x350 [ 20.162792] ? lock_release+0xa40/0xa40 [ 20.162800] ? lock_acquire+0x1d5/0x580 [ 20.162806] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 20.162811] ? lock_acquire+0x1d5/0x580 [ 20.162817] ? ep_unregister_pollwait.isra.7+0x323/0x590 [ 20.162824] _raw_spin_lock_irqsave+0x96/0xc0 [ 20.162830] ? remove_wait_queue+0x81/0x350 [ 20.162836] remove_wait_queue+0x81/0x350 [ 20.162844] ? depot_save_stack+0x3b5/0x490 [ 20.162851] ? add_wait_queue+0x290/0x290 [ 20.162857] ? rcutorture_record_progress+0x10/0x10 [ 20.162863] ? lock_release+0xa40/0xa40 [ 20.162871] ep_unregister_pollwait.isra.7+0x18c/0x590 [ 20.162879] ? __kernel_text_address+0xd/0x40 [ 20.162886] ? clear_tfile_check_list+0x370/0x370 [ 20.162893] ? check_noncircular+0x20/0x20 [ 20.162902] ? locks_remove_file+0x3fa/0x5a0 [ 20.162910] ep_free+0x13f/0x320 [ 20.162916] ? ep_remove+0x800/0x800 [ 20.162923] ? fsnotify_first_mark+0x2b0/0x2b0 [ 20.162930] ? ep_free+0x320/0x320 [ 20.162935] ep_eventpoll_release+0x44/0x60 [ 20.162941] __fput+0x327/0x7e0 [ 20.162949] ? fput+0x140/0x140 [ 20.162956] ? _raw_spin_unlock_irq+0x27/0x70 [ 20.162963] ____fput+0x15/0x20 [ 20.162970] task_work_run+0x199/0x270 [ 20.162977] ? task_work_cancel+0x210/0x210 [ 20.162983] ? _raw_spin_unlock+0x22/0x30 [ 20.162989] ? switch_task_namespaces+0x87/0xc0 [ 20.162997] do_exit+0x9bb/0x1ad0 [ 20.163007] ? __handle_mm_fault+0x2330/0x3ce0 [ 20.163015] ? mm_update_next_owner+0x930/0x930 [ 20.163024] ? do_raw_spin_trylock+0x190/0x190 [ 20.163031] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 20.163037] ? check_noncircular+0x20/0x20 [ 20.163044] ? _raw_spin_unlock+0x22/0x30 [ 20.163050] ? __handle_mm_fault+0x80e/0x3ce0 [ 20.163057] ? check_noncircular+0x20/0x20 [ 20.163062] ? __pmd_alloc+0x4e0/0x4e0 [ 20.163067] ? lock_downgrade+0x980/0x980 [ 20.163075] ? find_held_lock+0x35/0x1d0 [ 20.163084] ? handle_mm_fault+0x248/0x8d0 [ 20.163091] ? find_held_lock+0x35/0x1d0 [ 20.163100] ? __do_page_fault+0x5f7/0xc90 [ 20.163106] ? lock_downgrade+0x980/0x980 [ 20.163115] ? handle_mm_fault+0x410/0x8d0 [ 20.163120] ? down_read_trylock+0xdb/0x170 [ 20.163126] ? __do_page_fault+0x32d/0xc90 [ 20.163132] ? __handle_mm_fault+0x3ce0/0x3ce0 [ 20.163138] ? vmacache_find+0x5f/0x280 [ 20.163144] ? vmacache_update+0xfe/0x130 [ 20.163152] do_group_exit+0x149/0x400 [ 20.163158] ? __do_page_fault+0x3d6/0xc90 [ 20.163164] ? SyS_exit+0x30/0x30 [ 20.163172] ? do_fast_syscall_32+0x156/0xf9d [ 20.163178] ? do_group_exit+0x400/0x400 [ 20.163185] SyS_exit_group+0x1d/0x20 [ 20.163191] do_fast_syscall_32+0x3ee/0xf9d [ 20.163199] ? do_int80_syscall_32+0x9d0/0x9d0 [ 20.163205] ? kasan_check_read+0x11/0x20 [ 20.163212] ? syscall_return_slowpath+0x550/0x550 [ 20.163219] ? SyS_rt_sigaction+0x94/0x1b0 [ 20.163225] ? SyS_sigprocmask+0x4b0/0x4b0 [ 20.163230] ? SyS_read+0x184/0x220 [ 20.163236] ? retint_user+0x18/0x18 [ 20.163244] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 20.163254] entry_SYSENTER_compat+0x54/0x63 [ 20.163258] RIP: 0023:0xf7f5dc79 [ 20.163262] RSP: 002b:00000000ffd99e3c EFLAGS: 00000292 ORIG_RAX: 00000000000000fc [ 20.163268] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00000000080f0298 [ 20.163272] RDX: 0000000000000000 RSI: 00000000080d9ad8 RDI: 00000000080f02a0 [ 20.163275] RBP: 0000000000000001 R08: 0000000000000000 R09: 0000000000000000 [ 20.163278] R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000 [ 20.163281] R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 [ 20.163289] [ 20.163292] Allocated by task 3151: [ 20.163297] save_stack+0x43/0xd0 [ 20.163301] kasan_kmalloc+0xad/0xe0 [ 20.163307] kmem_cache_alloc_trace+0x136/0x750 [ 20.163314] binder_get_thread+0x1cf/0x870 [ 20.163319] binder_poll+0x8c/0x390 [ 20.163323] ep_item_poll.isra.10+0xec/0x320 [ 20.163327] ep_insert+0x6a3/0x1b10 [ 20.163332] SyS_epoll_ctl+0x12e4/0x1ab0 [ 20.163337] do_fast_syscall_32+0x3ee/0xf9d [ 20.163343] entry_SYSENTER_compat+0x54/0x63 [ 20.163344] [ 20.163346] Freed by task 3151: [ 20.163350] save_stack+0x43/0xd0 [ 20.163354] kasan_slab_free+0x71/0xc0 [ 20.163358] kfree+0xd6/0x260 [ 20.163363] binder_thread_dec_tmpref+0x27f/0x310 [ 20.163368] binder_thread_release+0x27d/0x540 [ 20.163373] binder_ioctl+0xc02/0x1417 [ 20.163378] compat_SyS_ioctl+0x151/0x2a30 [ 20.163382] do_fast_syscall_32+0x3ee/0xf9d [ 20.163388] entry_SYSENTER_compat+0x54/0x63 [ 20.163389] [ 20.163393] The buggy address belongs to the object at ffff8801c94c1540 [ 20.163393] which belongs to the cache kmalloc-512 of size 512 [ 20.163398] The buggy address is located 176 bytes inside of [ 20.163398] 512-byte region [ffff8801c94c1540, ffff8801c94c1740) [ 20.163400] The buggy address belongs to the page: [ 20.163405] page:000000003a8c6520 count:1 mapcount:0 mapping:00000000c4ab3267 index:0x0 [ 20.163410] flags: 0x2fffc0000000100(slab) [ 20.163418] raw: 02fffc0000000100 ffff8801c94c1040 0000000000000000 0000000100000006 [ 20.163425] raw: ffffea0007290060 ffffea000726dda0 ffff8801db000940 0000000000000000 [ 20.163427] page dumped because: kasan: bad access detected [ 20.163429] [ 20.163430] Memory state around the buggy address: [ 20.163435] ffff8801c94c1480: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 20.163439] ffff8801c94c1500: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb [ 20.163443] >ffff8801c94c1580: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 20.163446] ^ [ 20.163450] ffff8801c94c1600: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 20.163454] ffff8801c94c1680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 20.163456] ================================================================== [ 20.163458] Disabling lock debugging due to kernel taint [ 20.163461] Kernel panic - not syncing: panic_on_warn set ... [ 20.163461] [ 20.163467] CPU: 1 PID: 3151 Comm: syzkaller031224 Tainted: G B 4.15.0-rc5+ #147 [ 20.163470] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 20.163471] Call Trace: [ 20.163477] dump_stack+0x194/0x257 [ 20.163484] ? arch_local_irq_restore+0x53/0x53 [ 20.163489] ? kasan_end_report+0x32/0x50 [ 20.163495] ? lock_downgrade+0x980/0x980 [ 20.163501] ? vsnprintf+0x1ed/0x1900 [ 20.163507] ? __lock_acquire+0x3cd0/0x3e00 [ 20.163512] panic+0x1e4/0x41c [ 20.163518] ? refcount_error_report+0x214/0x214 [ 20.163525] ? add_taint+0x40/0x50 [ 20.163530] ? add_taint+0x1c/0x50 [ 20.163537] ? __lock_acquire+0x3d4d/0x3e00 [ 20.163542] kasan_end_report+0x50/0x50 [ 20.163548] kasan_report+0x144/0x340 [ 20.163555] __asan_report_load8_noabort+0x14/0x20 [ 20.163561] __lock_acquire+0x3d4d/0x3e00 [ 20.163566] ? __lock_acquire+0x664/0x3e00 [ 20.163572] ? lock_downgrade+0x980/0x980 [ 20.163577] ? lock_downgrade+0x980/0x980 [ 20.163583] ? print_irqtrace_events+0x270/0x270 [ 20.163589] ? remove_wait_queue+0x81/0x350 [ 20.163601] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 20.163607] ? __lock_acquire+0x664/0x3e00 [ 20.163613] ? check_noncircular+0x20/0x20 [ 20.163624] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 20.163631] ? lock_acquire+0x1d5/0x580 [ 20.163636] ? lock_acquire+0x1d5/0x580 [ 20.163641] ? ep_free+0xf4/0x320 [ 20.163649] ? lock_release+0xa40/0xa40 [ 20.163655] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 20.163660] ? print_irqtrace_events+0x270/0x270 [ 20.163666] ? print_irqtrace_events+0x270/0x270 [ 20.163672] ? rcu_note_context_switch+0x710/0x710 [ 20.163679] ? __might_sleep+0x95/0x190 [ 20.163684] ? ep_free+0xf4/0x320 [ 20.163689] ? __mutex_lock+0x16f/0x1a80 [ 20.163694] ? ep_free+0xf4/0x320 [ 20.163701] ? print_irqtrace_events+0x270/0x270 [ 20.163705] ? ep_free+0xf4/0x320 [ 20.163713] lock_acquire+0x1d5/0x580 [ 20.163719] ? lock_acquire+0x1d5/0x580 [ 20.163724] ? remove_wait_queue+0x81/0x350 [ 20.163732] ? lock_release+0xa40/0xa40 [ 20.163741] ? lock_acquire+0x1d5/0x580 [ 20.163747] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 20.163752] ? lock_acquire+0x1d5/0x580 [ 20.163758] ? ep_unregister_pollwait.isra.7+0x323/0x590 [ 20.163765] _raw_spin_lock_irqsave+0x96/0xc0 [ 20.163770] ? remove_wait_queue+0x81/0x350 [ 20.163777] remove_wait_queue+0x81/0x350 [ 20.163782] ? depot_save_stack+0x3b5/0x490 [ 20.163789] ? add_wait_queue+0x290/0x290 [ 20.163795] ? rcutorture_record_progress+0x10/0x10 [ 20.163800] ? lock_release+0xa40/0xa40 [ 20.163808] ep_unregister_pollwait.isra.7+0x18c/0x590 [ 20.163815] ? __kernel_text_address+0xd/0x40 [ 20.163822] ? clear_tfile_check_list+0x370/0x370 [ 20.163829] ? check_noncircular+0x20/0x20 [ 20.163836] ? locks_remove_file+0x3fa/0x5a0 [ 20.163845] ep_free+0x13f/0x320 [ 20.163850] ? ep_remove+0x800/0x800 [ 20.163857] ? fsnotify_first_mark+0x2b0/0x2b0 [ 20.163864] ? ep_free+0x320/0x320 [ 20.163869] ep_eventpoll_release+0x44/0x60 [ 20.163874] __fput+0x327/0x7e0 [ 20.163882] ? fput+0x140/0x140 [ 20.163888] ? _raw_spin_unlock_irq+0x27/0x70 [ 20.163896] ____fput+0x15/0x20 [ 20.163902] task_work_run+0x199/0x270 [ 20.163909] ? task_work_cancel+0x210/0x210 [ 20.163915] ? _raw_spin_unlock+0x22/0x30 [ 20.163921] ? switch_task_namespaces+0x87/0xc0 [ 20.163928] do_exit+0x9bb/0x1ad0 [ 20.163934] ? __handle_mm_fault+0x2330/0x3ce0 [ 20.163942] ? mm_update_next_owner+0x930/0x930 [ 20.163951] ? do_raw_spin_trylock+0x190/0x190 [ 20.163958] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 20.163963] ? check_noncircular+0x20/0x20 [ 20.163970] ? _raw_spin_unlock+0x22/0x30 [ 20.163976] ? __handle_mm_fault+0x80e/0x3ce0 [ 20.163983] ? check_noncircular+0x20/0x20 [ 20.163988] ? __pmd_alloc+0x4e0/0x4e0 [ 20.163993] ? lock_downgrade+0x980/0x980 [ 20.164001] ? find_held_lock+0x35/0x1d0 [ 20.164009] ? handle_mm_fault+0x248/0x8d0 [ 20.164016] ? find_held_lock+0x35/0x1d0 [ 20.164025] ? __do_page_fault+0x5f7/0xc90 [ 20.164031] ? lock_downgrade+0x980/0x980 [ 20.164039] ? handle_mm_fault+0x410/0x8d0 [ 20.164044] ? down_read_trylock+0xdb/0x170 [ 20.164050] ? __do_page_fault+0x32d/0xc90 [ 20.164056] ? __handle_mm_fault+0x3ce0/0x3ce0 [ 20.164061] ? vmacache_find+0x5f/0x280 [ 20.164067] ? vmacache_update+0xfe/0x130 [ 20.164075] do_group_exit+0x149/0x400 [ 20.164081] ? __do_page_fault+0x3d6/0xc90 [ 20.164086] ? SyS_exit+0x30/0x30 [ 20.164093] ? do_fast_syscall_32+0x156/0xf9d [ 20.164099] ? do_group_exit+0x400/0x400 [ 20.164105] SyS_exit_group+0x1d/0x20 [ 20.164111] do_fast_syscall_32+0x3ee/0xf9d [ 20.164119] ? do_int80_syscall_32+0x9d0/0x9d0 [ 20.164125] ? kasan_check_read+0x11/0x20 [ 20.164132] ? syscall_return_slowpath+0x550/0x550 [ 20.164138] ? SyS_rt_sigaction+0x94/0x1b0 [ 20.164144] ? SyS_sigprocmask+0x4b0/0x4b0 [ 20.164149] ? SyS_read+0x184/0x220 [ 20.164155] ? retint_user+0x18/0x18 [ 20.164162] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 20.164171] entry_SYSENTER_compat+0x54/0x63 [ 20.164175] RIP: 0023:0xf7f5dc79 [ 20.164178] RSP: 002b:00000000ffd99e3c EFLAGS: 00000292 ORIG_RAX: 00000000000000fc [ 20.164183] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00000000080f0298 [ 20.164187] RDX: 0000000000000000 RSI: 00000000080d9ad8 RDI: 00000000080f02a0 [ 20.164190] RBP: 0000000000000001 R08: 0000000000000000 R09: 0000000000000000 [ 20.164193] R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000 [ 20.164196] R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 [ 20.184742] Dumping ftrace buffer: [ 20.184745] (ftrace buffer empty) [ 20.184747] Kernel Offset: disabled [ 21.475124] Rebooting in 86400 seconds..