[....] Starting file context maintaining daemon: restorecond[?25l[?1c7[ ok 8[?25h[?0c. Debian GNU/Linux 7 syzkaller ttyS0 syzkaller login: [ 36.182734] random: sshd: uninitialized urandom read (32 bytes read) [ 36.432312] kauditd_printk_skb: 10 callbacks suppressed [ 36.432319] audit: type=1400 audit(1572751790.019:35): avc: denied { map } for pid=6944 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 [ 36.486369] random: sshd: uninitialized urandom read (32 bytes read) [ 37.012165] random: sshd: uninitialized urandom read (32 bytes read) [ 43.412929] random: sshd: uninitialized urandom read (32 bytes read) Warning: Permanently added '10.128.0.230' (ECDSA) to the list of known hosts. [ 49.012224] random: sshd: uninitialized urandom read (32 bytes read) executing program executing program executing program executing program executing program executing program executing program executing program [ 49.131047] audit: type=1400 audit(1572751802.719:36): avc: denied { map } for pid=6956 comm="syz-executor214" path="/root/syz-executor214741304" 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 executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 49.224739] ================================================================== [ 49.232319] BUG: KASAN: use-after-free in disk_unblock_events+0x55/0x60 [ 49.239101] Read of size 8 at addr ffff88809acbca08 by task syz-executor214/6978 [ 49.246627] [ 49.248365] CPU: 1 PID: 6978 Comm: syz-executor214 Not tainted 4.14.151 #0 [ 49.255401] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 49.264756] Call Trace: [ 49.267348] dump_stack+0x138/0x197 executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 49.271152] ? disk_unblock_events+0x55/0x60 [ 49.275570] print_address_description.cold+0x7c/0x1dc [ 49.280851] ? disk_unblock_events+0x55/0x60 [ 49.285258] kasan_report.cold+0xa9/0x2af [ 49.289413] __asan_report_load8_noabort+0x14/0x20 [ 49.294348] disk_unblock_events+0x55/0x60 [ 49.298612] __blkdev_get+0x7d6/0x1120 [ 49.302730] ? __blkdev_put+0x7f0/0x7f0 [ 49.306703] ? bd_acquire+0x178/0x2c0 [ 49.310508] ? find_held_lock+0x35/0x130 [ 49.314574] blkdev_get+0xa8/0x8e0 [ 49.318120] ? bd_may_claim+0xd0/0xd0 executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 49.321923] ? _raw_spin_unlock+0x2d/0x50 [ 49.326075] blkdev_open+0x1d1/0x260 [ 49.329794] ? security_file_open+0x89/0x190 [ 49.334209] do_dentry_open+0x73b/0xeb0 [ 49.338190] ? bd_acquire+0x2c0/0x2c0 [ 49.341997] vfs_open+0x105/0x220 [ 49.345574] path_openat+0x8bd/0x3f70 [ 49.349377] ? entry_SYSCALL_64_after_hwframe+0x42/0xb7 [ 49.354753] ? trace_hardirqs_on+0x10/0x10 [ 49.358993] ? path_lookupat.isra.0+0x7b0/0x7b0 [ 49.363667] ? __lock_is_held+0xb6/0x140 [ 49.367728] ? save_trace+0x290/0x290 [ 49.371528] ? __alloc_fd+0x1d4/0x4a0 executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 49.375328] do_filp_open+0x18e/0x250 [ 49.379129] ? __alloc_fd+0x1d4/0x4a0 [ 49.382926] ? may_open_dev+0xe0/0xe0 [ 49.386739] ? _raw_spin_unlock+0x2d/0x50 [ 49.390887] ? __alloc_fd+0x1d4/0x4a0 [ 49.394703] do_sys_open+0x2c5/0x430 [ 49.398419] ? filp_open+0x70/0x70 [ 49.401962] ? up_read+0x1a/0x40 [ 49.405505] ? _raw_spin_unlock_irq+0x28/0x90 [ 49.410357] SyS_openat+0x30/0x40 [ 49.413833] ? SyS_open+0x40/0x40 [ 49.417289] do_syscall_64+0x1e8/0x640 executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 49.421179] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 49.426032] entry_SYSCALL_64_after_hwframe+0x42/0xb7 [ 49.431217] RIP: 0033:0x446749 [ 49.434404] RSP: 002b:00007f9e2dbf4db8 EFLAGS: 00000246 ORIG_RAX: 0000000000000101 [ 49.442110] RAX: ffffffffffffffda RBX: 00000000006dbc28 RCX: 0000000000446749 [ 49.449391] RDX: 0000000000000000 RSI: 0000000020000080 RDI: ffffffffffffff9c [ 49.456664] RBP: 00000000006dbc20 R08: 00007f9e2dbf5700 R09: 0000000000000000 [ 49.463932] R10: 0000000000000000 R11: 0000000000000246 R12: 00000000006dbc2c executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 49.471200] R13: 00007ffdfc160a1f R14: 00007f9e2dbf59c0 R15: 000000000000002d [ 49.478480] [ 49.480105] Allocated by task 1: [ 49.483475] save_stack_trace+0x16/0x20 [ 49.487449] save_stack+0x45/0xd0 [ 49.490903] kasan_kmalloc+0xce/0xf0 [ 49.494619] kmem_cache_alloc_node_trace+0x153/0x770 [ 49.499721] alloc_disk_node+0x64/0x3e0 [ 49.503693] alloc_disk+0x1b/0x20 [ 49.507147] md_alloc+0x219/0x840 [ 49.510598] md_probe+0x31/0x40 [ 49.513881] kobj_lookup+0x21c/0x400 [ 49.517595] get_gendisk+0x3b/0x240 [ 49.521217] __blkdev_get+0x3af/0x1120 executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 49.525106] blkdev_get+0xa8/0x8e0 [ 49.528655] blkdev_open+0x1d1/0x260 [ 49.532371] do_dentry_open+0x73b/0xeb0 [ 49.536342] vfs_open+0x105/0x220 [ 49.539798] path_openat+0x8bd/0x3f70 [ 49.543604] do_filp_open+0x18e/0x250 [ 49.547404] do_sys_open+0x2c5/0x430 [ 49.551115] SyS_open+0x2d/0x40 [ 49.554403] md_run_setup+0x7a/0xad [ 49.558039] prepare_namespace+0x4a/0x21d [ 49.562187] kernel_init_freeable+0x514/0x532 [ 49.566770] kernel_init+0x12/0x162 [ 49.570400] ret_from_fork+0x24/0x30 [ 49.574107] executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 49.575736] Freed by task 6978: [ 49.579023] save_stack_trace+0x16/0x20 [ 49.583000] save_stack+0x45/0xd0 [ 49.586454] kasan_slab_free+0x75/0xc0 [ 49.590338] kfree+0xcc/0x270 [ 49.593446] disk_release+0x24b/0x2d0 [ 49.597249] device_release+0xf6/0x1a0 [ 49.601136] kobject_put.cold+0x269/0x2f9 [ 49.605282] put_disk+0x23/0x30 [ 49.608559] __blkdev_get+0x73c/0x1120 [ 49.612441] blkdev_get+0xa8/0x8e0 [ 49.616101] blkdev_open+0x1d1/0x260 [ 49.619815] do_dentry_open+0x73b/0xeb0 executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 49.623786] vfs_open+0x105/0x220 [ 49.627238] path_openat+0x8bd/0x3f70 [ 49.631086] do_filp_open+0x18e/0x250 [ 49.634885] do_sys_open+0x2c5/0x430 [ 49.638637] SyS_openat+0x30/0x40 [ 49.642091] do_syscall_64+0x1e8/0x640 [ 49.645979] entry_SYSCALL_64_after_hwframe+0x42/0xb7 [ 49.651161] [ 49.652785] The buggy address belongs to the object at ffff88809acbc480 [ 49.652785] which belongs to the cache kmalloc-2048 of size 2048 [ 49.665613] The buggy address is located 1416 bytes inside of executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 49.665613] 2048-byte region [ffff88809acbc480, ffff88809acbcc80) [ 49.677660] The buggy address belongs to the page: [ 49.682591] page:ffffea00026b2f00 count:1 mapcount:0 mapping:ffff88809acbc480 index:0x0 compound_mapcount: 0 [ 49.692563] flags: 0x1fffc0000008100(slab|head) [ 49.697235] raw: 01fffc0000008100 ffff88809acbc480 0000000000000000 0000000100000003 [ 49.705122] raw: ffffea00026b29a0 ffffea00024e8ea0 ffff8880aa800c40 0000000000000000 [ 49.713000] page dumped because: kasan: bad access detected [ 49.718731] [ 49.720352] Memory state around the buggy address: executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 49.725279] ffff88809acbc900: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 49.732655] ffff88809acbc980: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 49.740023] >ffff88809acbca00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 49.747383] ^ [ 49.751010] ffff88809acbca80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 49.758369] ffff88809acbcb00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 49.765724] ================================================================== executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 49.773082] Disabling lock debugging due to kernel taint [ 49.794479] Kernel panic - not syncing: panic_on_warn set ... [ 49.794479] [ 49.801886] CPU: 1 PID: 6978 Comm: syz-executor214 Tainted: G B 4.14.151 #0 [ 49.810109] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 49.819465] Call Trace: [ 49.822054] dump_stack+0x138/0x197 executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 49.825708] ? disk_unblock_events+0x55/0x60 [ 49.830141] panic+0x1f9/0x42d [ 49.833335] ? add_taint.cold+0x16/0x16 [ 49.837319] ? ___preempt_schedule+0x16/0x18 [ 49.841727] kasan_end_report+0x47/0x4f [ 49.845698] kasan_report.cold+0x130/0x2af [ 49.849958] __asan_report_load8_noabort+0x14/0x20 [ 49.854888] disk_unblock_events+0x55/0x60 [ 49.859209] __blkdev_get+0x7d6/0x1120 [ 49.863093] ? __blkdev_put+0x7f0/0x7f0 [ 49.867066] ? bd_acquire+0x178/0x2c0 [ 49.870896] ? find_held_lock+0x35/0x130 executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 49.874956] blkdev_get+0xa8/0x8e0 [ 49.878495] ? bd_may_claim+0xd0/0xd0 [ 49.882297] ? _raw_spin_unlock+0x2d/0x50 [ 49.886449] blkdev_open+0x1d1/0x260 [ 49.890167] ? security_file_open+0x89/0x190 [ 49.894662] do_dentry_open+0x73b/0xeb0 [ 49.898637] ? bd_acquire+0x2c0/0x2c0 [ 49.902446] vfs_open+0x105/0x220 [ 49.905899] path_openat+0x8bd/0x3f70 [ 49.909703] ? entry_SYSCALL_64_after_hwframe+0x42/0xb7 [ 49.915069] ? trace_hardirqs_on+0x10/0x10 [ 49.919305] ? path_lookupat.isra.0+0x7b0/0x7b0 executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 49.923976] ? __lock_is_held+0xb6/0x140 [ 49.928036] ? save_trace+0x290/0x290 [ 49.931835] ? __alloc_fd+0x1d4/0x4a0 [ 49.935639] do_filp_open+0x18e/0x250 [ 49.939439] ? __alloc_fd+0x1d4/0x4a0 [ 49.943235] ? may_open_dev+0xe0/0xe0 [ 49.947039] ? _raw_spin_unlock+0x2d/0x50 [ 49.951184] ? __alloc_fd+0x1d4/0x4a0 [ 49.954986] do_sys_open+0x2c5/0x430 [ 49.958700] ? filp_open+0x70/0x70 [ 49.962238] ? up_read+0x1a/0x40 [ 49.965599] ? _raw_spin_unlock_irq+0x28/0x90 [ 49.970093] SyS_openat+0x30/0x40 [ 49.973541] ? SyS_open+0x40/0x40 executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 49.976993] do_syscall_64+0x1e8/0x640 [ 49.980878] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 49.985720] entry_SYSCALL_64_after_hwframe+0x42/0xb7 [ 49.990904] RIP: 0033:0x446749 [ 49.994088] RSP: 002b:00007f9e2dbf4db8 EFLAGS: 00000246 ORIG_RAX: 0000000000000101 [ 50.001795] RAX: ffffffffffffffda RBX: 00000000006dbc28 RCX: 0000000000446749 [ 50.009063] RDX: 0000000000000000 RSI: 0000000020000080 RDI: ffffffffffffff9c [ 50.016339] RBP: 00000000006dbc20 R08: 00007f9e2dbf5700 R09: 0000000000000000 executing program executing program executing program executing program executing program executing program [ 50.023730] R10: 0000000000000000 R11: 0000000000000246 R12: 00000000006dbc2c [ 50.030996] R13: 00007ffdfc160a1f R14: 00007f9e2dbf59c0 R15: 000000000000002d [ 50.039642] Kernel Offset: disabled [ 50.043265] Rebooting in 86400 seconds..