[ 34.744111] audit: type=1800 audit(1583331719.797:33): pid=7263 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:kernel_t:s0 op="collect_data" cause="failed(directio)" comm="startpar" name="rc.local" dev="sda1" ino=2465 res=0 [ 34.771341] audit: type=1800 audit(1583331719.797:34): pid=7263 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:kernel_t:s0 op="collect_data" cause="failed(directio)" comm="startpar" name="rmnologin" dev="sda1" ino=2456 res=0 Debian GNU/Linux 7 syzkaller ttyS0 syzkaller login: [ 37.699306] random: sshd: uninitialized urandom read (32 bytes read) [ 37.925170] audit: type=1400 audit(1583331722.977:35): avc: denied { map } for pid=7434 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 [ 37.964555] random: sshd: uninitialized urandom read (32 bytes read) [ 38.672759] random: sshd: uninitialized urandom read (32 bytes read) [ 53.500937] random: sshd: uninitialized urandom read (32 bytes read) Warning: Permanently added '10.128.0.141' (ECDSA) to the list of known hosts. [ 59.124999] random: sshd: uninitialized urandom read (32 bytes read) executing program executing program executing program executing program executing program executing program executing program [ 59.248281] audit: type=1400 audit(1583331744.297:36): avc: denied { map } for pid=7446 comm="syz-executor006" path="/root/syz-executor006956602" dev="sda1" ino=1426 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:user_home_t:s0 tclass=file permissive=1 [ 59.305393] ================================================================== [ 59.305428] BUG: KASAN: use-after-free in con_shutdown+0x7f/0x90 [ 59.305434] Write of size 8 at addr ffff88809355ee08 by task syz-executor006/7454 [ 59.305436] [ 59.305443] CPU: 0 PID: 7454 Comm: syz-executor006 Not tainted 4.14.172-syzkaller #0 [ 59.305447] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 59.305450] Call Trace: [ 59.305461] dump_stack+0x13e/0x194 [ 59.305470] ? con_shutdown+0x7f/0x90 [ 59.305489] print_address_description.cold+0x7c/0x1e2 [ 59.305498] ? con_shutdown+0x7f/0x90 [ 59.305506] kasan_report.cold+0xa9/0x2ae [ 59.305514] ? set_palette+0x130/0x130 [ 59.305522] con_shutdown+0x7f/0x90 [ 59.305531] release_tty+0xb6/0x7a0 [ 59.305540] tty_release_struct+0x37/0x50 [ 59.305548] tty_release+0xaa6/0xd60 [ 59.305562] ? tty_release_struct+0x50/0x50 [ 59.305570] __fput+0x25f/0x790 [ 59.305585] task_work_run+0x113/0x190 [ 59.305596] do_exit+0x9f2/0x2b00 [ 59.305606] ? __do_page_fault+0x4e4/0xb40 [ 59.305616] ? mm_update_next_owner+0x5b0/0x5b0 [ 59.305626] ? lock_downgrade+0x6e0/0x6e0 [ 59.305639] do_group_exit+0x100/0x310 [ 59.305649] SyS_exit_group+0x19/0x20 [ 59.305655] ? do_group_exit+0x310/0x310 [ 59.305664] do_syscall_64+0x1d5/0x640 [ 59.305678] entry_SYSCALL_64_after_hwframe+0x42/0xb7 [ 59.305685] RIP: 0033:0x43ff38 [ 59.305689] RSP: 002b:00007ffe182eee58 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7 [ 59.305698] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 000000000043ff38 [ 59.305703] RDX: 0000000000000000 RSI: 000000000000003c RDI: 0000000000000000 [ 59.305708] RBP: 00000000004bf950 R08: 00000000000000e7 R09: ffffffffffffffd0 [ 59.305712] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000001 [ 59.305717] R13: 00000000006d2180 R14: 0000000000000000 R15: 0000000000000000 [ 59.305730] [ 59.305735] Allocated by task 7454: [ 59.305742] save_stack+0x32/0xa0 [ 59.305748] kasan_kmalloc+0xbf/0xe0 [ 59.305754] kmem_cache_alloc_trace+0x14d/0x7b0 [ 59.305761] vc_allocate+0x142/0x550 [ 59.305767] con_install+0x4f/0x3e0 [ 59.305774] tty_init_dev+0xe1/0x3a0 [ 59.305780] tty_open+0x410/0x9c0 [ 59.305787] chrdev_open+0x1fc/0x540 [ 59.305794] do_dentry_open+0x732/0xe90 [ 59.305801] vfs_open+0x105/0x220 [ 59.305807] path_openat+0x8ca/0x3c50 [ 59.305813] do_filp_open+0x18e/0x250 [ 59.305820] do_sys_open+0x29d/0x3f0 [ 59.305826] do_syscall_64+0x1d5/0x640 [ 59.305833] entry_SYSCALL_64_after_hwframe+0x42/0xb7 [ 59.305835] [ 59.305839] Freed by task 7456: [ 59.305845] save_stack+0x32/0xa0 [ 59.305851] kasan_slab_free+0x75/0xc0 [ 59.305856] kfree+0xcb/0x260 [ 59.305865] vt_disallocate_all+0x25c/0x340 [ 59.305870] vt_ioctl+0x6e3/0x1f00 [ 59.305876] tty_ioctl+0x6c5/0x1220 [ 59.305882] do_vfs_ioctl+0x75a/0xfe0 [ 59.305889] SyS_ioctl+0x7f/0xb0 [ 59.305895] do_syscall_64+0x1d5/0x640 [ 59.305901] entry_SYSCALL_64_after_hwframe+0x42/0xb7 [ 59.305903] [ 59.305908] The buggy address belongs to the object at ffff88809355ed00 [ 59.305908] which belongs to the cache kmalloc-2048 of size 2048 [ 59.305914] The buggy address is located 264 bytes inside of [ 59.305914] 2048-byte region [ffff88809355ed00, ffff88809355f500) [ 59.305917] The buggy address belongs to the page: [ 59.305923] page:ffffea00024d5780 count:1 mapcount:0 mapping:ffff88809355e480 index:0x0 compound_mapcount: 0 [ 59.305934] flags: 0xfffe0000008100(slab|head) [ 59.305944] raw: 00fffe0000008100 ffff88809355e480 0000000000000000 0000000100000003 [ 59.305952] raw: ffffea00024b54a0 ffffea0002584720 ffff88812fe56c40 0000000000000000 [ 59.305955] page dumped because: kasan: bad access detected [ 59.305958] [ 59.305960] Memory state around the buggy address: [ 59.305966] ffff88809355ed00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 59.305972] ffff88809355ed80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 59.305977] >ffff88809355ee00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 59.305981] ^ [ 59.305986] ffff88809355ee80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 59.305992] ffff88809355ef00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 59.305994] ================================================================== [ 59.305997] Disabling lock debugging due to kernel taint [ 59.306032] Kernel panic - not syncing: panic_on_warn set ... [ 59.306032] [ 59.306039] CPU: 0 PID: 7454 Comm: syz-executor006 Tainted: G B 4.14.172-syzkaller #0 [ 59.306043] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 59.306045] Call Trace: [ 59.306053] dump_stack+0x13e/0x194 [ 59.306061] panic+0x1f9/0x42d [ 59.306067] ? add_taint.cold+0x16/0x16 [ 59.306077] ? con_shutdown+0x7f/0x90 [ 59.306083] kasan_end_report+0x43/0x49 [ 59.306090] kasan_report.cold+0x12f/0x2ae [ 59.306097] ? set_palette+0x130/0x130 [ 59.306103] con_shutdown+0x7f/0x90 [ 59.306110] release_tty+0xb6/0x7a0 [ 59.306118] tty_release_struct+0x37/0x50 [ 59.306131] tty_release+0xaa6/0xd60 [ 59.306141] ? tty_release_struct+0x50/0x50 [ 59.306146] __fput+0x25f/0x790 [ 59.306156] task_work_run+0x113/0x190 [ 59.306164] do_exit+0x9f2/0x2b00 [ 59.306171] ? __do_page_fault+0x4e4/0xb40 [ 59.306178] ? mm_update_next_owner+0x5b0/0x5b0 [ 59.306186] ? lock_downgrade+0x6e0/0x6e0 [ 59.306195] do_group_exit+0x100/0x310 [ 59.306203] SyS_exit_group+0x19/0x20 [ 59.306209] ? do_group_exit+0x310/0x310 [ 59.306215] do_syscall_64+0x1d5/0x640 [ 59.306224] entry_SYSCALL_64_after_hwframe+0x42/0xb7 [ 59.306229] RIP: 0033:0x43ff38 [ 59.306233] RSP: 002b:00007ffe182eee58 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7 [ 59.306239] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 000000000043ff38 [ 59.306243] RDX: 0000000000000000 RSI: 000000000000003c RDI: 0000000000000000 [ 59.306247] RBP: 00000000004bf950 R08: 00000000000000e7 R09: ffffffffffffffd0 [ 59.306251] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000001 [ 59.306255] R13: 00000000006d2180 R14: 0000000000000000 R15: 0000000000000000 [ 59.307557] Kernel Offset: disabled