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-386-2,10.128.0.44' (ECDSA) to the list of known hosts. executing program executing program syzkaller login: [ 50.529033] ================================================================== [ 50.530164] BUG: KASAN: use-after-free in __internal_add_timer+0x275/0x2d0 [ 50.531120] Write of size 8 at addr ffff8801d231b600 by task syzkaller132690/2981 [ 50.532131] [ 50.532400] CPU: 1 PID: 2981 Comm: syzkaller132690 Not tainted 4.14.0-rc5+ #44 [ 50.533389] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 50.534657] Call Trace: [ 50.535033] dump_stack+0x194/0x257 [ 50.535541] ? arch_local_irq_restore+0x53/0x53 [ 50.536215] ? show_regs_print_info+0x65/0x65 [ 50.536873] ? __kernel_text_address+0xd/0x40 [ 50.537507] ? __internal_add_timer+0x275/0x2d0 [ 50.538152] print_address_description+0x73/0x250 [ 50.538830] ? __internal_add_timer+0x275/0x2d0 [ 50.539482] kasan_report+0x25b/0x340 [ 50.540043] __asan_report_store8_noabort+0x17/0x20 [ 50.540726] __internal_add_timer+0x275/0x2d0 [ 50.541369] ? calc_wheel_index+0x200/0x200 [ 50.541981] mod_timer+0x622/0x15b0 [ 50.542531] ? mod_timer_pending+0x14e0/0x14e0 [ 50.543172] ? __lock_is_held+0xb6/0x140 [ 50.543795] ? __lock_is_held+0xb6/0x140 [ 50.544364] ? __lockdep_init_map+0xe4/0x650 [ 50.544975] ? lockdep_init_map+0x9/0x10 [ 50.545533] ? init_timer_key+0x126/0x3b0 [ 50.546139] ? try_to_del_timer_sync+0x120/0x120 [ 50.546829] ? round_jiffies_up+0xce/0x100 [ 50.547414] ? __round_jiffies_up_relative+0x150/0x150 [ 50.548209] ? debug_lockdep_rcu_enabled+0x77/0x90 [ 50.548886] ? selinux_tun_dev_alloc_security+0x124/0x170 [ 50.552826] __tun_chr_ioctl+0x1b17/0x3d20 [ 50.557072] ? tun_chr_read_iter+0x1e0/0x1e0 [ 50.561467] ? find_held_lock+0x35/0x1d0 [ 50.565530] ? __might_sleep+0x95/0x190 [ 50.569487] ? handle_mm_fault+0x248/0x8d0 [ 50.573713] ? selinux_file_ioctl+0x444/0x690 [ 50.578183] ? __fget_light+0x297/0x380 [ 50.582131] ? selinux_capable+0x40/0x40 [ 50.586176] ? handle_mm_fault+0x410/0x8d0 [ 50.590388] tun_chr_compat_ioctl+0x29/0x30 [ 50.594678] ? tun_chr_compat_ioctl+0x29/0x30 [ 50.599145] compat_SyS_ioctl+0x1d7/0x3290 [ 50.603347] ? up_read+0x1a/0x40 [ 50.606770] ? __tun_chr_ioctl+0x3d20/0x3d20 [ 50.611149] ? do_ioctl+0x60/0x60 [ 50.614572] ? do_fast_syscall_32+0x158/0xf05 [ 50.619036] ? do_ioctl+0x60/0x60 [ 50.622455] do_fast_syscall_32+0x3f2/0xf05 [ 50.626778] ? do_int80_syscall_32+0x940/0x940 [ 50.631328] ? kasan_check_read+0x11/0x20 [ 50.635447] ? syscall_return_slowpath+0x510/0x510 [ 50.640343] ? SyS_rt_sigaction+0x94/0x1b0 [ 50.644545] ? SyS_sigprocmask+0x4b0/0x4b0 [ 50.648750] ? SyS_read+0x184/0x220 [ 50.652346] ? retint_user+0x18/0x20 [ 50.656032] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 50.660850] entry_SYSENTER_compat+0x51/0x60 [ 50.665225] RIP: 0023:0xf7efdc79 [ 50.668556] RSP: 002b:00000000ffce4a2c EFLAGS: 00000282 ORIG_RAX: 0000000000000036 [ 50.676231] RAX: ffffffffffffffda RBX: 0000000000000004 RCX: 00000000400454ca [ 50.683468] RDX: 0000000020464000 RSI: 00000000080ef00c RDI: 000000000000003f [ 50.690706] RBP: 0000000000001000 R08: 0000000000000000 R09: 0000000000000000 [ 50.697942] R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000 [ 50.705178] R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 [ 50.712432] [ 50.714027] Allocated by task 2981: [ 50.717621] save_stack_trace+0x16/0x20 [ 50.721561] save_stack+0x43/0xd0 [ 50.724979] kasan_kmalloc+0xad/0xe0 [ 50.728657] __kmalloc_node+0x47/0x70 [ 50.732433] kvmalloc_node+0x64/0xd0 [ 50.736113] alloc_netdev_mqs+0x16e/0xed0 [ 50.740225] __tun_chr_ioctl+0x12b2/0x3d20 [ 50.744423] tun_chr_compat_ioctl+0x29/0x30 [ 50.748711] compat_SyS_ioctl+0x1d7/0x3290 [ 50.752911] do_fast_syscall_32+0x3f2/0xf05 [ 50.757199] entry_SYSENTER_compat+0x51/0x60 [ 50.761569] [ 50.763161] Freed by task 2981: [ 50.766404] save_stack_trace+0x16/0x20 [ 50.770342] save_stack+0x43/0xd0 [ 50.773761] kasan_slab_free+0x71/0xc0 [ 50.777610] kfree+0xca/0x250 [ 50.780681] kvfree+0x36/0x60 [ 50.783752] free_netdev+0x2cf/0x360 [ 50.787430] __tun_chr_ioctl+0x2cea/0x3d20 [ 50.791629] tun_chr_compat_ioctl+0x29/0x30 [ 50.795915] compat_SyS_ioctl+0x1d7/0x3290 [ 50.800116] do_fast_syscall_32+0x3f2/0xf05 [ 50.804405] entry_SYSENTER_compat+0x51/0x60 [ 50.808773] [ 50.810369] The buggy address belongs to the object at ffff8801d23182c0 [ 50.810369] which belongs to the cache kmalloc-16384 of size 16384 [ 50.823337] The buggy address is located 13120 bytes inside of [ 50.823337] 16384-byte region [ffff8801d23182c0, ffff8801d231c2c0) [ 50.835521] The buggy address belongs to the page: [ 50.840416] page:ffffea000748c600 count:1 mapcount:0 mapping:ffff8801d23182c0 index:0x0 compound_mapcount: 0 [ 50.850351] flags: 0x200000000008100(slab|head) [ 50.854985] raw: 0200000000008100 ffff8801d23182c0 0000000000000000 0000000100000001 [ 50.862831] raw: ffffea0007019a20 ffffea0007483a20 ffff8801dac02200 0000000000000000 [ 50.870673] page dumped because: kasan: bad access detected [ 50.876344] [ 50.877935] Memory state around the buggy address: [ 50.882831] ffff8801d231b500: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 50.890154] ffff8801d231b580: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 50.897475] >ffff8801d231b600: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 50.904796] ^ [ 50.908128] ffff8801d231b680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 50.915452] ffff8801d231b700: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 50.922775] ================================================================== [ 50.930095] Disabling lock debugging due to kernel taint [ 50.935508] Kernel panic - not syncing: panic_on_warn set ... [ 50.935508] [ 50.942834] CPU: 1 PID: 2981 Comm: syzkaller132690 Tainted: G B 4.14.0-rc5+ #44 [ 50.951374] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 50.960692] Call Trace: [ 50.963251] dump_stack+0x194/0x257 [ 50.966846] ? arch_local_irq_restore+0x53/0x53 [ 50.971477] ? kasan_end_report+0x32/0x50 [ 50.975592] ? lock_downgrade+0x990/0x990 [ 50.979710] ? __internal_add_timer+0x1c0/0x2d0 [ 50.984346] panic+0x1e4/0x417 [ 50.987506] ? __warn+0x1d9/0x1d9 [ 50.990930] ? __internal_add_timer+0x275/0x2d0 [ 50.995560] kasan_end_report+0x50/0x50 [ 50.999497] kasan_report+0x144/0x340 [ 51.003263] __asan_report_store8_noabort+0x17/0x20 [ 51.008244] __internal_add_timer+0x275/0x2d0 [ 51.012704] ? calc_wheel_index+0x200/0x200 [ 51.016998] mod_timer+0x622/0x15b0 [ 51.020595] ? mod_timer_pending+0x14e0/0x14e0 [ 51.025143] ? __lock_is_held+0xb6/0x140 [ 51.029174] ? __lock_is_held+0xb6/0x140 [ 51.033202] ? __lockdep_init_map+0xe4/0x650 [ 51.037576] ? lockdep_init_map+0x9/0x10 [ 51.041601] ? init_timer_key+0x126/0x3b0 [ 51.045715] ? try_to_del_timer_sync+0x120/0x120 [ 51.050435] ? round_jiffies_up+0xce/0x100 [ 51.054633] ? __round_jiffies_up_relative+0x150/0x150 [ 51.059872] ? debug_lockdep_rcu_enabled+0x77/0x90 [ 51.064767] ? selinux_tun_dev_alloc_security+0x124/0x170 [ 51.070358] __tun_chr_ioctl+0x1b17/0x3d20 [ 51.074558] ? tun_chr_read_iter+0x1e0/0x1e0 [ 51.078929] ? find_held_lock+0x35/0x1d0 [ 51.082958] ? __might_sleep+0x95/0x190 [ 51.086895] ? handle_mm_fault+0x248/0x8d0 [ 51.091097] ? selinux_file_ioctl+0x444/0x690 [ 51.095559] ? __fget_light+0x297/0x380 [ 51.099496] ? selinux_capable+0x40/0x40 [ 51.103524] ? handle_mm_fault+0x410/0x8d0 [ 51.107726] tun_chr_compat_ioctl+0x29/0x30 [ 51.112013] ? tun_chr_compat_ioctl+0x29/0x30 [ 51.116475] compat_SyS_ioctl+0x1d7/0x3290 [ 51.120675] ? up_read+0x1a/0x40 [ 51.124006] ? __tun_chr_ioctl+0x3d20/0x3d20 [ 51.128377] ? do_ioctl+0x60/0x60 [ 51.131796] ? do_fast_syscall_32+0x158/0xf05 [ 51.136260] ? do_ioctl+0x60/0x60 [ 51.139679] do_fast_syscall_32+0x3f2/0xf05 [ 51.143968] ? do_int80_syscall_32+0x940/0x940 [ 51.148515] ? kasan_check_read+0x11/0x20 [ 51.152631] ? syscall_return_slowpath+0x510/0x510 [ 51.157526] ? SyS_rt_sigaction+0x94/0x1b0 [ 51.161727] ? SyS_sigprocmask+0x4b0/0x4b0 [ 51.165925] ? SyS_read+0x184/0x220 [ 51.169518] ? retint_user+0x18/0x20 [ 51.173196] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 51.178008] entry_SYSENTER_compat+0x51/0x60 [ 51.182382] RIP: 0023:0xf7efdc79 [ 51.185709] RSP: 002b:00000000ffce4a2c EFLAGS: 00000282 ORIG_RAX: 0000000000000036 [ 51.194451] RAX: ffffffffffffffda RBX: 0000000000000004 RCX: 00000000400454ca [ 51.201692] RDX: 0000000020464000 RSI: 00000000080ef00c RDI: 000000000000003f [ 51.208929] RBP: 0000000000001000 R08: 0000000000000000 R09: 0000000000000000 [ 51.216163] R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000 [ 51.223397] R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 [ 51.230688] Dumping ftrace buffer: [ 51.234194] (ftrace buffer empty) [ 51.237871] Kernel Offset: disabled [ 51.241466] Rebooting in 86400 seconds..