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.45' (ECDSA) to the list of known hosts. executing program syzkaller login: [ 43.252569] ================================================================== [ 43.259974] BUG: KASAN: use-after-free in __internal_add_timer+0x275/0x2d0 [ 43.266956] Write of size 8 at addr ffff8801cfcbb688 by task syzkaller318769/2992 [ 43.274544] [ 43.276145] CPU: 0 PID: 2992 Comm: syzkaller318769 Not tainted 4.14.0-rc4+ #38 [ 43.283472] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 43.292795] Call Trace: [ 43.295358] dump_stack+0x194/0x257 [ 43.298962] ? arch_local_irq_restore+0x53/0x53 [ 43.303603] ? show_regs_print_info+0x65/0x65 [ 43.308083] ? __internal_add_timer+0x275/0x2d0 [ 43.313334] print_address_description+0x73/0x250 [ 43.318148] ? __internal_add_timer+0x275/0x2d0 [ 43.322789] kasan_report+0x25b/0x340 [ 43.326564] __asan_report_store8_noabort+0x17/0x20 [ 43.331549] __internal_add_timer+0x275/0x2d0 [ 43.336019] ? calc_wheel_index+0x200/0x200 [ 43.340327] mod_timer+0x622/0x15b0 [ 43.343933] ? mod_timer_pending+0x14e0/0x14e0 [ 43.348485] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 43.353473] ? trace_hardirqs_on+0xd/0x10 [ 43.357594] ? _crng_backtrack_protect+0xd9/0x130 [ 43.362414] ? __lock_is_held+0xbc/0x140 [ 43.366449] ? __lockdep_init_map+0xe4/0x650 [ 43.370830] ? lockdep_init_map+0x3d/0x70 [ 43.374949] ? rcu_read_lock_sched_held+0x108/0x120 [ 43.379936] ? init_timer_key+0x126/0x3b0 [ 43.384057] ? try_to_del_timer_sync+0x120/0x120 [ 43.388785] ? round_jiffies_up+0xce/0x100 [ 43.392990] ? __round_jiffies_up_relative+0x150/0x150 [ 43.398238] ? debug_lockdep_rcu_enabled+0x77/0x90 [ 43.403147] __tun_chr_ioctl+0x1b23/0x3d20 [ 43.407361] ? tun_chr_read_iter+0x1e0/0x1e0 [ 43.411744] ? find_held_lock+0x39/0x1d0 [ 43.415783] ? __might_sleep+0x95/0x190 [ 43.419737] ? selinux_file_ioctl+0x444/0x690 [ 43.424203] ? __fget_light+0x29d/0x390 [ 43.428150] ? selinux_capable+0x40/0x40 [ 43.432191] ? handle_mm_fault+0x410/0x8d0 [ 43.436394] ? down_read_trylock+0xdb/0x170 [ 43.440692] tun_chr_compat_ioctl+0x29/0x30 [ 43.444982] ? tun_chr_compat_ioctl+0x29/0x30 [ 43.449450] compat_SyS_ioctl+0x1d7/0x3290 [ 43.453651] ? up_read+0x1a/0x40 [ 43.456989] ? __tun_chr_ioctl+0x3d20/0x3d20 [ 43.461372] ? do_ioctl+0x60/0x60 [ 43.464797] ? do_fast_syscall_32+0x158/0xf05 [ 43.469266] ? do_ioctl+0x60/0x60 [ 43.472693] do_fast_syscall_32+0x3f2/0xf05 [ 43.476991] ? do_int80_syscall_32+0x940/0x940 [ 43.481547] ? lockdep_sys_exit+0x47/0xf0 [ 43.485664] ? syscall_return_slowpath+0x2b3/0x510 [ 43.490561] ? finish_task_switch+0x1aa/0x740 [ 43.495029] ? lockdep_sys_exit+0x47/0xf0 [ 43.499146] ? retint_user+0x18/0x20 [ 43.502833] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 43.507651] entry_SYSENTER_compat+0x51/0x60 [ 43.512026] RIP: 0023:0xf7f69c79 [ 43.515358] RSP: 002b:00000000f576013c EFLAGS: 00000246 ORIG_RAX: 0000000000000036 [ 43.523036] RAX: ffffffffffffffda RBX: 0000000000000004 RCX: 00000000400454ca [ 43.530276] RDX: 00000000205bafd8 RSI: 0000000000000000 RDI: 0000000000000000 [ 43.537517] RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000000 [ 43.544756] R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000 [ 43.551993] R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 [ 43.559251] [ 43.560849] Allocated by task 2989: [ 43.564448] save_stack_trace+0x16/0x20 [ 43.568390] save_stack+0x43/0xd0 [ 43.571813] kasan_kmalloc+0xad/0xe0 [ 43.575495] __kmalloc_node+0x47/0x70 [ 43.579265] kvmalloc_node+0x64/0xd0 [ 43.582952] alloc_netdev_mqs+0x16e/0xed0 [ 43.587073] __tun_chr_ioctl+0x12be/0x3d20 [ 43.591277] tun_chr_compat_ioctl+0x29/0x30 [ 43.595568] compat_SyS_ioctl+0x1d7/0x3290 [ 43.599771] do_fast_syscall_32+0x3f2/0xf05 [ 43.604059] entry_SYSENTER_compat+0x51/0x60 [ 43.608430] [ 43.610028] Freed by task 2989: [ 43.613277] save_stack_trace+0x16/0x20 [ 43.617221] save_stack+0x43/0xd0 [ 43.620641] kasan_slab_free+0x71/0xc0 [ 43.624496] kfree+0xca/0x250 [ 43.627573] kvfree+0x36/0x60 [ 43.630648] free_netdev+0x2cf/0x360 [ 43.634330] __tun_chr_ioctl+0x2cf6/0x3d20 [ 43.638531] tun_chr_compat_ioctl+0x29/0x30 [ 43.642818] compat_SyS_ioctl+0x1d7/0x3290 [ 43.647020] do_fast_syscall_32+0x3f2/0xf05 [ 43.651310] entry_SYSENTER_compat+0x51/0x60 [ 43.655683] [ 43.657284] The buggy address belongs to the object at ffff8801cfcb8280 [ 43.657284] which belongs to the cache kmalloc-16384 of size 16384 [ 43.670253] The buggy address is located 13320 bytes inside of [ 43.670253] 16384-byte region [ffff8801cfcb8280, ffff8801cfcbc280) [ 43.682442] The buggy address belongs to the page: [ 43.687339] page:ffffea00073f2e00 count:1 mapcount:0 mapping:ffff8801cfcb8280 index:0x0 compound_mapcount: 0 [ 43.697282] flags: 0x200000000008100(slab|head) [ 43.701922] raw: 0200000000008100 ffff8801cfcb8280 0000000000000000 0000000100000001 [ 43.709771] raw: ffffea000756f220 ffffea00073af620 ffff8801dac02200 0000000000000000 [ 43.717618] page dumped because: kasan: bad access detected [ 43.723294] [ 43.724891] Memory state around the buggy address: [ 43.729791] ffff8801cfcbb580: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 43.737121] ffff8801cfcbb600: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 43.744449] >ffff8801cfcbb680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 43.751774] ^ [ 43.755368] ffff8801cfcbb700: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 43.762694] ffff8801cfcbb780: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 43.770018] ================================================================== [ 43.777341] Disabling lock debugging due to kernel taint [ 43.782752] Kernel panic - not syncing: panic_on_warn set ... [ 43.782752] [ 43.790077] CPU: 0 PID: 2992 Comm: syzkaller318769 Tainted: G B 4.14.0-rc4+ #38 [ 43.798612] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 43.807928] Call Trace: [ 43.810479] dump_stack+0x194/0x257 [ 43.814071] ? arch_local_irq_restore+0x53/0x53 [ 43.818703] ? vprintk_default+0x28/0x30 [ 43.822728] ? __internal_add_timer+0x1f0/0x2d0 [ 43.827362] panic+0x1e4/0x417 [ 43.830522] ? __warn+0x1d9/0x1d9 [ 43.833945] ? __internal_add_timer+0x275/0x2d0 [ 43.838577] kasan_end_report+0x50/0x50 [ 43.842514] kasan_report+0x144/0x340 [ 43.846281] __asan_report_store8_noabort+0x17/0x20 [ 43.851260] __internal_add_timer+0x275/0x2d0 [ 43.855718] ? calc_wheel_index+0x200/0x200 [ 43.860009] mod_timer+0x622/0x15b0 [ 43.863602] ? mod_timer_pending+0x14e0/0x14e0 [ 43.868148] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 43.873129] ? trace_hardirqs_on+0xd/0x10 [ 43.877242] ? _crng_backtrack_protect+0xd9/0x130 [ 43.882054] ? __lock_is_held+0xbc/0x140 [ 43.886079] ? __lockdep_init_map+0xe4/0x650 [ 43.890454] ? lockdep_init_map+0x3d/0x70 [ 43.894566] ? rcu_read_lock_sched_held+0x108/0x120 [ 43.899546] ? init_timer_key+0x126/0x3b0 [ 43.903658] ? try_to_del_timer_sync+0x120/0x120 [ 43.908377] ? round_jiffies_up+0xce/0x100 [ 43.912573] ? __round_jiffies_up_relative+0x150/0x150 [ 43.917812] ? debug_lockdep_rcu_enabled+0x77/0x90 [ 43.922708] __tun_chr_ioctl+0x1b23/0x3d20 [ 43.926911] ? tun_chr_read_iter+0x1e0/0x1e0 [ 43.931282] ? find_held_lock+0x39/0x1d0 [ 43.935310] ? __might_sleep+0x95/0x190 [ 43.939254] ? selinux_file_ioctl+0x444/0x690 [ 43.943712] ? __fget_light+0x29d/0x390 [ 43.947651] ? selinux_capable+0x40/0x40 [ 43.951681] ? handle_mm_fault+0x410/0x8d0 [ 43.955877] ? down_read_trylock+0xdb/0x170 [ 43.960166] tun_chr_compat_ioctl+0x29/0x30 [ 43.964450] ? tun_chr_compat_ioctl+0x29/0x30 [ 43.968911] compat_SyS_ioctl+0x1d7/0x3290 [ 43.973110] ? up_read+0x1a/0x40 [ 43.976440] ? __tun_chr_ioctl+0x3d20/0x3d20 [ 43.980811] ? do_ioctl+0x60/0x60 [ 43.984228] ? do_fast_syscall_32+0x158/0xf05 [ 43.988690] ? do_ioctl+0x60/0x60 [ 43.992108] do_fast_syscall_32+0x3f2/0xf05 [ 43.996399] ? do_int80_syscall_32+0x940/0x940 [ 44.000949] ? lockdep_sys_exit+0x47/0xf0 [ 44.005064] ? syscall_return_slowpath+0x2b3/0x510 [ 44.009957] ? finish_task_switch+0x1aa/0x740 [ 44.014416] ? lockdep_sys_exit+0x47/0xf0 [ 44.018531] ? retint_user+0x18/0x20 [ 44.022214] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 44.028327] entry_SYSENTER_compat+0x51/0x60 [ 44.032697] RIP: 0023:0xf7f69c79 [ 44.036028] RSP: 002b:00000000f576013c EFLAGS: 00000246 ORIG_RAX: 0000000000000036 [ 44.043699] RAX: ffffffffffffffda RBX: 0000000000000004 RCX: 00000000400454ca [ 44.050933] RDX: 00000000205bafd8 RSI: 0000000000000000 RDI: 0000000000000000 [ 44.058165] RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000000 [ 44.065398] R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000 [ 44.072631] R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 [ 44.079908] Dumping ftrace buffer: [ 44.083414] (ftrace buffer empty) [ 44.087091] Kernel Offset: disabled [ 44.090684] Rebooting in 86400 seconds..