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-mmots-kasan-gce-8,10.128.15.202' (ECDSA) to the list of known hosts. net.ipv6.conf.syz0.accept_dad = 0 net.ipv6.conf.syz0.router_solicitations = 0 executing program syzkaller login: [ 52.030428] ================================================================== [ 52.037853] BUG: KASAN: stack-out-of-bounds in xfrm_state_find+0x305b/0x3190 [ 52.045016] Read of size 4 at addr ffff8801cd6d6898 by task syzkaller670798/3022 [ 52.052521] [ 52.054127] CPU: 0 PID: 3022 Comm: syzkaller670798 Not tainted 4.13.0-mm1+ #5 [ 52.061373] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 52.070705] Call Trace: [ 52.073269] dump_stack+0x194/0x257 [ 52.076876] ? arch_local_irq_restore+0x53/0x53 [ 52.081518] ? show_regs_print_info+0x65/0x65 [ 52.086004] ? lock_release+0xd70/0xd70 [ 52.089955] ? print_usage_bug+0x480/0x480 [ 52.094173] ? xfrm_state_find+0x305b/0x3190 [ 52.098572] print_address_description+0x73/0x250 [ 52.103397] ? xfrm_state_find+0x305b/0x3190 [ 52.107787] kasan_report+0x24e/0x340 [ 52.111571] __asan_report_load4_noabort+0x14/0x20 [ 52.116484] xfrm_state_find+0x305b/0x3190 [ 52.120725] ? xfrm_state_afinfo_get_rcu+0x160/0x160 [ 52.125810] ? print_usage_bug+0x480/0x480 [ 52.130029] ? __lock_acquire+0x732/0x4620 [ 52.134268] ? debug_check_no_locks_freed+0x3d0/0x3d0 [ 52.139450] ? __lock_acquire+0x732/0x4620 [ 52.143673] ? __lock_acquire+0x732/0x4620 [ 52.147893] ? debug_check_no_locks_freed+0x3d0/0x3d0 [ 52.153067] ? debug_check_no_locks_freed+0x3d0/0x3d0 [ 52.158249] ? check_noncircular+0x20/0x20 [ 52.162454] ? check_noncircular+0x20/0x20 [ 52.166674] xfrm_tmpl_resolve+0x2fb/0xbd0 [ 52.170900] ? __xfrm_decode_session+0x100/0x100 [ 52.175638] ? rcu_read_lock_sched_held+0x108/0x120 [ 52.180630] ? fib_table_lookup+0xa07/0x1a30 [ 52.185016] ? check_noncircular+0x20/0x20 [ 52.189246] xfrm_resolve_and_create_bundle+0x186/0x24b0 [ 52.194673] ? inet_netconf_get_devconf+0x4f0/0x4f0 [ 52.199681] ? xfrm_tmpl_resolve+0xbd0/0xbd0 [ 52.204070] ? lock_downgrade+0x990/0x990 [ 52.208202] ? xfrm_selector_match+0xe00/0xe00 [ 52.212762] ? rcu_read_lock_held+0xa9/0xc0 [ 52.217059] ? find_exception+0x3aa/0x520 [ 52.221186] ? lock_release+0xd70/0xd70 [ 52.225139] ? refcount_inc_not_zero+0xfe/0x180 [ 52.229788] ? xfrm_selector_match+0x3b/0xe00 [ 52.234273] ? xfrm_sk_policy_lookup+0x2cf/0x3d0 [ 52.239006] ? xfrm_selector_match+0xe00/0xe00 [ 52.243565] ? check_noncircular+0x20/0x20 [ 52.247771] ? ip_route_output_key_hash_rcu+0x604/0x2c20 [ 52.253237] xfrm_lookup+0xf0a/0x2540 [ 52.257009] ? xfrm_lookup+0xf0a/0x2540 [ 52.260956] ? ip_route_input_noref+0x1e0/0x1e0 [ 52.265609] ? xfrm_policy_lookup_bytype.constprop.49+0x16f0/0x16f0 [ 52.271995] ? find_held_lock+0x39/0x1d0 [ 52.276041] ? lock_downgrade+0x990/0x990 [ 52.280163] ? selinux_netlbl_sock_rcv_skb+0x9e/0x730 [ 52.285331] ? ip_route_output_key_hash+0x1a6/0x370 [ 52.290590] ? lock_release+0xd70/0xd70 [ 52.294537] ? selinux_nf_register+0x30/0x30 [ 52.298915] ? __lock_acquire+0x732/0x4620 [ 52.303128] ? selinux_sock_rcv_skb_compat+0x2f4/0x480 [ 52.308382] ? ip_route_output_key_hash+0x252/0x370 [ 52.313389] ? ip_route_output_key_hash_rcu+0x2c20/0x2c20 [ 52.318909] xfrm_lookup_route+0x39/0x1a0 [ 52.323032] ip_route_output_flow+0x7c/0xa0 [ 52.327344] inet_csk_route_req+0x5d8/0x990 [ 52.331644] tcp_v4_send_synack+0x1e4/0x270 [ 52.335940] ? tcp_v4_send_check+0x90/0x90 [ 52.340161] ? sk_filter_trim_cap+0x12f/0x9b0 [ 52.344655] ? prandom_u32_state+0x13/0x180 [ 52.348974] tcp_rtx_synack+0x119/0x2e0 [ 52.352921] ? tcp_event_new_data_sent+0x2e0/0x2e0 [ 52.357826] ? __lock_is_held+0xbc/0x140 [ 52.361872] inet_rtx_syn_ack+0x64/0xd0 [ 52.365822] tcp_check_req+0xaf5/0x1630 [ 52.369773] ? tcp_openreq_init_rwin+0xae0/0xae0 [ 52.374529] ? refcount_inc_not_zero+0xfe/0x180 [ 52.379181] ? refcount_add+0x60/0x60 [ 52.382972] ? tcp_v4_reqsk_send_ack+0x3e0/0x3e0 [ 52.387703] ? tcp_filter+0x111/0x160 [ 52.391486] tcp_v4_rcv+0x1f57/0x2f20 [ 52.395261] ? lock_acquire+0x1d5/0x580 [ 52.399240] ? tcp_v4_early_demux+0xa30/0xa30 [ 52.403719] ip_local_deliver_finish+0x2e2/0xba0 [ 52.408450] ? inet_del_offload+0x40/0x40 [ 52.412623] ? nf_hook_slow+0xd3/0x1a0 [ 52.416497] ip_local_deliver+0x1ce/0x6e0 [ 52.420650] ? ip_call_ra_chain+0x6d0/0x6d0 [ 52.424960] ? inet_del_offload+0x40/0x40 [ 52.429092] ip_rcv_finish+0x8db/0x19c0 [ 52.433043] ? ip_local_deliver_finish+0xba0/0xba0 [ 52.437944] ? iptable_nat_ipv4_fn+0x40/0x40 [ 52.442327] ? nf_nat_ipv4_in_range+0xf0/0xf0 [ 52.446802] ? ip_rcv+0xbe0/0x17d0 [ 52.450317] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 52.455045] ? tcp_v4_send_synack+0x270/0x270 [ 52.459551] ? nf_nat_ipv4_in+0x1cd/0x270 [ 52.463671] ? iptable_nat_ipv4_fn+0x40/0x40 [ 52.468061] ? nf_hook_slow+0xd3/0x1a0 [ 52.471923] ip_rcv+0xc3f/0x17d0 [ 52.475266] ? ip_local_deliver+0x6e0/0x6e0 [ 52.479564] ? __lock_acquire+0x732/0x4620 [ 52.483783] ? ip_local_deliver_finish+0xba0/0xba0 [ 52.488686] ? ip_local_deliver+0x6e0/0x6e0 [ 52.492985] __netif_receive_skb_core+0x19af/0x33d0 [ 52.497987] ? print_usage_bug+0x480/0x480 [ 52.502204] ? nf_ingress+0x9f0/0x9f0 [ 52.505977] ? save_stack+0x43/0xd0 [ 52.509575] ? kasan_slab_alloc+0x12/0x20 [ 52.513694] ? kmem_cache_alloc+0x12e/0x760 [ 52.517989] ? __build_skb+0x9d/0x450 [ 52.521757] ? build_skb+0x6f/0x260 [ 52.525353] ? tun_build_skb.isra.42+0x92f/0x1690 [ 52.530165] ? tun_get_user+0x1dad/0x2150 [ 52.534285] ? tun_chr_write_iter+0xde/0x190 [ 52.538667] ? vfs_write+0x18f/0x510 [ 52.542353] ? __skb_flow_get_ports+0x151/0x400 [ 52.546995] ? skb_flow_dissector_init+0x280/0x280 [ 52.551901] ? check_noncircular+0x20/0x20 [ 52.556108] ? __skb_flow_get_ports+0x151/0x400 [ 52.560765] ? __skb_flow_dissect+0x85b/0x3bc0 [ 52.565320] ? print_usage_bug+0x480/0x480 [ 52.569540] ? find_held_lock+0x39/0x1d0 [ 52.573581] ? lock_downgrade+0x990/0x990 [ 52.577700] ? debug_check_no_locks_freed+0x3d0/0x3d0 [ 52.582865] ? netif_receive_skb_internal+0x1d7/0x5e0 [ 52.588042] ? pvclock_read_flags+0x160/0x160 [ 52.592508] ? tun_build_skb.isra.42+0x455/0x1690 [ 52.597329] ? lock_acquire+0x1d5/0x580 [ 52.601275] ? netif_receive_skb_internal+0x93/0x5e0 [ 52.606351] ? ktime_get_with_offset+0x2c1/0x420 [ 52.611085] ? lock_release+0xd70/0xd70 [ 52.615032] ? ktime_get+0x3a0/0x3a0 [ 52.618718] ? skb_put+0x149/0x1c0 [ 52.622240] __netif_receive_skb+0x2c/0x1b0 [ 52.626533] ? __netif_receive_skb+0x2c/0x1b0 [ 52.631003] netif_receive_skb_internal+0x10b/0x5e0 [ 52.635991] ? __lru_cache_add+0x2a4/0x410 [ 52.640195] ? dev_cpu_dead+0xb00/0xb00 [ 52.644141] ? __pagevec_lru_add+0x30/0x30 [ 52.648371] ? get_mem_cgroup_from_mm+0x49b/0x710 [ 52.653185] ? rcu_pm_notify+0xc0/0xc0 [ 52.657055] netif_receive_skb+0xae/0x390 [ 52.661175] ? netif_receive_skb_internal+0x5e0/0x5e0 [ 52.666355] ? lock_downgrade+0x990/0x990 [ 52.670494] ? tun_rx_batched.isra.43+0x5c3/0x860 [ 52.675309] tun_rx_batched.isra.43+0x5ed/0x860 [ 52.679951] ? skb_get_hash_perturb+0x9d0/0x9d0 [ 52.684596] ? tun_sock_write_space+0x370/0x370 [ 52.689273] tun_get_user+0x11dd/0x2150 [ 52.693236] ? tun_build_skb.isra.42+0x1690/0x1690 [ 52.698136] ? lock_release+0xd70/0xd70 [ 52.702088] ? tun_chr_close+0x60/0x60 [ 52.705952] ? lock_release+0xd70/0xd70 [ 52.709899] ? __lock_is_held+0xbc/0x140 [ 52.713942] ? __tun_get+0x1d4/0x2e0 [ 52.717623] ? tun_chr_close+0x60/0x60 [ 52.721492] tun_chr_write_iter+0xde/0x190 [ 52.725704] __vfs_write+0x68a/0x970 [ 52.729408] ? default_llseek+0x2a0/0x2a0 [ 52.733554] ? avc_policy_seqno+0x9/0x20 [ 52.737589] ? selinux_file_permission+0x82/0x460 [ 52.742414] ? rw_verify_area+0xe5/0x2b0 [ 52.746449] ? __fdget_raw+0x20/0x20 [ 52.750137] vfs_write+0x18f/0x510 [ 52.753669] SyS_write+0xef/0x220 [ 52.757095] ? lockdep_sys_exit+0x47/0xf0 [ 52.761216] ? SyS_read+0x220/0x220 [ 52.764813] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 52.769804] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 52.774542] entry_SYSCALL_64_fastpath+0x1f/0xbe [ 52.779266] RIP: 0033:0x405b91 [ 52.782428] RSP: 002b:00007f023c6bad90 EFLAGS: 00000293 ORIG_RAX: 0000000000000001 [ 52.790111] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 0000000000405b91 [ 52.797350] RDX: 0000000000000036 RSI: 0000000020002000 RDI: 0000000000000003 [ 52.804590] RBP: 0000000000000082 R08: 0000000000000013 R09: 00007f023c6bb700 [ 52.811831] R10: 00007f023c6bb9d0 R11: 0000000000000293 R12: 0000000000000000 [ 52.819070] R13: 00007ffffc3e390f R14: 00007f023c6bb9c0 R15: 0000000000000000 [ 52.826329] [ 52.827926] The buggy address belongs to the page: [ 52.832828] page:ffffea000735b580 count:0 mapcount:0 mapping: (null) index:0xffff8801cd6d6ec0 [ 52.842248] flags: 0x200000000000000() [ 52.846113] raw: 0200000000000000 0000000000000000 ffff8801cd6d6ec0 00000000ffffffff [ 52.853967] raw: dead000000000100 dead000000000200 0000000000000000 0000000000000000 [ 52.861816] page dumped because: kasan: bad access detected [ 52.867500] [ 52.869097] Memory state around the buggy address: [ 52.873997] ffff8801cd6d6780: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 52.881323] ffff8801cd6d6800: 00 00 00 00 00 00 00 00 f1 f1 f1 f1 00 00 00 00 [ 52.888659] >ffff8801cd6d6880: 00 00 00 f2 f3 f3 f3 f3 00 00 00 00 00 00 00 f1 [ 52.895992] ^ [ 52.900109] ffff8801cd6d6900: f1 f1 f1 00 00 00 00 00 00 00 00 00 00 00 f2 f3 [ 52.907449] ffff8801cd6d6980: f3 f3 f3 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 52.914780] ================================================================== [ 52.922111] Disabling lock debugging due to kernel taint [ 52.927567] Kernel panic - not syncing: panic_on_warn set ... [ 52.927567] [ 52.934898] CPU: 0 PID: 3022 Comm: syzkaller670798 Tainted: G B 4.13.0-mm1+ #5 [ 52.943348] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 52.952667] Call Trace: [ 52.955222] dump_stack+0x194/0x257 [ 52.958817] ? arch_local_irq_restore+0x53/0x53 [ 52.963464] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 52.968186] ? xfrm_state_find+0x2fb0/0x3190 [ 52.972559] panic+0x1e4/0x417 [ 52.975718] ? __warn+0x1d9/0x1d9 [ 52.979142] ? xfrm_state_find+0x305b/0x3190 [ 52.983515] kasan_end_report+0x50/0x50 [ 52.987456] kasan_report+0x137/0x340 [ 52.991231] __asan_report_load4_noabort+0x14/0x20 [ 52.996127] xfrm_state_find+0x305b/0x3190 [ 53.000342] ? xfrm_state_afinfo_get_rcu+0x160/0x160 [ 53.005411] ? print_usage_bug+0x480/0x480 [ 53.009612] ? __lock_acquire+0x732/0x4620 [ 53.013824] ? debug_check_no_locks_freed+0x3d0/0x3d0 [ 53.018985] ? __lock_acquire+0x732/0x4620 [ 53.023191] ? __lock_acquire+0x732/0x4620 [ 53.027395] ? debug_check_no_locks_freed+0x3d0/0x3d0