INIT: Entering runlevel: 2 [info] Using makefile-style concurrent boot in runlevel 2. [....] Starting enhanced syslogd: rsyslogd[?25l[?1c7[ ok 8[?25h[?0c. [....] Starting periodic command scheduler: cron[?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 'ci-upstream-kasan-gce-2,10.128.15.201' (ECDSA) to the list of known hosts. executing program executing program syzkaller login: [ 33.465281] ================================================================== [ 33.466424] BUG: KASAN: use-after-free in __internal_add_timer+0x275/0x2d0 [ 33.467399] Write of size 8 at addr ffff8801cc8cb6c8 by task syzkaller671964/3018 [ 33.468424] [ 33.468661] CPU: 0 PID: 3018 Comm: syzkaller671964 Not tainted 4.13.0+ #68 [ 33.469600] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 33.470823] Call Trace: [ 33.471186] dump_stack+0x194/0x257 [ 33.471713] ? arch_local_irq_restore+0x53/0x53 [ 33.472371] ? show_regs_print_info+0x65/0x65 [ 33.472983] ? __internal_add_timer+0x275/0x2d0 [ 33.473635] print_address_description+0x73/0x250 [ 33.474335] ? __internal_add_timer+0x275/0x2d0 [ 33.475009] kasan_report+0x24e/0x340 [ 33.475554] __asan_report_store8_noabort+0x17/0x20 [ 33.476224] __internal_add_timer+0x275/0x2d0 [ 33.476858] ? calc_wheel_index+0x200/0x200 [ 33.477453] mod_timer+0x622/0x15b0 [ 33.477956] ? mod_timer_pending+0x14e0/0x14e0 [ 33.478596] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 33.479278] ? trace_hardirqs_on+0xd/0x10 [ 33.479854] ? _crng_backtrack_protect+0xd9/0x130 [ 33.480520] ? __lock_is_held+0xbc/0x140 [ 33.481073] ? __lockdep_init_map+0xe4/0x650 [ 33.481698] ? lockdep_init_map+0x3d/0x70 [ 33.482350] ? rcu_read_lock_sched_held+0x108/0x120 [ 33.483107] ? init_timer_key+0x126/0x3b0 [ 33.483701] ? try_to_del_timer_sync+0x120/0x120 [ 33.484339] ? round_jiffies_up+0xce/0x100 [ 33.484925] ? __round_jiffies_up_relative+0x150/0x150 [ 33.486944] ? debug_lockdep_rcu_enabled+0x77/0x90 [ 33.491858] __tun_chr_ioctl+0x1b2c/0x3d70 [ 33.496075] ? tun_select_queue+0x580/0x580 [ 33.500378] ? lock_downgrade+0x990/0x990 [ 33.504529] ? check_same_owner+0x320/0x320 [ 33.508825] ? __handle_mm_fault+0x3840/0x3840 [ 33.513377] ? vmacache_find+0x61/0x270 [ 33.517329] ? tun_chr_compat_ioctl+0x30/0x30 [ 33.521795] tun_chr_ioctl+0x2a/0x40 [ 33.525480] ? tun_chr_ioctl+0x2a/0x40 [ 33.529344] do_vfs_ioctl+0x1b1/0x1530 [ 33.533209] ? ioctl_preallocate+0x2b0/0x2b0 [ 33.537597] ? selinux_capable+0x40/0x40 [ 33.541634] ? putname+0xf3/0x130 [ 33.545063] ? do_sys_open+0x320/0x6d0 [ 33.549024] ? security_file_ioctl+0x7d/0xb0 [ 33.553408] ? security_file_ioctl+0x89/0xb0 [ 33.557792] SyS_ioctl+0x8f/0xc0 [ 33.561149] entry_SYSCALL_64_fastpath+0x1f/0xbe [ 33.565877] RIP: 0033:0x443d99 [ 33.569037] RSP: 002b:00007ffd67e47a08 EFLAGS: 00000207 ORIG_RAX: 0000000000000010 [ 33.576718] RAX: ffffffffffffffda RBX: ffffffffffffffff RCX: 0000000000443d99 [ 33.583958] RDX: 0000000020822000 RSI: 00000000400454ca RDI: 0000000000000006 [ 33.591201] RBP: 0000000000000082 R08: 0000000000000000 R09: 0000000000000000 [ 33.598490] R10: 0000000000000000 R11: 0000000000000207 R12: 5f6010a0d3dd9153 [ 33.605732] R13: 74656e2f7665642f R14: 0000000000000000 R15: 0000000000000000 [ 33.612989] [ 33.614605] Allocated by task 3018: [ 33.618220] save_stack_trace+0x16/0x20 [ 33.622182] save_stack+0x43/0xd0 [ 33.625602] kasan_kmalloc+0xad/0xe0 [ 33.629324] __kmalloc_node+0x47/0x70 [ 33.633110] kvmalloc_node+0x64/0xd0 [ 33.636797] alloc_netdev_mqs+0x16e/0xed0 [ 33.640931] __tun_chr_ioctl+0x12be/0x3d70 [ 33.646324] tun_chr_ioctl+0x2a/0x40 [ 33.650024] do_vfs_ioctl+0x1b1/0x1530 [ 33.653895] SyS_ioctl+0x8f/0xc0 [ 33.657238] entry_SYSCALL_64_fastpath+0x1f/0xbe [ 33.661963] [ 33.663562] Freed by task 3018: [ 33.666830] save_stack_trace+0x16/0x20 [ 33.670773] save_stack+0x43/0xd0 [ 33.674196] kasan_slab_free+0x71/0xc0 [ 33.678055] kfree+0xca/0x250 [ 33.681130] kvfree+0x36/0x60 [ 33.684208] free_netdev+0x2cf/0x360 [ 33.687893] __tun_chr_ioctl+0x2d30/0x3d70 [ 33.692099] tun_chr_ioctl+0x2a/0x40 [ 33.695791] do_vfs_ioctl+0x1b1/0x1530 [ 33.699650] SyS_ioctl+0x8f/0xc0 [ 33.702992] entry_SYSCALL_64_fastpath+0x1f/0xbe [ 33.707714] [ 33.709312] The buggy address belongs to the object at ffff8801cc8c82c0 [ 33.709312] which belongs to the cache kmalloc-16384 of size 16384 [ 33.722282] The buggy address is located 13320 bytes inside of [ 33.722282] 16384-byte region [ffff8801cc8c82c0, ffff8801cc8cc2c0) [ 33.734472] The buggy address belongs to the page: [ 33.739373] page:ffffea0007323200 count:1 mapcount:0 mapping:ffff8801cc8c82c0 index:0x0 compound_mapcount: 0 [ 33.749320] flags: 0x200000000008100(slab|head) [ 33.753959] raw: 0200000000008100 ffff8801cc8c82c0 0000000000000000 0000000100000001 [ 33.761810] raw: ffffea000750b420 ffffea0007343220 ffff8801dac02200 0000000000000000 [ 33.769658] page dumped because: kasan: bad access detected [ 33.775346] [ 33.776964] Memory state around the buggy address: [ 33.781911] ffff8801cc8cb580: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 33.789245] ffff8801cc8cb600: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 33.796574] >ffff8801cc8cb680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 33.803910] ^ [ 33.809603] ffff8801cc8cb700: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 33.817203] ffff8801cc8cb780: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 33.824540] ================================================================== [ 33.831882] Disabling lock debugging due to kernel taint [ 33.837308] Kernel panic - not syncing: panic_on_warn set ... [ 33.837308] [ 33.844647] CPU: 0 PID: 3018 Comm: syzkaller671964 Tainted: G B 4.13.0+ #68 [ 33.853100] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 33.862424] Call Trace: [ 33.864994] dump_stack+0x194/0x257 [ 33.868599] ? arch_local_irq_restore+0x53/0x53 [ 33.873246] ? vprintk_default+0x28/0x30 [ 33.877278] ? __internal_add_timer+0x250/0x2d0 [ 33.882003] panic+0x1e4/0x417 [ 33.885167] ? __warn+0x1d9/0x1d9 [ 33.888600] ? __internal_add_timer+0x275/0x2d0 [ 33.893243] kasan_end_report+0x50/0x50 [ 33.897190] kasan_report+0x137/0x340 [ 33.900962] __asan_report_store8_noabort+0x17/0x20 [ 33.905943] __internal_add_timer+0x275/0x2d0 [ 33.910405] ? calc_wheel_index+0x200/0x200 [ 33.914696] mod_timer+0x622/0x15b0 [ 33.918292] ? mod_timer_pending+0x14e0/0x14e0 [ 33.922841] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 33.927824] ? trace_hardirqs_on+0xd/0x10 [ 33.931942] ? _crng_backtrack_protect+0xd9/0x130 [ 33.936766] ? __lock_is_held+0xbc/0x140 [ 33.940797] ? __lockdep_init_map+0xe4/0x650 [ 33.945173] ? lockdep_init_map+0x3d/0x70 [ 33.949288] ? rcu_read_lock_sched_held+0x108/0x120 [ 33.954269] ? init_timer_key+0x126/0x3b0 [ 33.958382] ? try_to_del_timer_sync+0x120/0x120 [ 33.963104] ? round_jiffies_up+0xce/0x100 [ 33.967303] ? __round_jiffies_up_relative+0x150/0x150 [ 33.972545] ? debug_lockdep_rcu_enabled+0x77/0x90 [ 33.977445] __tun_chr_ioctl+0x1b2c/0x3d70 [ 33.981651] ? tun_select_queue+0x580/0x580 [ 33.985947] ? lock_downgrade+0x990/0x990 [ 33.990086] ? check_same_owner+0x320/0x320 [ 33.994379] ? __handle_mm_fault+0x3840/0x3840 [ 33.998925] ? vmacache_find+0x61/0x270 [ 34.002868] ? tun_chr_compat_ioctl+0x30/0x30 [ 34.007325] tun_chr_ioctl+0x2a/0x40 [ 34.011006] ? tun_chr_ioctl+0x2a/0x40 [ 34.014862] do_vfs_ioctl+0x1b1/0x1530 [ 34.018718] ? ioctl_preallocate+0x2b0/0x2b0 [ 34.023096] ? selinux_capable+0x40/0x40 [ 34.027134] ? putname+0xf3/0x130 [ 34.030741] ? do_sys_open+0x320/0x6d0 [ 34.034617] ? security_file_ioctl+0x7d/0xb0 [ 34.039000] ? security_file_ioctl+0x89/0xb0 [ 34.043377] SyS_ioctl+0x8f/0xc0 [ 34.046717] entry_SYSCALL_64_fastpath+0x1f/0xbe [ 34.051441] RIP: 0033:0x443d99 [ 34.054598] RSP: 002b:00007ffd67e47a08 EFLAGS: 00000207 ORIG_RAX: 0000000000000010 [ 34.062274] RAX: ffffffffffffffda RBX: ffffffffffffffff RCX: 0000000000443d99 [ 34.069512] RDX: 0000000020822000 RSI: 00000000400454ca RDI: 0000000000000006 [ 34.076755] RBP: 0000000000000082 R08: 0000000000000000 R09: 0000000000000000 [ 34.083994] R10: 0000000000000000 R11: 0000000000000207 R12: 5f6010a0d3dd9153 [ 34.091229] R13: 74656e2f7665642f R14: 0000000000000000 R15: 0000000000000000