[?25l[?1c7[ ok 8[?25h[?0c. Starting mcstransd: [....] Starting periodic command scheduler: cron[?25l[?1c7[ ok 8[?25h[?0c. [....] Starting OpenBSD Secure Shell server: sshd[?25l[?1c7[ ok 8[?25h[?0c. [....] Starting file context maintaining daemon: restorecond[?25l[?1c7[ ok 8[?25h[?0c. [ 11.411798] audit: type=1400 audit(1515106810.369:6): avc: denied { map } for pid=3446 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 Debian GNU/Linux 7 syzkaller ttyS0 Warning: Permanently added '10.128.15.214' (ECDSA) to the list of known hosts. executing program syzkaller login: [ 41.779671] audit: type=1400 audit(1515106840.737:7): avc: denied { map } for pid=3465 comm="syzkaller892805" path="/root/syzkaller892805343" 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 [ 41.785308] ================================================================== [ 41.785322] BUG: KASAN: use-after-free in __lock_acquire+0x3c41/0x3cf0 [ 41.785326] Read of size 8 at addr ffff8801c856d5b8 by task syzkaller892805/3465 [ 41.785327] [ 41.785333] CPU: 1 PID: 3465 Comm: syzkaller892805 Not tainted 4.15.0-rc6-mm1+ #50 [ 41.785335] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 41.785337] Call Trace: [ 41.785346] dump_stack+0x137/0x198 [ 41.785350] ? __lock_acquire+0x3c41/0x3cf0 [ 41.785359] print_address_description+0x73/0x250 [ 41.785363] ? __lock_acquire+0x3c41/0x3cf0 [ 41.785367] kasan_report+0x23b/0x360 [ 41.785371] __asan_report_load8_noabort+0x14/0x20 [ 41.785375] __lock_acquire+0x3c41/0x3cf0 [ 41.785382] ? bpf_prog_kallsyms_find+0x39/0x270 [ 41.785387] ? __lock_acquire+0x63e/0x3cf0 [ 41.785392] ? remove_wait_queue+0x24/0x1b0 [ 41.785398] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 41.785403] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 41.785410] ? __mutex_lock+0xec/0x1550 [ 41.785417] ? ep_free+0x72/0x230 [ 41.785420] ? save_stack+0x43/0xd0 [ 41.785424] ? __kasan_slab_free+0x11a/0x170 [ 41.785427] ? kasan_slab_free+0xe/0x10 [ 41.785431] lock_acquire+0x16b/0x420 [ 41.785435] ? lock_acquire+0x16b/0x420 [ 41.785438] ? remove_wait_queue+0x24/0x1b0 [ 41.785444] _raw_spin_lock_irqsave+0x96/0xc0 [ 41.785448] ? remove_wait_queue+0x24/0x1b0 [ 41.785451] remove_wait_queue+0x24/0x1b0 [ 41.785461] ep_unregister_pollwait.isra.7+0x9d/0x360 [ 41.785465] ? ep_free+0x230/0x230 [ 41.785468] ep_free+0xae/0x230 [ 41.785472] ? ep_free+0x230/0x230 [ 41.785476] ep_eventpoll_release+0x44/0x60 [ 41.785480] __fput+0x291/0x6e0 [ 41.785484] ____fput+0x15/0x20 [ 41.785489] task_work_run+0x122/0x1a0 [ 41.785496] do_exit+0x7f4/0x2da0 [ 41.785503] ? binder_ioctl_write_read.isra.39+0x8e0/0x8e0 [ 41.785508] ? do_vfs_ioctl+0x439/0xfe0 [ 41.785513] ? mm_update_next_owner+0x690/0x690 [ 41.785516] ? ioctl_preallocate+0x1c0/0x1c0 [ 41.785525] ? __do_page_fault+0x3c3/0xca0 [ 41.785530] ? entry_SYSCALL_64_fastpath+0x5/0x9a [ 41.785535] do_group_exit+0x108/0x320 [ 41.785539] SyS_exit_group+0x1d/0x20 [ 41.785543] entry_SYSCALL_64_fastpath+0x23/0x9a [ 41.785547] RIP: 0033:0x4429f8 [ 41.785549] RSP: 002b:00007ffc83088d38 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7 [ 41.785553] RAX: ffffffffffffffda RBX: 00000000004002e0 RCX: 00000000004429f8 [ 41.785556] RDX: 0000000000000000 RSI: 000000000000003c RDI: 0000000000000000 [ 41.785558] RBP: 00000000006ce018 R08: 00000000000000e7 R09: ffffffffffffffd0 [ 41.785560] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000401a40 [ 41.785562] R13: 0000000000401ad0 R14: 0000000000000000 R15: 0000000000000000 [ 41.785566] [ 41.785568] Allocated by task 3465: [ 41.785573] save_stack+0x43/0xd0 [ 41.785576] kasan_kmalloc+0xad/0xe0 [ 41.785579] kmem_cache_alloc_trace+0x136/0x750 [ 41.785581] binder_get_thread+0x15d/0x700 [ 41.785584] binder_poll+0x4a/0x210 [ 41.785587] ep_item_poll.isra.10+0xf2/0x320 [ 41.785591] SyS_epoll_ctl+0x11c4/0x27b0 [ 41.785594] entry_SYSCALL_64_fastpath+0x23/0x9a [ 41.785595] [ 41.785596] Freed by task 3465: [ 41.785599] save_stack+0x43/0xd0 [ 41.785602] __kasan_slab_free+0x11a/0x170 [ 41.785605] kasan_slab_free+0xe/0x10 [ 41.785608] kfree+0xd9/0x260 [ 41.785611] binder_thread_dec_tmpref+0x17d/0x1e0 [ 41.785613] binder_thread_release+0x27d/0x540 [ 41.785616] binder_ioctl+0xa1b/0x10ee [ 41.785619] do_vfs_ioctl+0x190/0xfe0 [ 41.785622] SyS_ioctl+0x8f/0xc0 [ 41.785625] entry_SYSCALL_64_fastpath+0x23/0x9a [ 41.785626] [ 41.785628] The buggy address belongs to the object at ffff8801c856d500 [ 41.785628] which belongs to the cache kmalloc-512 of size 512 [ 41.785631] The buggy address is located 184 bytes inside of [ 41.785631] 512-byte region [ffff8801c856d500, ffff8801c856d700) [ 41.785632] The buggy address belongs to the page: [ 41.785635] page:ffffea0007215b40 count:1 mapcount:0 mapping:ffff8801c856d000 index:0x0 [ 41.785639] flags: 0x2fffc0000000100(slab) [ 41.785645] raw: 02fffc0000000100 ffff8801c856d000 0000000000000000 0000000100000006 [ 41.785649] raw: ffffea00072a39e0 ffffea00072afba0 ffff8801db000940 0000000000000000 [ 41.785651] page dumped because: kasan: bad access detected [ 41.785651] [ 41.785653] Memory state around the buggy address: [ 41.785655] ffff8801c856d480: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 41.785658] ffff8801c856d500: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 41.785660] >ffff8801c856d580: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 41.785662] ^ [ 41.785664] ffff8801c856d600: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 41.785667] ffff8801c856d680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 41.785668] ================================================================== [ 41.785669] Disabling lock debugging due to kernel taint [ 41.785671] Kernel panic - not syncing: panic_on_warn set ... [ 41.785671] [ 41.785675] CPU: 1 PID: 3465 Comm: syzkaller892805 Tainted: G B 4.15.0-rc6-mm1+ #50 [ 41.785677] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 41.785678] Call Trace: [ 41.785682] dump_stack+0x137/0x198 [ 41.785686] ? __lock_acquire+0x3bc0/0x3cf0 [ 41.785690] panic+0x1e4/0x41c [ 41.785693] ? refcount_error_report+0x214/0x214 [ 41.785697] ? add_taint+0x40/0x50 [ 41.785700] ? add_taint+0x1c/0x50 [ 41.785704] ? __lock_acquire+0x3c41/0x3cf0 [ 41.785708] kasan_end_report+0x50/0x50 [ 41.785712] kasan_report+0x148/0x360 [ 41.785717] __asan_report_load8_noabort+0x14/0x20 [ 41.785720] __lock_acquire+0x3c41/0x3cf0 [ 41.785724] ? bpf_prog_kallsyms_find+0x39/0x270 [ 41.785728] ? __lock_acquire+0x63e/0x3cf0 [ 41.785732] ? remove_wait_queue+0x24/0x1b0 [ 41.785737] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 41.785742] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 41.785746] ? __mutex_lock+0xec/0x1550 [ 41.785749] ? ep_free+0x72/0x230 [ 41.785752] ? save_stack+0x43/0xd0 [ 41.785756] ? __kasan_slab_free+0x11a/0x170 [ 41.785759] ? kasan_slab_free+0xe/0x10 [ 41.785763] lock_acquire+0x16b/0x420 [ 41.785766] ? lock_acquire+0x16b/0x420 [ 41.785770] ? remove_wait_queue+0x24/0x1b0 [ 41.785775] _raw_spin_lock_irqsave+0x96/0xc0 [ 41.785778] ? remove_wait_queue+0x24/0x1b0 [ 41.785782] remove_wait_queue+0x24/0x1b0 [ 41.785787] ep_unregister_pollwait.isra.7+0x9d/0x360 [ 41.785791] ? ep_free+0x230/0x230 [ 41.785795] ep_free+0xae/0x230 [ 41.785798] ? ep_free+0x230/0x230 [ 41.785802] ep_eventpoll_release+0x44/0x60 [ 41.785805] __fput+0x291/0x6e0 [ 41.785809] ____fput+0x15/0x20 [ 41.785812] task_work_run+0x122/0x1a0 [ 41.785817] do_exit+0x7f4/0x2da0 [ 41.785820] ? binder_ioctl_write_read.isra.39+0x8e0/0x8e0 [ 41.785824] ? do_vfs_ioctl+0x439/0xfe0 [ 41.785828] ? mm_update_next_owner+0x690/0x690 [ 41.785832] ? ioctl_preallocate+0x1c0/0x1c0 [ 41.785836] ? __do_page_fault+0x3c3/0xca0 [ 41.785841] ? entry_SYSCALL_64_fastpath+0x5/0x9a [ 41.785846] do_group_exit+0x108/0x320 [ 41.785850] SyS_exit_group+0x1d/0x20 [ 41.785854] entry_SYSCALL_64_fastpath+0x23/0x9a [ 41.785856] RIP: 0033:0x4429f8 [ 41.785858] RSP: 002b:00007ffc83088d38 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7 [ 41.785861] RAX: ffffffffffffffda RBX: 00000000004002e0 RCX: 00000000004429f8 [ 41.785863] RDX: 0000000000000000 RSI: 000000000000003c RDI: 0000000000000000 [ 41.785865] RBP: 00000000006ce018 R08: 00000000000000e7 R09: ffffffffffffffd0 [ 41.785867] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000401a40 [ 41.785869] R13: 0000000000401ad0 R14: 0000000000000000 R15: 0000000000000000 [ 41.805618] Dumping ftrace buffer: [ 41.805622] (ftrace buffer empty) [ 41.805624] Kernel Offset: disabled [ 42.544014] Rebooting in 86400 seconds..