[ 45.399286] audit: type=1800 audit(1581627666.190:31): pid=8024 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:kernel_t:s0 op=collect_data cause=failed(directio) comm="startpar" name="restorecond" dev="sda1" ino=2469 res=0 [ 45.422513] audit: type=1800 audit(1581627666.190:32): pid=8024 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:kernel_t:s0 op=collect_data cause=failed(directio) comm="startpar" name="ssh" dev="sda1" ino=2450 res=0 [....] 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 Warning: Permanently added '10.128.1.28' (ECDSA) to the list of known hosts. executing program executing program executing program executing program executing program executing program executing program executing program syzkaller login: [ 71.323277] kauditd_printk_skb: 3 callbacks suppressed [ 71.323298] audit: type=1400 audit(1581627692.200:36): avc: denied { map } for pid=8210 comm="syz-executor500" path="/root/syz-executor500600538" 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 [ 71.431540] ================================================================== [ 71.431577] BUG: KASAN: use-after-free in con_shutdown+0x85/0x90 [ 71.431588] Write of size 8 at addr ffff888097af8748 by task syz-executor500/8222 [ 71.431591] [ 71.431604] CPU: 1 PID: 8222 Comm: syz-executor500 Not tainted 4.19.103-syzkaller #0 [ 71.431611] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 71.431616] Call Trace: [ 71.431633] dump_stack+0x197/0x210 [ 71.431651] ? con_shutdown+0x85/0x90 [ 71.431670] print_address_description.cold+0x7c/0x20d [ 71.431686] ? con_shutdown+0x85/0x90 [ 71.431700] kasan_report.cold+0x8c/0x2ba [ 71.431716] ? set_palette+0x1c0/0x1c0 [ 71.431735] __asan_report_store8_noabort+0x17/0x20 [ 71.431750] con_shutdown+0x85/0x90 [ 71.431765] release_tty+0xe4/0x4d0 [ 71.431783] tty_release_struct+0x3c/0x50 [ 71.431797] tty_release+0xbcb/0xe90 [ 71.431820] ? tty_release_struct+0x50/0x50 [ 71.431835] __fput+0x2dd/0x8b0 [ 71.431858] ____fput+0x16/0x20 [ 71.431874] task_work_run+0x145/0x1c0 [ 71.431894] do_exit+0xc1f/0x30d0 [ 71.431917] ? mm_update_next_owner+0x660/0x660 [ 71.431933] ? up_read+0x1a/0x110 [ 71.431948] ? __sanitizer_cov_trace_const_cmp4+0x16/0x20 [ 71.431964] ? __do_page_fault+0x484/0xe90 [ 71.431987] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 71.432000] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 71.432013] do_group_exit+0x135/0x370 [ 71.432026] __x64_sys_exit_group+0x44/0x50 [ 71.432038] do_syscall_64+0xfd/0x620 [ 71.432053] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 71.432061] RIP: 0033:0x43ff38 [ 71.432071] Code: 00 00 be 3c 00 00 00 eb 19 66 0f 1f 84 00 00 00 00 00 48 89 d7 89 f0 0f 05 48 3d 00 f0 ff ff 77 21 f4 48 89 d7 44 89 c0 0f 05 <48> 3d 00 f0 ff ff 76 e0 f7 d8 64 41 89 01 eb d8 0f 1f 84 00 00 00 [ 71.432077] RSP: 002b:00007ffcc39b35a8 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7 [ 71.432088] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 000000000043ff38 [ 71.432094] RDX: 0000000000000000 RSI: 000000000000003c RDI: 0000000000000000 [ 71.432101] RBP: 00000000004bf950 R08: 00000000000000e7 R09: ffffffffffffffd0 [ 71.432106] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000001 [ 71.432112] R13: 00000000006d2180 R14: 0000000000000000 R15: 0000000000000000 [ 71.432126] [ 71.432131] Allocated by task 8222: [ 71.432142] save_stack+0x45/0xd0 [ 71.432151] kasan_kmalloc+0xce/0xf0 [ 71.432160] kmem_cache_alloc_trace+0x152/0x760 [ 71.432169] vc_allocate+0x1f5/0x760 [ 71.432178] con_install+0x52/0x410 [ 71.432187] tty_init_dev+0xf7/0x460 [ 71.432195] tty_open+0x4bf/0xb70 [ 71.432204] chrdev_open+0x245/0x6b0 [ 71.432212] do_dentry_open+0x4c3/0x1210 [ 71.432220] vfs_open+0xa0/0xd0 [ 71.432228] path_openat+0x10d8/0x44a0 [ 71.432236] do_filp_open+0x1a1/0x280 [ 71.432244] do_sys_open+0x3fe/0x550 [ 71.432255] __x64_sys_open+0x7e/0xc0 [ 71.432268] do_syscall_64+0xfd/0x620 [ 71.432282] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 71.432285] [ 71.432291] Freed by task 8224: [ 71.432303] save_stack+0x45/0xd0 [ 71.432315] __kasan_slab_free+0x102/0x150 [ 71.432328] kasan_slab_free+0xe/0x10 [ 71.432338] kfree+0xcf/0x220 [ 71.432353] vt_disallocate_all+0x2bd/0x3e0 [ 71.432366] vt_ioctl+0xc38/0x2530 [ 71.432377] tty_ioctl+0x7f3/0x1510 [ 71.432400] do_vfs_ioctl+0xd5f/0x1380 [ 71.432411] ksys_ioctl+0xab/0xd0 [ 71.432422] __x64_sys_ioctl+0x73/0xb0 [ 71.432435] do_syscall_64+0xfd/0x620 [ 71.432449] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 71.432453] [ 71.432463] The buggy address belongs to the object at ffff888097af8640 [ 71.432463] which belongs to the cache kmalloc-2048 of size 2048 [ 71.432475] The buggy address is located 264 bytes inside of [ 71.432475] 2048-byte region [ffff888097af8640, ffff888097af8e40) [ 71.432480] The buggy address belongs to the page: [ 71.432492] page:ffffea00025ebe00 count:1 mapcount:0 mapping:ffff88812c31cc40 index:0x0 compound_mapcount: 0 [ 71.432506] flags: 0xfffe0000008100(slab|head) [ 71.432525] raw: 00fffe0000008100 ffffea0002671988 ffffea00025b1788 ffff88812c31cc40 [ 71.432540] raw: 0000000000000000 ffff888097af8640 0000000100000003 0000000000000000 [ 71.432546] page dumped because: kasan: bad access detected [ 71.432550] [ 71.432554] Memory state around the buggy address: [ 71.432565] ffff888097af8600: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb [ 71.432576] ffff888097af8680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 71.432587] >ffff888097af8700: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 71.432592] ^ [ 71.432603] ffff888097af8780: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 71.432614] ffff888097af8800: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 71.432619] ================================================================== [ 71.432624] Disabling lock debugging due to kernel taint [ 71.433172] Kernel panic - not syncing: panic_on_warn set ... [ 71.433172] [ 71.433188] CPU: 1 PID: 8222 Comm: syz-executor500 Tainted: G B 4.19.103-syzkaller #0 [ 71.433196] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 71.433200] Call Trace: [ 71.433217] dump_stack+0x197/0x210 [ 71.433233] ? con_shutdown+0x85/0x90 [ 71.433244] panic+0x26a/0x50e [ 71.433255] ? __warn_printk+0xf3/0xf3 [ 71.433269] ? con_shutdown+0x85/0x90 [ 71.433281] ? preempt_schedule+0x4b/0x60 [ 71.433300] ? ___preempt_schedule+0x16/0x18 [ 71.433315] ? trace_hardirqs_on+0x5e/0x220 [ 71.433329] ? con_shutdown+0x85/0x90 [ 71.433343] kasan_end_report+0x47/0x4f [ 71.433357] kasan_report.cold+0xa9/0x2ba [ 71.433371] ? set_palette+0x1c0/0x1c0 [ 71.433405] __asan_report_store8_noabort+0x17/0x20 [ 71.433419] con_shutdown+0x85/0x90 [ 71.433432] release_tty+0xe4/0x4d0 [ 71.433447] tty_release_struct+0x3c/0x50 [ 71.433460] tty_release+0xbcb/0xe90 [ 71.433478] ? tty_release_struct+0x50/0x50 [ 71.433492] __fput+0x2dd/0x8b0 [ 71.433509] ____fput+0x16/0x20 [ 71.433522] task_work_run+0x145/0x1c0 [ 71.433537] do_exit+0xc1f/0x30d0 [ 71.433555] ? mm_update_next_owner+0x660/0x660 [ 71.433568] ? up_read+0x1a/0x110 [ 71.433582] ? __sanitizer_cov_trace_const_cmp4+0x16/0x20 [ 71.433595] ? __do_page_fault+0x484/0xe90 [ 71.433611] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 71.433625] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 71.433640] do_group_exit+0x135/0x370 [ 71.433656] __x64_sys_exit_group+0x44/0x50 [ 71.433670] do_syscall_64+0xfd/0x620 [ 71.433682] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 71.433690] RIP: 0033:0x43ff38 [ 71.433702] Code: 00 00 be 3c 00 00 00 eb 19 66 0f 1f 84 00 00 00 00 00 48 89 d7 89 f0 0f 05 48 3d 00 f0 ff ff 77 21 f4 48 89 d7 44 89 c0 0f 05 <48> 3d 00 f0 ff ff 76 e0 f7 d8 64 41 89 01 eb d8 0f 1f 84 00 00 00 [ 71.433709] RSP: 002b:00007ffcc39b35a8 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7 [ 71.433722] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 000000000043ff38 [ 71.433729] RDX: 0000000000000000 RSI: 000000000000003c RDI: 0000000000000000 [ 71.433737] RBP: 00000000004bf950 R08: 00000000000000e7 R09: ffffffffffffffd0 [ 71.433744] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000001 [ 71.433752] R13: 00000000006d2180 R14: 0000000000000000 R15: 0000000000000000 [ 71.435120] Kernel Offset: disabled [ 72.125509] Rebooting in 86400 seconds..