[....] Starting enhanced syslogd: rsyslogd[ 11.050371] audit: type=1400 audit(1513825434.724:5): avc: denied { syslog } for pid=2992 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 syzkaller login: [ 16.869270] audit: type=1400 audit(1513825440.543:6): avc: denied { map } for pid=3131 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-next-kasan-gce-3,10.128.0.60' (ECDSA) to the list of known hosts. executing program [ 29.392560] audit: type=1400 audit(1513825453.066:7): avc: denied { map } for pid=3147 comm="syzkaller643123" path="/root/syzkaller643123576" 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 [ 29.395823] ================================================================== [ 29.395833] BUG: KASAN: use-after-free in __lock_acquire+0x3d4d/0x3e00 [ 29.395837] Read of size 8 at addr ffff8801cf36a5f8 by task syzkaller643123/3147 [ 29.395838] [ 29.395843] CPU: 0 PID: 3147 Comm: syzkaller643123 Not tainted 4.15.0-rc4-next-20171220+ #77 [ 29.395845] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 29.395846] Call Trace: [ 29.395852] dump_stack+0x194/0x257 [ 29.395857] ? arch_local_irq_restore+0x53/0x53 [ 29.395861] ? show_regs_print_info+0x18/0x18 [ 29.395865] ? print_irqtrace_events+0x270/0x270 [ 29.395868] ? __lock_acquire+0x664/0x3e00 [ 29.395872] ? __lock_acquire+0x3d4d/0x3e00 [ 29.395878] print_address_description+0x73/0x250 [ 29.395882] ? __lock_acquire+0x3d4d/0x3e00 [ 29.395886] kasan_report+0x25b/0x340 [ 29.395890] __asan_report_load8_noabort+0x14/0x20 [ 29.395894] __lock_acquire+0x3d4d/0x3e00 [ 29.395897] ? __lock_acquire+0x664/0x3e00 [ 29.395900] ? lock_downgrade+0x980/0x980 [ 29.395904] ? lock_downgrade+0x980/0x980 [ 29.395910] ? remove_wait_queue+0x81/0x350 [ 29.395915] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 29.395919] ? __lock_acquire+0x664/0x3e00 [ 29.395923] ? check_noncircular+0x20/0x20 [ 29.395930] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 29.395935] ? lock_acquire+0x1d5/0x580 [ 29.395938] ? lock_acquire+0x1d5/0x580 [ 29.395943] ? ep_free+0xf4/0x320 [ 29.395948] ? lock_release+0xa40/0xa40 [ 29.395954] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 29.395958] ? print_irqtrace_events+0x270/0x270 [ 29.395964] ? rcu_note_context_switch+0x710/0x710 [ 29.395968] ? __might_sleep+0x95/0x190 [ 29.395972] ? ep_free+0xf4/0x320 [ 29.395977] ? __mutex_lock+0x16f/0x1a80 [ 29.395979] ? ep_free+0xf4/0x320 [ 29.395984] ? print_irqtrace_events+0x270/0x270 [ 29.395987] ? ep_free+0xf4/0x320 [ 29.395992] lock_acquire+0x1d5/0x580 [ 29.395995] ? lock_acquire+0x1d5/0x580 [ 29.395998] ? remove_wait_queue+0x81/0x350 [ 29.396005] ? __lock_acquire+0x664/0x3e00 [ 29.396010] ? lock_release+0xa40/0xa40 [ 29.396016] ? lock_acquire+0x1d5/0x580 [ 29.396019] ? lock_acquire+0x1d5/0x580 [ 29.396023] ? ep_unregister_pollwait.isra.7+0x323/0x590 [ 29.396027] _raw_spin_lock_irqsave+0x96/0xc0 [ 29.396031] ? remove_wait_queue+0x81/0x350 [ 29.396035] remove_wait_queue+0x81/0x350 [ 29.396039] ? add_wait_queue+0x290/0x290 [ 29.396043] ? rcutorture_record_progress+0x10/0x10 [ 29.396049] ep_unregister_pollwait.isra.7+0x18c/0x590 [ 29.396054] ? __kernel_text_address+0xd/0x40 [ 29.396059] ? clear_tfile_check_list+0x370/0x370 [ 29.396063] ? check_noncircular+0x20/0x20 [ 29.396069] ? locks_remove_file+0x3fa/0x5a0 [ 29.396074] ep_free+0x13f/0x320 [ 29.396078] ? ep_remove+0x800/0x800 [ 29.396082] ? fsnotify_first_mark+0x2b0/0x2b0 [ 29.396086] ? ep_free+0x320/0x320 [ 29.396090] ep_eventpoll_release+0x44/0x60 [ 29.396094] __fput+0x327/0x7e0 [ 29.396099] ? fput+0x140/0x140 [ 29.396103] ? _raw_spin_unlock_irq+0x27/0x70 [ 29.396108] ____fput+0x15/0x20 [ 29.396112] task_work_run+0x199/0x270 [ 29.396116] ? task_work_cancel+0x210/0x210 [ 29.396120] ? _raw_spin_unlock+0x22/0x30 [ 29.396123] ? switch_task_namespaces+0x87/0xc0 [ 29.396129] do_exit+0x9bb/0x1ad0 [ 29.396136] ? binder_ioctl+0x551/0x1417 [ 29.396139] ? mm_update_next_owner+0x930/0x930 [ 29.396144] ? binder_ioctl_write_read.isra.38+0xcb0/0xcb0 [ 29.396151] ? avc_ss_reset+0x110/0x110 [ 29.396154] ? mutex_unlock+0xd/0x10 [ 29.396158] ? SyS_epoll_ctl+0x30a/0x1a80 [ 29.396170] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 29.396173] ? up_read+0x1a/0x40 [ 29.396177] ? rcu_note_context_switch+0x710/0x710 [ 29.396181] ? __fd_install+0x288/0x740 [ 29.396186] ? binder_ioctl_write_read.isra.38+0xcb0/0xcb0 [ 29.396190] ? do_vfs_ioctl+0x486/0x1520 [ 29.396193] ? _cond_resched+0x14/0x30 [ 29.396198] ? ioctl_preallocate+0x2b0/0x2b0 [ 29.396202] ? selinux_capable+0x40/0x40 [ 29.396206] ? __alloc_fd+0x750/0x750 [ 29.396211] do_group_exit+0x149/0x400 [ 29.396215] ? SyS_exit+0x30/0x30 [ 29.396219] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 29.396225] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 29.396229] SyS_exit_group+0x1d/0x20 [ 29.396233] entry_SYSCALL_64_fastpath+0x1f/0x96 [ 29.396236] RIP: 0033:0x4429f8 [ 29.396238] RSP: 002b:00007ffc7c172088 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7 [ 29.396242] RAX: ffffffffffffffda RBX: 00000000004002e0 RCX: 00000000004429f8 [ 29.396244] RDX: 0000000000000000 RSI: 000000000000003c RDI: 0000000000000000 [ 29.396246] RBP: 00000000006ce018 R08: 00000000000000e7 R09: ffffffffffffffd0 [ 29.396248] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000401a40 [ 29.396250] R13: 0000000000401ad0 R14: 0000000000000000 R15: 0000000000000000 [ 29.396256] [ 29.396257] Allocated by task 3147: [ 29.396261] save_stack+0x43/0xd0 [ 29.396264] kasan_kmalloc+0xad/0xe0 [ 29.396267] kmem_cache_alloc_trace+0x136/0x750 [ 29.396270] binder_get_thread+0x1cf/0x870 [ 29.396272] binder_poll+0x8c/0x390 [ 29.396275] ep_item_poll.isra.10+0xf2/0x320 [ 29.396278] ep_insert+0x6a2/0x1ac0 [ 29.396280] SyS_epoll_ctl+0x12bf/0x1a80 [ 29.396283] entry_SYSCALL_64_fastpath+0x1f/0x96 [ 29.396284] [ 29.396285] Freed by task 3147: [ 29.396288] save_stack+0x43/0xd0 [ 29.396291] kasan_slab_free+0x71/0xc0 [ 29.396293] kfree+0xd6/0x260 [ 29.396297] binder_thread_dec_tmpref+0x27f/0x310 [ 29.396299] binder_thread_release+0x27d/0x540 [ 29.396302] binder_ioctl+0xc02/0x1417 [ 29.396304] do_vfs_ioctl+0x1b1/0x1520 [ 29.396307] SyS_ioctl+0x8f/0xc0 [ 29.396310] entry_SYSCALL_64_fastpath+0x1f/0x96 [ 29.396310] [ 29.396313] The buggy address belongs to the object at ffff8801cf36a540 [ 29.396313] which belongs to the cache kmalloc-512 of size 512 [ 29.396316] The buggy address is located 184 bytes inside of [ 29.396316] 512-byte region [ffff8801cf36a540, ffff8801cf36a740) [ 29.396317] The buggy address belongs to the page: [ 29.396320] page:00000000ef2321e1 count:1 mapcount:0 mapping:000000007b47b691 index:0x0 [ 29.396324] flags: 0x2fffc0000000100(slab) [ 29.396330] raw: 02fffc0000000100 ffff8801cf36a040 0000000000000000 0000000100000006 [ 29.396334] raw: ffffea00073cc0e0 ffffea00073cdb60 ffff8801dac00940 0000000000000000 [ 29.396335] page dumped because: kasan: bad access detected [ 29.396336] [ 29.396337] Memory state around the buggy address: [ 29.396340] ffff8801cf36a480: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc [ 29.396342] ffff8801cf36a500: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb [ 29.396345] >ffff8801cf36a580: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 29.396346] ^ [ 29.396349] ffff8801cf36a600: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 29.396351] ffff8801cf36a680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 29.396352] ================================================================== [ 29.396353] Disabling lock debugging due to kernel taint [ 29.396355] Kernel panic - not syncing: panic_on_warn set ... [ 29.396355] [ 29.396359] CPU: 0 PID: 3147 Comm: syzkaller643123 Tainted: G B 4.15.0-rc4-next-20171220+ #77 [ 29.396361] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 29.396362] Call Trace: [ 29.396366] dump_stack+0x194/0x257 [ 29.396369] ? arch_local_irq_restore+0x53/0x53 [ 29.396373] ? kasan_end_report+0x32/0x50 [ 29.396376] ? lock_downgrade+0x980/0x980 [ 29.396380] ? vsnprintf+0x1ed/0x1900 [ 29.396383] ? __lock_acquire+0x3d30/0x3e00 [ 29.396387] panic+0x1e4/0x41c [ 29.396390] ? refcount_error_report+0x214/0x214 [ 29.396394] ? add_taint+0x40/0x50 [ 29.396397] ? add_taint+0x1c/0x50 [ 29.396401] ? __lock_acquire+0x3d4d/0x3e00 [ 29.396405] kasan_end_report+0x50/0x50 [ 29.396408] kasan_report+0x144/0x340 [ 29.396413] __asan_report_load8_noabort+0x14/0x20 [ 29.396416] __lock_acquire+0x3d4d/0x3e00 [ 29.396419] ? __lock_acquire+0x664/0x3e00 [ 29.396422] ? lock_downgrade+0x980/0x980 [ 29.396425] ? lock_downgrade+0x980/0x980 [ 29.396430] ? remove_wait_queue+0x81/0x350 [ 29.396435] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 29.396438] ? __lock_acquire+0x664/0x3e00 [ 29.396441] ? check_noncircular+0x20/0x20 [ 29.396448] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 29.396452] ? lock_acquire+0x1d5/0x580 [ 29.396455] ? lock_acquire+0x1d5/0x580 [ 29.396458] ? ep_free+0xf4/0x320 [ 29.396463] ? lock_release+0xa40/0xa40 [ 29.396466] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 29.396470] ? print_irqtrace_events+0x270/0x270 [ 29.396474] ? rcu_note_context_switch+0x710/0x710 [ 29.396478] ? __might_sleep+0x95/0x190 [ 29.396481] ? ep_free+0xf4/0x320 [ 29.396485] ? __mutex_lock+0x16f/0x1a80 [ 29.396487] ? ep_free+0xf4/0x320 [ 29.396491] ? print_irqtrace_events+0x270/0x270 [ 29.396494] ? ep_free+0xf4/0x320 [ 29.396499] lock_acquire+0x1d5/0x580 [ 29.396502] ? lock_acquire+0x1d5/0x580 [ 29.396505] ? remove_wait_queue+0x81/0x350 [ 29.396508] ? __lock_acquire+0x664/0x3e00 [ 29.396513] ? lock_release+0xa40/0xa40 [ 29.396518] ? lock_acquire+0x1d5/0x580 [ 29.396520] ? lock_acquire+0x1d5/0x580 [ 29.396524] ? ep_unregister_pollwait.isra.7+0x323/0x590 [ 29.396528] _raw_spin_lock_irqsave+0x96/0xc0 [ 29.396531] ? remove_wait_queue+0x81/0x350 [ 29.396535] remove_wait_queue+0x81/0x350 [ 29.396539] ? add_wait_queue+0x290/0x290 [ 29.396543] ? rcutorture_record_progress+0x10/0x10 [ 29.396548] ep_unregister_pollwait.isra.7+0x18c/0x590 [ 29.396552] ? __kernel_text_address+0xd/0x40 [ 29.396556] ? clear_tfile_check_list+0x370/0x370 [ 29.396561] ? check_noncircular+0x20/0x20 [ 29.396565] ? locks_remove_file+0x3fa/0x5a0 [ 29.396570] ep_free+0x13f/0x320 [ 29.396574] ? ep_remove+0x800/0x800 [ 29.396577] ? fsnotify_first_mark+0x2b0/0x2b0 [ 29.396581] ? ep_free+0x320/0x320 [ 29.396584] ep_eventpoll_release+0x44/0x60 [ 29.396588] __fput+0x327/0x7e0 [ 29.396592] ? fput+0x140/0x140 [ 29.396596] ? _raw_spin_unlock_irq+0x27/0x70 [ 29.396600] ____fput+0x15/0x20 [ 29.396604] task_work_run+0x199/0x270 [ 29.396608] ? task_work_cancel+0x210/0x210 [ 29.396612] ? _raw_spin_unlock+0x22/0x30 [ 29.396615] ? switch_task_namespaces+0x87/0xc0 [ 29.396619] do_exit+0x9bb/0x1ad0 [ 29.396623] ? binder_ioctl+0x551/0x1417 [ 29.396627] ? mm_update_next_owner+0x930/0x930 [ 29.396631] ? binder_ioctl_write_read.isra.38+0xcb0/0xcb0 [ 29.396635] ? avc_ss_reset+0x110/0x110 [ 29.396639] ? mutex_unlock+0xd/0x10 [ 29.396642] ? SyS_epoll_ctl+0x30a/0x1a80 [ 29.396652] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 29.396659] ? up_read+0x1a/0x40 [ 29.396663] ? rcu_note_context_switch+0x710/0x710 [ 29.396666] ? __fd_install+0x288/0x740 [ 29.396671] ? binder_ioctl_write_read.isra.38+0xcb0/0xcb0 [ 29.396674] ? do_vfs_ioctl+0x486/0x1520 [ 29.396677] ? _cond_resched+0x14/0x30 [ 29.396681] ? ioctl_preallocate+0x2b0/0x2b0 [ 29.396685] ? selinux_capable+0x40/0x40 [ 29.396689] ? __alloc_fd+0x750/0x750 [ 29.396693] do_group_exit+0x149/0x400 [ 29.396697] ? SyS_exit+0x30/0x30 [ 29.396701] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 29.396705] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 29.396709] SyS_exit_group+0x1d/0x20 [ 29.396713] entry_SYSCALL_64_fastpath+0x1f/0x96 [ 29.396715] RIP: 0033:0x4429f8 [ 29.396717] RSP: 002b:00007ffc7c172088 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7 [ 29.396720] RAX: ffffffffffffffda RBX: 00000000004002e0 RCX: 00000000004429f8 [ 29.396722] RDX: 0000000000000000 RSI: 000000000000003c RDI: 0000000000000000 [ 29.396724] RBP: 00000000006ce018 R08: 00000000000000e7 R09: ffffffffffffffd0 [ 29.396726] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000401a40 [ 29.396728] R13: 0000000000401ad0 R14: 0000000000000000 R15: 0000000000000000 [ 29.418789] Dumping ftrace buffer: [ 29.418791] (ftrace buffer empty) [ 29.418793] Kernel Offset: disabled [ 30.546324] Rebooting in 86400 seconds..