[....] Starting enhanced syslogd: rsyslogd[ 10.208481] audit: type=1400 audit(1513998659.983:5): avc: denied { syslog } for pid=2990 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: [ 12.522781] audit: type=1400 audit(1513998662.298:6): avc: denied { map } for pid=3129 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-7,10.128.0.8' (ECDSA) to the list of known hosts. executing program [ 18.925804] audit: type=1400 audit(1513998668.701:7): avc: denied { map } for pid=3143 comm="syzkaller810424" path="/root/syzkaller810424258" 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 [ 18.930343] ================================================================== [ 18.930357] BUG: KASAN: use-after-free in __lock_acquire+0x3d4d/0x3e00 [ 18.930362] Read of size 8 at addr ffff8801ca50d670 by task syzkaller810424/3143 [ 18.930363] [ 18.930370] CPU: 0 PID: 3143 Comm: syzkaller810424 Not tainted 4.15.0-rc4+ #234 [ 18.930374] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 18.930376] Call Trace: [ 18.930384] dump_stack+0x194/0x257 [ 18.930392] ? arch_local_irq_restore+0x53/0x53 [ 18.930401] ? show_regs_print_info+0x18/0x18 [ 18.930406] ? print_irqtrace_events+0x270/0x270 [ 18.930412] ? __lock_acquire+0x664/0x3e00 [ 18.930419] ? __lock_acquire+0x3d4d/0x3e00 [ 18.930427] print_address_description+0x73/0x250 [ 18.930433] ? __lock_acquire+0x3d4d/0x3e00 [ 18.930438] kasan_report+0x25b/0x340 [ 18.930446] __asan_report_load8_noabort+0x14/0x20 [ 18.930452] __lock_acquire+0x3d4d/0x3e00 [ 18.930457] ? __lock_acquire+0x664/0x3e00 [ 18.930462] ? lock_downgrade+0x980/0x980 [ 18.930467] ? lock_downgrade+0x980/0x980 [ 18.930475] ? remove_wait_queue+0x81/0x350 [ 18.930484] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 18.930490] ? __lock_acquire+0x664/0x3e00 [ 18.930495] ? check_noncircular+0x20/0x20 [ 18.930508] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 18.930515] ? lock_acquire+0x1d5/0x580 [ 18.930520] ? lock_acquire+0x1d5/0x580 [ 18.930526] ? ep_free+0xf4/0x320 [ 18.930534] ? lock_release+0xa40/0xa40 [ 18.930541] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 18.930547] ? print_irqtrace_events+0x270/0x270 [ 18.930554] ? rcu_note_context_switch+0x710/0x710 [ 18.930561] ? __might_sleep+0x95/0x190 [ 18.930566] ? ep_free+0xf4/0x320 [ 18.930572] ? __mutex_lock+0x16f/0x1a80 [ 18.930577] ? ep_free+0xf4/0x320 [ 18.930589] ? print_irqtrace_events+0x270/0x270 [ 18.930594] ? ep_free+0xf4/0x320 [ 18.930602] lock_acquire+0x1d5/0x580 [ 18.930607] ? lock_acquire+0x1d5/0x580 [ 18.930613] ? remove_wait_queue+0x81/0x350 [ 18.930618] ? __lock_acquire+0x664/0x3e00 [ 18.930625] ? lock_release+0xa40/0xa40 [ 18.930634] ? lock_acquire+0x1d5/0x580 [ 18.930639] ? lock_acquire+0x1d5/0x580 [ 18.930645] ? ep_unregister_pollwait.isra.7+0x323/0x590 [ 18.930653] _raw_spin_lock_irqsave+0x96/0xc0 [ 18.930658] ? remove_wait_queue+0x81/0x350 [ 18.930664] remove_wait_queue+0x81/0x350 [ 18.930672] ? add_wait_queue+0x290/0x290 [ 18.930678] ? rcutorture_record_progress+0x10/0x10 [ 18.930687] ep_unregister_pollwait.isra.7+0x18c/0x590 [ 18.930696] ? __kernel_text_address+0xd/0x40 [ 18.930703] ? clear_tfile_check_list+0x370/0x370 [ 18.930710] ? check_noncircular+0x20/0x20 [ 18.930719] ? locks_remove_file+0x3fa/0x5a0 [ 18.930727] ep_free+0x13f/0x320 [ 18.930733] ? ep_remove+0x800/0x800 [ 18.930740] ? fsnotify_first_mark+0x2b0/0x2b0 [ 18.930748] ? ep_free+0x320/0x320 [ 18.930753] ep_eventpoll_release+0x44/0x60 [ 18.930760] __fput+0x327/0x7e0 [ 18.930767] ? fput+0x140/0x140 [ 18.930774] ? _raw_spin_unlock_irq+0x27/0x70 [ 18.930781] ____fput+0x15/0x20 [ 18.930788] task_work_run+0x199/0x270 [ 18.930795] ? task_work_cancel+0x210/0x210 [ 18.930801] ? _raw_spin_unlock+0x22/0x30 [ 18.930807] ? switch_task_namespaces+0x87/0xc0 [ 18.930815] do_exit+0x9bb/0x1ad0 [ 18.930823] ? binder_ioctl+0x4d1/0x1417 [ 18.930829] ? mm_update_next_owner+0x930/0x930 [ 18.930837] ? binder_ioctl_write_read.isra.41+0xcb0/0xcb0 [ 18.930847] ? avc_ss_reset+0x110/0x110 [ 18.930852] ? mutex_unlock+0xd/0x10 [ 18.930857] ? SyS_epoll_ctl+0x30a/0x1ab0 [ 18.930876] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 18.930880] ? up_read+0x1a/0x40 [ 18.930887] ? rcu_note_context_switch+0x710/0x710 [ 18.930893] ? __fd_install+0x288/0x740 [ 18.930902] ? binder_ioctl_write_read.isra.41+0xcb0/0xcb0 [ 18.930908] ? do_vfs_ioctl+0x486/0x1520 [ 18.930913] ? _cond_resched+0x14/0x30 [ 18.930922] ? ioctl_preallocate+0x2b0/0x2b0 [ 18.930928] ? selinux_capable+0x40/0x40 [ 18.930935] ? __alloc_fd+0x750/0x750 [ 18.930943] do_group_exit+0x149/0x400 [ 18.930950] ? SyS_exit+0x30/0x30 [ 18.930956] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 18.930964] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 18.930971] SyS_exit_group+0x1d/0x20 [ 18.930977] entry_SYSCALL_64_fastpath+0x1f/0x96 [ 18.930982] RIP: 0033:0x4429f8 [ 18.930985] RSP: 002b:00007ffc341938f8 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7 [ 18.930991] RAX: ffffffffffffffda RBX: 00000000004002e0 RCX: 00000000004429f8 [ 18.930995] RDX: 0000000000000000 RSI: 000000000000003c RDI: 0000000000000000 [ 18.930998] RBP: 00000000006ce018 R08: 00000000000000e7 R09: ffffffffffffffd0 [ 18.931005] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000401a40 [ 18.931008] R13: 0000000000401ad0 R14: 0000000000000000 R15: 0000000000000000 [ 18.931016] [ 18.931019] Allocated by task 3143: [ 18.931024] save_stack+0x43/0xd0 [ 18.931028] kasan_kmalloc+0xad/0xe0 [ 18.931036] kmem_cache_alloc_trace+0x136/0x750 [ 18.931041] binder_get_thread+0x1cf/0x870 [ 18.931046] binder_poll+0x8c/0x390 [ 18.931050] ep_item_poll.isra.10+0xec/0x320 [ 18.931054] ep_insert+0x6a3/0x1b10 [ 18.931059] SyS_epoll_ctl+0x12e4/0x1ab0 [ 18.931064] entry_SYSCALL_64_fastpath+0x1f/0x96 [ 18.931065] [ 18.931067] Freed by task 3143: [ 18.931071] save_stack+0x43/0xd0 [ 18.931075] kasan_slab_free+0x71/0xc0 [ 18.931080] kfree+0xd6/0x260 [ 18.931085] binder_thread_dec_tmpref+0x27f/0x310 [ 18.931090] binder_thread_release+0x27d/0x540 [ 18.931094] binder_ioctl+0xc02/0x1417 [ 18.931099] do_vfs_ioctl+0x1b1/0x1520 [ 18.931104] SyS_ioctl+0x8f/0xc0 [ 18.931109] entry_SYSCALL_64_fastpath+0x1f/0x96 [ 18.931110] [ 18.931114] The buggy address belongs to the object at ffff8801ca50d5c0 [ 18.931114] which belongs to the cache kmalloc-512 of size 512 [ 18.931119] The buggy address is located 176 bytes inside of [ 18.931119] 512-byte region [ffff8801ca50d5c0, ffff8801ca50d7c0) [ 18.931121] The buggy address belongs to the page: [ 18.931126] page:000000002731dd32 count:1 mapcount:0 mapping:0000000023e23a81 index:0x0 [ 18.931131] flags: 0x2fffc0000000100(slab) [ 18.931139] raw: 02fffc0000000100 ffff8801ca50d0c0 0000000000000000 0000000100000006 [ 18.931146] raw: ffffea000722e060 ffffea0007201e20 ffff8801db000940 0000000000000000 [ 18.931148] page dumped because: kasan: bad access detected [ 18.931149] [ 18.931151] Memory state around the buggy address: [ 18.931155] ffff8801ca50d500: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 18.931160] ffff8801ca50d580: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb [ 18.931164] >ffff8801ca50d600: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 18.931166] ^ [ 18.931171] ffff8801ca50d680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 18.931175] ffff8801ca50d700: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 18.931176] ================================================================== [ 18.931178] Disabling lock debugging due to kernel taint [ 18.931181] Kernel panic - not syncing: panic_on_warn set ... [ 18.931181] [ 18.931187] CPU: 0 PID: 3143 Comm: syzkaller810424 Tainted: G B 4.15.0-rc4+ #234 [ 18.931190] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 18.931192] Call Trace: [ 18.931198] dump_stack+0x194/0x257 [ 18.931204] ? arch_local_irq_restore+0x53/0x53 [ 18.931209] ? kasan_end_report+0x32/0x50 [ 18.931215] ? lock_downgrade+0x980/0x980 [ 18.931221] ? vsnprintf+0x1ed/0x1900 [ 18.931227] ? __lock_acquire+0x3cf0/0x3e00 [ 18.931232] panic+0x1e4/0x41c [ 18.931238] ? refcount_error_report+0x214/0x214 [ 18.931245] ? add_taint+0x40/0x50 [ 18.931249] ? add_taint+0x1c/0x50 [ 18.931256] ? __lock_acquire+0x3d4d/0x3e00 [ 18.931261] kasan_end_report+0x50/0x50 [ 18.931267] kasan_report+0x144/0x340 [ 18.931275] __asan_report_load8_noabort+0x14/0x20 [ 18.931280] __lock_acquire+0x3d4d/0x3e00 [ 18.931286] ? __lock_acquire+0x664/0x3e00 [ 18.931291] ? lock_downgrade+0x980/0x980 [ 18.931296] ? lock_downgrade+0x980/0x980 [ 18.931303] ? remove_wait_queue+0x81/0x350 [ 18.931312] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 18.931318] ? __lock_acquire+0x664/0x3e00 [ 18.931323] ? check_noncircular+0x20/0x20 [ 18.931335] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 18.931341] ? lock_acquire+0x1d5/0x580 [ 18.931346] ? lock_acquire+0x1d5/0x580 [ 18.931351] ? ep_free+0xf4/0x320 [ 18.931359] ? lock_release+0xa40/0xa40 [ 18.931365] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 18.931371] ? print_irqtrace_events+0x270/0x270 [ 18.931377] ? rcu_note_context_switch+0x710/0x710 [ 18.931384] ? __might_sleep+0x95/0x190 [ 18.931389] ? ep_free+0xf4/0x320 [ 18.931394] ? __mutex_lock+0x16f/0x1a80 [ 18.931398] ? ep_free+0xf4/0x320 [ 18.931405] ? print_irqtrace_events+0x270/0x270 [ 18.931409] ? ep_free+0xf4/0x320 [ 18.931417] lock_acquire+0x1d5/0x580 [ 18.931422] ? lock_acquire+0x1d5/0x580 [ 18.931427] ? remove_wait_queue+0x81/0x350 [ 18.931433] ? __lock_acquire+0x664/0x3e00 [ 18.931440] ? lock_release+0xa40/0xa40 [ 18.931449] ? lock_acquire+0x1d5/0x580 [ 18.931454] ? lock_acquire+0x1d5/0x580 [ 18.931459] ? ep_unregister_pollwait.isra.7+0x323/0x590 [ 18.931466] _raw_spin_lock_irqsave+0x96/0xc0 [ 18.931471] ? remove_wait_queue+0x81/0x350 [ 18.931478] remove_wait_queue+0x81/0x350 [ 18.931485] ? add_wait_queue+0x290/0x290 [ 18.931490] ? rcutorture_record_progress+0x10/0x10 [ 18.931499] ep_unregister_pollwait.isra.7+0x18c/0x590 [ 18.931506] ? __kernel_text_address+0xd/0x40 [ 18.931513] ? clear_tfile_check_list+0x370/0x370 [ 18.931520] ? check_noncircular+0x20/0x20 [ 18.931527] ? locks_remove_file+0x3fa/0x5a0 [ 18.931535] ep_free+0x13f/0x320 [ 18.931541] ? ep_remove+0x800/0x800 [ 18.931547] ? fsnotify_first_mark+0x2b0/0x2b0 [ 18.931554] ? ep_free+0x320/0x320 [ 18.931559] ep_eventpoll_release+0x44/0x60 [ 18.931565] __fput+0x327/0x7e0 [ 18.931572] ? fput+0x140/0x140 [ 18.931582] ? _raw_spin_unlock_irq+0x27/0x70 [ 18.931590] ____fput+0x15/0x20 [ 18.931596] task_work_run+0x199/0x270 [ 18.931603] ? task_work_cancel+0x210/0x210 [ 18.931609] ? _raw_spin_unlock+0x22/0x30 [ 18.931615] ? switch_task_namespaces+0x87/0xc0 [ 18.931622] do_exit+0x9bb/0x1ad0 [ 18.931629] ? binder_ioctl+0x4d1/0x1417 [ 18.931635] ? mm_update_next_owner+0x930/0x930 [ 18.931642] ? binder_ioctl_write_read.isra.41+0xcb0/0xcb0 [ 18.931651] ? avc_ss_reset+0x110/0x110 [ 18.931656] ? mutex_unlock+0xd/0x10 [ 18.931661] ? SyS_epoll_ctl+0x30a/0x1ab0 [ 18.931679] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 18.931683] ? up_read+0x1a/0x40 [ 18.931690] ? rcu_note_context_switch+0x710/0x710 [ 18.931695] ? __fd_install+0x288/0x740 [ 18.931704] ? binder_ioctl_write_read.isra.41+0xcb0/0xcb0 [ 18.931710] ? do_vfs_ioctl+0x486/0x1520 [ 18.931715] ? _cond_resched+0x14/0x30 [ 18.931723] ? ioctl_preallocate+0x2b0/0x2b0 [ 18.931730] ? selinux_capable+0x40/0x40 [ 18.931736] ? __alloc_fd+0x750/0x750 [ 18.931744] do_group_exit+0x149/0x400 [ 18.931750] ? SyS_exit+0x30/0x30 [ 18.931757] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 18.931763] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 18.931770] SyS_exit_group+0x1d/0x20 [ 18.931777] entry_SYSCALL_64_fastpath+0x1f/0x96 [ 18.931780] RIP: 0033:0x4429f8 [ 18.931783] RSP: 002b:00007ffc341938f8 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7 [ 18.931788] RAX: ffffffffffffffda RBX: 00000000004002e0 RCX: 00000000004429f8 [ 18.931791] RDX: 0000000000000000 RSI: 000000000000003c RDI: 0000000000000000 [ 18.931795] RBP: 00000000006ce018 R08: 00000000000000e7 R09: ffffffffffffffd0 [ 18.931798] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000401a40 [ 18.931801] R13: 0000000000401ad0 R14: 0000000000000000 R15: 0000000000000000 [ 18.952067] Dumping ftrace buffer: [ 18.952070] (ftrace buffer empty) [ 18.952072] Kernel Offset: disabled [ 20.075876] Rebooting in 86400 seconds..