[....] Starting enhanced syslogd: rsyslogd[ 11.370463] audit: type=1400 audit(1516412031.331:4): avc: denied { syslog } for pid=3172 comm="rsyslogd" capability=34 scontext=system_u:system_r:kernel_t:s0 tcontext=system_u:system_r:kernel_t:s0 tclass=capability2 permissive=1 [?25l[?1c7[ ok 8[?25h[?0c. Starting mcstransd: [....] Starting periodic command scheduler: cron[?25l[?1c7[ ok 8[?25h[?0c. [....] Starting file context maintaining daemon: restorecond[?25l[?1c7[ ok 8[?25h[?0c. [....] Starting OpenBSD Secure Shell server: sshd[?25l[?1c7[ ok 8[?25h[?0c. Debian GNU/Linux 7 syzkaller ttyS0 Warning: Permanently added '10.128.0.45' (ECDSA) to the list of known hosts. 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 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 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 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 syzkaller login: [ 25.363056] ================================================================== [ 25.370454] BUG: KASAN: use-after-free in disk_unblock_events+0x51/0x60 [ 25.377178] Read of size 8 at addr ffff8801c4993860 by task blkid/3545 [ 25.383817] [ 25.385418] CPU: 0 PID: 3545 Comm: blkid Not tainted 4.9.77-ge12a9c4 #27 [ 25.392233] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 25.401566] ffff8801c80ef790 ffffffff81d941c9 ffffea0007126400 ffff8801c4993860 [ 25.409530] 0000000000000000 ffff8801c4993860 0000000000000000 ffff8801c80ef7c8 [ 25.417495] ffffffff8153db93 ffff8801c4993860 0000000000000008 0000000000000000 [ 25.425473] Call Trace: [ 25.428028] [] dump_stack+0xc1/0x128 [ 25.433370] [] print_address_description+0x73/0x280 [ 25.440004] [] kasan_report+0x275/0x360 [ 25.445597] [] ? disk_unblock_events+0x51/0x60 [ 25.451795] [] __asan_report_load8_noabort+0x14/0x20 [ 25.458527] [] disk_unblock_events+0x51/0x60 [ 25.464553] [] __blkdev_get+0x4b5/0xd50 [ 25.470154] [] ? __blkdev_put+0x7e0/0x7e0 [ 25.475921] [] blkdev_get+0x33b/0x960 [ 25.481341] [] ? bd_link_disk_holder+0x6c0/0x6c0 [ 25.487723] [] ? bd_acquire+0x27/0x250 [ 25.493226] [] ? bd_acquire+0x88/0x250 [ 25.498731] [] ? _raw_spin_unlock+0x2c/0x50 [ 25.504671] [] blkdev_open+0x1a5/0x250 [ 25.510174] [] do_dentry_open+0x607/0xc60 [ 25.515945] [] ? blkdev_get_by_dev+0x60/0x60 [ 25.521976] [] vfs_open+0x105/0x220 [ 25.527220] [] ? may_open+0x231/0x2e0 [ 25.532637] [] path_openat+0x5ac/0x2910 [ 25.538232] [] ? path_lookupat+0x3f0/0x3f0 [ 25.544084] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 25.551066] [] ? __lock_is_held+0xa1/0xf0 [ 25.556831] [] do_filp_open+0x197/0x290 [ 25.562422] [] ? may_open_dev+0xe0/0xe0 [ 25.568019] [] ? _raw_spin_unlock+0x2c/0x50 [ 25.573956] [] ? __alloc_fd+0x1d7/0x510 [ 25.579551] [] do_sys_open+0x352/0x4c0 [ 25.585054] [] ? filp_open+0x70/0x70 [ 25.590385] [] ? entry_SYSCALL_64_fastpath+0x5/0xe8 [ 25.597020] [] ? trace_hardirqs_on_caller+0x38b/0x590 [ 25.603827] [] SyS_open+0x2d/0x40 [ 25.608897] [] entry_SYSCALL_64_fastpath+0x29/0xe8 [ 25.615441] [ 25.617035] Allocated by task 3527: [ 25.620631] save_stack_trace+0x16/0x20 [ 25.624569] save_stack+0x43/0xd0 [ 25.627987] kasan_kmalloc+0xad/0xe0 [ 25.631665] kmem_cache_alloc_trace+0xfb/0x2a0 [ 25.636216] alloc_disk_node+0x54/0x3b0 [ 25.640156] alloc_disk+0x18/0x20 [ 25.643580] loop_add+0x324/0x770 [ 25.647002] loop_probe+0x155/0x180 [ 25.650595] kobj_lookup+0x2ac/0x410 [ 25.654278] get_gendisk+0x37/0x2d0 [ 25.657873] blkdev_get+0x110/0x960 [ 25.661468] blkdev_open+0x1a5/0x250 [ 25.665148] do_dentry_open+0x607/0xc60 [ 25.669088] vfs_open+0x105/0x220 [ 25.672509] path_openat+0x5ac/0x2910 [ 25.676274] do_filp_open+0x197/0x290 [ 25.680087] do_sys_open+0x352/0x4c0 [ 25.683767] compat_SyS_open+0x2a/0x40 [ 25.687625] do_fast_syscall_32+0x2f7/0x890 [ 25.691923] entry_SYSENTER_compat+0x74/0x83 [ 25.696305] [ 25.697906] Freed by task 3545: [ 25.701153] save_stack_trace+0x16/0x20 [ 25.705093] save_stack+0x43/0xd0 [ 25.708514] kasan_slab_free+0x72/0xc0 [ 25.712369] kfree+0x103/0x300 [ 25.715528] disk_release+0x259/0x330 [ 25.719301] device_release+0x7c/0x210 [ 25.723155] kobject_release+0xed/0x1a0 [ 25.727097] kobject_put+0x63/0xc0 [ 25.730605] put_disk+0x23/0x30 [ 25.733860] __blkdev_get+0x415/0xd50 [ 25.737626] blkdev_get+0x33b/0x960 [ 25.741221] blkdev_open+0x1a5/0x250 [ 25.744903] do_dentry_open+0x607/0xc60 [ 25.748844] vfs_open+0x105/0x220 [ 25.752268] path_openat+0x5ac/0x2910 [ 25.756040] do_filp_open+0x197/0x290 [ 25.759810] do_sys_open+0x352/0x4c0 [ 25.763490] SyS_open+0x2d/0x40 [ 25.766736] entry_SYSCALL_64_fastpath+0x29/0xe8 [ 25.771458] [ 25.773054] The buggy address belongs to the object at ffff8801c4993300 [ 25.773054] which belongs to the cache kmalloc-2048 of size 2048 [ 25.785851] The buggy address is located 1376 bytes inside of [ 25.785851] 2048-byte region [ffff8801c4993300, ffff8801c4993b00) [ 25.797863] The buggy address belongs to the page: [ 25.802759] page:ffffea0007126400 count:1 mapcount:0 mapping: (null) index:0x0 compound_mapcount: 0 [ 25.812925] flags: 0x8000000000004080(slab|head) [ 25.817645] page dumped because: kasan: bad access detected [ 25.823320] [ 25.824913] Memory state around the buggy address: [ 25.829816] ffff8801c4993700: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 25.837143] ffff8801c4993780: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 25.844470] >ffff8801c4993800: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 25.851794] ^ executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 25.858252] ffff8801c4993880: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 25.865578] ffff8801c4993900: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 25.872903] ================================================================== [ 25.880237] Disabling lock debugging due to kernel taint [ 25.887026] Kernel panic - not syncing: panic_on_warn set ... [ 25.887026] [ 25.894376] CPU: 0 PID: 3545 Comm: blkid Tainted: G B 4.9.77-ge12a9c4 #27 [ 25.902405] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 25.911738] ffff8801c80ef6e8 ffffffff81d941c9 ffffffff841970ff ffff8801c80ef7c0 [ 25.919706] 0000000000000000 ffff8801c4993860 0000000000000000 ffff8801c80ef7b0 [ 25.927671] ffffffff8142f3c1 0000000041b58ab3 ffffffff8418ab70 ffffffff8142f205 [ 25.935638] Call Trace: [ 25.938199] [] dump_stack+0xc1/0x128 [ 25.943532] [] panic+0x1bc/0x3a8 [ 25.948517] [] ? percpu_up_read_preempt_enable.constprop.53+0xd7/0xd7 [ 25.956716] [] ? preempt_schedule+0x25/0x30 [ 25.962659] [] ? ___preempt_schedule+0x16/0x18 [ 25.968860] [] kasan_end_report+0x50/0x50 [ 25.974625] [] kasan_report+0x167/0x360 [ 25.980231] [] ? disk_unblock_events+0x51/0x60 [ 25.986433] [] __asan_report_load8_noabort+0x14/0x20 [ 25.993181] [] disk_unblock_events+0x51/0x60 [ 25.999221] [] __blkdev_get+0x4b5/0xd50 [ 26.004823] [] ? __blkdev_put+0x7e0/0x7e0 [ 26.010596] [] blkdev_get+0x33b/0x960 [ 26.016024] [] ? bd_link_disk_holder+0x6c0/0x6c0 [ 26.022398] [] ? bd_acquire+0x27/0x250 [ 26.027910] [] ? bd_acquire+0x88/0x250 [ 26.033416] [] ? _raw_spin_unlock+0x2c/0x50 [ 26.039376] [] blkdev_open+0x1a5/0x250 [ 26.044884] [] do_dentry_open+0x607/0xc60 [ 26.050660] [] ? blkdev_get_by_dev+0x60/0x60 [ 26.056686] [] vfs_open+0x105/0x220 [ 26.061932] [] ? may_open+0x231/0x2e0 [ 26.067351] [] path_openat+0x5ac/0x2910 [ 26.072945] [] ? path_lookupat+0x3f0/0x3f0 [ 26.078799] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 26.085789] [] ? __lock_is_held+0xa1/0xf0 [ 26.091555] [] do_filp_open+0x197/0x290 [ 26.097147] [] ? may_open_dev+0xe0/0xe0 [ 26.102749] [] ? _raw_spin_unlock+0x2c/0x50 [ 26.108700] [] ? __alloc_fd+0x1d7/0x510 [ 26.114294] [] do_sys_open+0x352/0x4c0 [ 26.119799] [] ? filp_open+0x70/0x70 [ 26.125132] [] ? entry_SYSCALL_64_fastpath+0x5/0xe8 [ 26.131767] [] ? trace_hardirqs_on_caller+0x38b/0x590 [ 26.138577] [] SyS_open+0x2d/0x40 [ 26.143650] [] entry_SYSCALL_64_fastpath+0x29/0xe8 [ 26.150664] Dumping ftrace buffer: [ 26.154172] (ftrace buffer empty) [ 26.157850] Kernel Offset: disabled [ 26.161447] Rebooting in 86400 seconds..