syzkaller login: [ 40.485158] audit: type=1400 audit(1569194955.725:35): avc: denied { map } for pid=7511 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.0.27' (ECDSA) to the list of known hosts. executing program [ 47.039667] audit: type=1400 audit(1569194962.285:36): avc: denied { map } for pid=7524 comm="syz-executor115" path="/root/syz-executor115566811" dev="sda1" ino=16483 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:user_home_t:s0 tclass=file permissive=1 [ 47.076022] ================================================================== [ 47.083777] BUG: KASAN: use-after-free in wait_consider_task+0x1b51/0x3910 [ 47.090804] Read of size 4 at addr ffff88808a4628ac by task syz-executor115/7524 [ 47.098318] [ 47.099937] CPU: 1 PID: 7524 Comm: syz-executor115 Not tainted 4.19.75 #0 [ 47.106845] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 47.116394] Call Trace: [ 47.118997] dump_stack+0x172/0x1f0 [ 47.122695] ? wait_consider_task+0x1b51/0x3910 [ 47.127429] print_address_description.cold+0x7c/0x20d [ 47.132727] ? wait_consider_task+0x1b51/0x3910 [ 47.137402] kasan_report.cold+0x8c/0x2ba [ 47.141546] __asan_report_load4_noabort+0x14/0x20 [ 47.146466] wait_consider_task+0x1b51/0x3910 [ 47.150949] ? lockdep_hardirqs_on+0x415/0x5d0 [ 47.155529] ? _raw_spin_unlock_irqrestore+0x6b/0xe0 [ 47.160620] ? add_wait_queue+0x112/0x170 [ 47.164775] ? release_task+0x1630/0x1630 [ 47.168923] ? lock_acquire+0x16f/0x3f0 [ 47.172897] ? do_wait+0x3aa/0x9d0 [ 47.176426] ? kasan_check_write+0x14/0x20 [ 47.180661] do_wait+0x439/0x9d0 [ 47.184039] ? wait_consider_task+0x3910/0x3910 [ 47.188714] kernel_wait4+0x171/0x290 [ 47.192503] ? __ia32_sys_waitid+0x140/0x140 [ 47.196940] ? task_stopped_code+0x180/0x180 [ 47.201375] __do_sys_wait4+0x147/0x160 [ 47.205347] ? kernel_wait4+0x290/0x290 [ 47.209311] ? _copy_to_user+0xc9/0x120 [ 47.213275] ? __sanitizer_cov_trace_const_cmp8+0x18/0x20 [ 47.218798] ? put_timespec64+0xda/0x140 [ 47.222860] ? nsecs_to_jiffies+0x30/0x30 [ 47.227207] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 47.232104] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 47.236853] ? do_syscall_64+0x26/0x620 [ 47.240830] ? entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 47.246222] ? do_syscall_64+0x26/0x620 [ 47.250194] __x64_sys_wait4+0x97/0xf0 [ 47.254096] do_syscall_64+0xfd/0x620 [ 47.257889] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 47.263067] RIP: 0033:0x4012fa [ 47.266250] Code: c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 8b 05 fe 13 2d 00 85 c0 75 36 45 31 d2 48 63 d2 48 63 ff b8 3d 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 06 c3 0f 1f 44 00 00 48 c7 c2 d0 ff ff ff f7 [ 47.285846] RSP: 002b:00007ffc999a6f48 EFLAGS: 00000246 ORIG_RAX: 000000000000003d [ 47.294169] RAX: ffffffffffffffda RBX: 0000000000001d65 RCX: 00000000004012fa [ 47.301533] RDX: 0000000040000001 RSI: 00007ffc999a6f54 RDI: ffffffffffffffff [ 47.308794] RBP: 000000000000b7aa R08: 0000000000000000 R09: 000055555569a880 [ 47.316067] R10: 0000000000000000 R11: 0000000000000246 R12: 00000000004022b0 [ 47.323322] R13: 0000000000402340 R14: 0000000000000000 R15: 0000000000000000 [ 47.331098] [ 47.332715] Allocated by task 7524: [ 47.336331] save_stack+0x45/0xd0 [ 47.339770] kasan_kmalloc+0xce/0xf0 [ 47.343566] kasan_slab_alloc+0xf/0x20 [ 47.347702] kmem_cache_alloc_node+0x144/0x710 [ 47.352427] copy_process.part.0+0x1ce0/0x7a30 [ 47.357150] _do_fork+0x257/0xfd0 [ 47.360709] __x64_sys_clone+0xbf/0x150 [ 47.364780] do_syscall_64+0xfd/0x620 [ 47.368572] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 47.373741] [ 47.375371] Freed by task 0: [ 47.378379] save_stack+0x45/0xd0 [ 47.381905] __kasan_slab_free+0x102/0x150 [ 47.386139] kasan_slab_free+0xe/0x10 [ 47.389954] kmem_cache_free+0x86/0x260 [ 47.393908] free_task+0xdd/0x120 [ 47.397345] __put_task_struct+0x20f/0x4c0 [ 47.401564] finish_task_switch+0x52b/0x780 [ 47.405869] __schedule+0x86e/0x1dc0 [ 47.409573] schedule_idle+0x58/0x80 [ 47.413309] do_idle+0x192/0x560 [ 47.416683] cpu_startup_entry+0xc8/0xe0 [ 47.420769] start_secondary+0x3e8/0x5b0 [ 47.424816] secondary_startup_64+0xa4/0xb0 [ 47.429812] [ 47.431442] The buggy address belongs to the object at ffff88808a462440 [ 47.431442] which belongs to the cache task_struct of size 6080 [ 47.444325] The buggy address is located 1132 bytes inside of [ 47.444325] 6080-byte region [ffff88808a462440, ffff88808a463c00) [ 47.456364] The buggy address belongs to the page: [ 47.461292] page:ffffea0002291880 count:1 mapcount:0 mapping:ffff88812c26d800 index:0x0 compound_mapcount: 0 [ 47.472320] flags: 0x1fffc0000008100(slab|head) [ 47.476984] raw: 01fffc0000008100 ffffea0002294308 ffffea00022d0488 ffff88812c26d800 [ 47.484857] raw: 0000000000000000 ffff88808a462440 0000000100000001 0000000000000000 [ 47.492718] page dumped because: kasan: bad access detected [ 47.498415] [ 47.500039] Memory state around the buggy address: [ 47.504983] ffff88808a462780: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 47.512953] ffff88808a462800: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 47.520301] >ffff88808a462880: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 47.527653] ^ [ 47.532376] ffff88808a462900: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 47.539949] ffff88808a462980: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 47.547579] ================================================================== [ 47.554932] Disabling lock debugging due to kernel taint [ 47.560525] Kernel panic - not syncing: panic_on_warn set ... [ 47.560525] [ 47.567985] CPU: 1 PID: 7524 Comm: syz-executor115 Tainted: G B 4.19.75 #0 [ 47.576680] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 47.586030] Call Trace: [ 47.588610] dump_stack+0x172/0x1f0 [ 47.592239] ? wait_consider_task+0x1b51/0x3910 [ 47.597010] panic+0x263/0x507 [ 47.600280] ? __warn_printk+0xf3/0xf3 [ 47.604241] ? retint_kernel+0x2d/0x2d [ 47.608137] ? trace_hardirqs_on+0x5e/0x220 [ 47.612536] ? wait_consider_task+0x1b51/0x3910 [ 47.617190] kasan_end_report+0x47/0x4f [ 47.621150] kasan_report.cold+0xa9/0x2ba [ 47.625290] __asan_report_load4_noabort+0x14/0x20 [ 47.630209] wait_consider_task+0x1b51/0x3910 [ 47.634691] ? lockdep_hardirqs_on+0x415/0x5d0 [ 47.639317] ? _raw_spin_unlock_irqrestore+0x6b/0xe0 [ 47.644435] ? add_wait_queue+0x112/0x170 [ 47.648668] ? release_task+0x1630/0x1630 [ 47.652826] ? lock_acquire+0x16f/0x3f0 [ 47.656783] ? do_wait+0x3aa/0x9d0 [ 47.660323] ? kasan_check_write+0x14/0x20 [ 47.664544] do_wait+0x439/0x9d0 [ 47.667895] ? wait_consider_task+0x3910/0x3910 [ 47.672662] kernel_wait4+0x171/0x290 [ 47.676452] ? __ia32_sys_waitid+0x140/0x140 [ 47.680857] ? task_stopped_code+0x180/0x180 [ 47.685288] __do_sys_wait4+0x147/0x160 [ 47.689247] ? kernel_wait4+0x290/0x290 [ 47.693207] ? _copy_to_user+0xc9/0x120 [ 47.697169] ? __sanitizer_cov_trace_const_cmp8+0x18/0x20 [ 47.702690] ? put_timespec64+0xda/0x140 [ 47.706744] ? nsecs_to_jiffies+0x30/0x30 [ 47.710883] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 47.715635] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 47.720388] ? do_syscall_64+0x26/0x620 [ 47.724780] ? entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 47.730241] ? do_syscall_64+0x26/0x620 [ 47.734201] __x64_sys_wait4+0x97/0xf0 [ 47.738246] do_syscall_64+0xfd/0x620 [ 47.742034] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 47.747214] RIP: 0033:0x4012fa [ 47.750404] Code: c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 8b 05 fe 13 2d 00 85 c0 75 36 45 31 d2 48 63 d2 48 63 ff b8 3d 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 06 c3 0f 1f 44 00 00 48 c7 c2 d0 ff ff ff f7 [ 47.769563] RSP: 002b:00007ffc999a6f48 EFLAGS: 00000246 ORIG_RAX: 000000000000003d [ 47.777274] RAX: ffffffffffffffda RBX: 0000000000001d65 RCX: 00000000004012fa [ 47.784546] RDX: 0000000040000001 RSI: 00007ffc999a6f54 RDI: ffffffffffffffff [ 47.791836] RBP: 000000000000b7aa R08: 0000000000000000 R09: 000055555569a880 [ 47.799185] R10: 0000000000000000 R11: 0000000000000246 R12: 00000000004022b0 [ 47.806626] R13: 0000000000402340 R14: 0000000000000000 R15: 0000000000000000 [ 47.815602] Kernel Offset: disabled [ 47.819233] Rebooting in 86400 seconds..