[....] Starting enhanced syslogd: rsyslogd[ 11.281192] audit: type=1400 audit(1516105232.878:4): avc: denied { syslog } for pid=3175 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 periodic command scheduler: cron[?25l[?1c7[ ok 8[?25h[?0c. Starting mcstransd: [....] 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.4' (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 syzkaller login: [ 20.862963] ================================================================== [ 20.864482] BUG: KASAN: use-after-free in disk_unblock_events+0x51/0x60 [ 20.866037] Read of size 8 at addr ffff8801c5f12760 by task blkid/3399 [ 20.867010] [ 20.867289] CPU: 1 PID: 3399 Comm: blkid Not tainted 4.9.76-g8dec074 #13 [ 20.868296] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 20.869688] ffff8801c54ef790 ffffffff81d93169 ffffea000717c400 ffff8801c5f12760 [ 20.871105] 0000000000000000 ffff8801c5f12760 0000000000000000 ffff8801c54ef7c8 [ 20.872626] ffffffff8153cb43 ffff8801c5f12760 0000000000000008 0000000000000000 [ 20.874430] Call Trace: [ 20.874844] [] dump_stack+0xc1/0x128 [ 20.875610] [] print_address_description+0x73/0x280 [ 20.876587] [] kasan_report+0x275/0x360 [ 20.877356] [] ? disk_unblock_events+0x51/0x60 [ 20.878237] [] __asan_report_load8_noabort+0x14/0x20 [ 20.879338] [] disk_unblock_events+0x51/0x60 [ 20.880166] [] __blkdev_get+0x4b5/0xd50 [ 20.880931] [] ? __blkdev_put+0x7e0/0x7e0 [ 20.881798] [] blkdev_get+0x33b/0x960 [ 20.882617] [] ? bd_link_disk_holder+0x6c0/0x6c0 [ 20.886812] [] ? bd_acquire+0x27/0x250 [ 20.892336] [] ? bd_acquire+0x88/0x250 [ 20.897851] [] ? _raw_spin_unlock+0x2c/0x50 [ 20.903798] [] blkdev_open+0x1a5/0x250 [ 20.909312] [] do_dentry_open+0x607/0xc60 [ 20.915083] [] ? blkdev_get_by_dev+0x60/0x60 [ 20.921121] [] vfs_open+0x105/0x220 [ 20.926380] [] ? may_open+0x231/0x2e0 [ 20.931818] [] path_openat+0x5ac/0x2910 [ 20.937423] [] ? path_lookupat+0x3f0/0x3f0 [ 20.943294] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 20.950287] [] ? __lock_is_held+0xa1/0xf0 [ 20.956068] [] do_filp_open+0x197/0x290 [ 20.961685] [] ? may_open_dev+0xe0/0xe0 [ 20.967303] [] ? _raw_spin_unlock+0x2c/0x50 [ 20.973263] [] ? __alloc_fd+0x1d7/0x510 [ 20.978894] [] do_sys_open+0x352/0x4c0 [ 20.984441] [] ? filp_open+0x70/0x70 [ 20.989789] [] ? entry_SYSCALL_64_fastpath+0x5/0xe2 [ 20.996440] [] ? trace_hardirqs_on_caller+0x38b/0x590 [ 21.003275] [] SyS_open+0x2d/0x40 [ 21.008367] [] entry_SYSCALL_64_fastpath+0x23/0xe2 [ 21.014922] [ 21.016536] Allocated by task 3389: [ 21.020149] save_stack_trace+0x16/0x20 [ 21.024109] save_stack+0x43/0xd0 [ 21.027544] kasan_kmalloc+0xad/0xe0 [ 21.031239] kmem_cache_alloc_trace+0xfb/0x2a0 [ 21.035803] alloc_disk_node+0x54/0x3b0 [ 21.039762] alloc_disk+0x18/0x20 [ 21.043191] loop_add+0x324/0x770 [ 21.046636] loop_probe+0x155/0x180 [ 21.050258] kobj_lookup+0x2ac/0x410 [ 21.053961] get_gendisk+0x37/0x2d0 [ 21.057571] blkdev_get+0x110/0x960 [ 21.061181] blkdev_open+0x1a5/0x250 [ 21.064910] do_dentry_open+0x607/0xc60 [ 21.068874] vfs_open+0x105/0x220 [ 21.072330] path_openat+0x5ac/0x2910 [ 21.076125] do_filp_open+0x197/0x290 [ 21.079911] do_sys_open+0x352/0x4c0 [ 21.083606] SyS_open+0x2d/0x40 [ 21.086862] entry_SYSCALL_64_fastpath+0x23/0xe2 [ 21.091589] [ 21.093197] Freed by task 3399: [ 21.096469] save_stack_trace+0x16/0x20 [ 21.100430] save_stack+0x43/0xd0 [ 21.103854] kasan_slab_free+0x72/0xc0 [ 21.107724] kfree+0x103/0x300 [ 21.110901] disk_release+0x259/0x330 [ 21.114683] device_release+0x7c/0x210 [ 21.118548] kobject_release+0xed/0x1a0 [ 21.122502] kobject_put+0x63/0xc0 [ 21.126012] put_disk+0x23/0x30 [ 21.129269] __blkdev_get+0x415/0xd50 [ 21.133042] blkdev_get+0x33b/0x960 [ 21.136642] blkdev_open+0x1a5/0x250 [ 21.140331] do_dentry_open+0x607/0xc60 [ 21.144285] vfs_open+0x105/0x220 [ 21.147711] path_openat+0x5ac/0x2910 [ 21.151495] do_filp_open+0x197/0x290 [ 21.155271] do_sys_open+0x352/0x4c0 [ 21.158956] SyS_open+0x2d/0x40 [ 21.162215] entry_SYSCALL_64_fastpath+0x23/0xe2 [ 21.166941] [ 21.168548] The buggy address belongs to the object at ffff8801c5f12200 [ 21.168548] which belongs to the cache kmalloc-2048 of size 2048 [ 21.181364] The buggy address is located 1376 bytes inside of [ 21.181364] 2048-byte region [ffff8801c5f12200, ffff8801c5f12a00) [ 21.193390] The buggy address belongs to the page: [ 21.198306] page:ffffea000717c400 count:1 mapcount:0 mapping: (null) index:0x0 compound_mapcount: 0 [ 21.208482] flags: 0x8000000000004080(slab|head) [ 21.213212] page dumped because: kasan: bad access detected [ 21.218904] [ 21.220506] Memory state around the buggy address: [ 21.225412] ffff8801c5f12600: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 21.232758] ffff8801c5f12680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 21.240096] >ffff8801c5f12700: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 21.247437] ^ [ 21.253927] ffff8801c5f12780: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb executing program executing program executing program executing program executing program [ 21.261262] ffff8801c5f12800: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 21.268592] ================================================================== [ 21.275927] Disabling lock debugging due to kernel taint [ 21.285380] Kernel panic - not syncing: panic_on_warn set ... [ 21.285380] [ 21.292814] CPU: 1 PID: 3399 Comm: blkid Tainted: G B 4.9.76-g8dec074 #13 [ 21.300866] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 21.310205] ffff8801c54ef6e8 ffffffff81d93169 ffffffff84195c2f ffff8801c54ef7c0 [ 21.318216] 0000000000000000 ffff8801c5f12760 0000000000000000 ffff8801c54ef7b0 [ 21.326204] ffffffff8142e371 0000000041b58ab3 ffffffff84189690 ffffffff8142e1b5 [ 21.334187] Call Trace: [ 21.336753] [] dump_stack+0xc1/0x128 [ 21.342092] [] panic+0x1bc/0x3a8 [ 21.347092] [] ? percpu_up_read_preempt_enable.constprop.53+0xd7/0xd7 [ 21.355309] [] ? preempt_schedule+0x25/0x30 [ 21.361265] [] ? ___preempt_schedule+0x16/0x18 [ 21.367485] [] kasan_end_report+0x50/0x50 [ 21.373300] [] kasan_report+0x167/0x360 [ 21.378920] [] ? disk_unblock_events+0x51/0x60 [ 21.385148] [] __asan_report_load8_noabort+0x14/0x20 [ 21.391897] [] disk_unblock_events+0x51/0x60 [ 21.397945] [] __blkdev_get+0x4b5/0xd50 [ 21.403551] [] ? __blkdev_put+0x7e0/0x7e0 [ 21.409337] [] blkdev_get+0x33b/0x960 [ 21.414779] [] ? bd_link_disk_holder+0x6c0/0x6c0 [ 21.421163] [] ? bd_acquire+0x27/0x250 [ 21.426682] [] ? bd_acquire+0x88/0x250 [ 21.432199] [] ? _raw_spin_unlock+0x2c/0x50 [ 21.438145] [] blkdev_open+0x1a5/0x250 [ 21.443664] [] do_dentry_open+0x607/0xc60 [ 21.449447] [] ? blkdev_get_by_dev+0x60/0x60 [ 21.455486] [] vfs_open+0x105/0x220 [ 21.460745] [] ? may_open+0x231/0x2e0 [ 21.466168] [] path_openat+0x5ac/0x2910 [ 21.471766] [] ? path_lookupat+0x3f0/0x3f0 [ 21.477631] [] ? debug_check_no_locks_freed+0x2c0/0x2c0 [ 21.484621] [] ? __lock_is_held+0xa1/0xf0 [ 21.490406] [] do_filp_open+0x197/0x290 [ 21.496014] [] ? may_open_dev+0xe0/0xe0 [ 21.501628] [] ? _raw_spin_unlock+0x2c/0x50 [ 21.507579] [] ? __alloc_fd+0x1d7/0x510 [ 21.513191] [] do_sys_open+0x352/0x4c0 [ 21.518707] [] ? filp_open+0x70/0x70 [ 21.524049] [] ? entry_SYSCALL_64_fastpath+0x5/0xe2 [ 21.530692] [] ? trace_hardirqs_on_caller+0x38b/0x590 [ 21.537507] [] SyS_open+0x2d/0x40 [ 21.542596] [] entry_SYSCALL_64_fastpath+0x23/0xe2 [ 21.549613] Dumping ftrace buffer: [ 21.553143] (ftrace buffer empty) [ 21.556837] Kernel Offset: disabled [ 21.560450] Rebooting in 86400 seconds..