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.0.42' (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: [ 30.402854] ================================================================== [ 30.403959] BUG: KASAN: stack-out-of-bounds in xfrm_state_find+0x305b/0x3190 [ 30.404910] Read of size 4 at addr ffff8801ce726898 by task syzkaller084950/3018 [ 30.405899] [ 30.406133] CPU: 1 PID: 3018 Comm: syzkaller084950 Not tainted 4.13.0-mm1+ #7 [ 30.407089] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 30.408309] Call Trace: [ 30.408671] dump_stack+0x194/0x257 [ 30.409172] ? arch_local_irq_restore+0x53/0x53 [ 30.409797] ? show_regs_print_info+0x65/0x65 [ 30.410404] ? lock_release+0xd70/0xd70 [ 30.410940] ? xfrm_state_find+0x305b/0x3190 [ 30.411532] print_address_description+0x73/0x250 [ 30.412182] ? xfrm_state_find+0x305b/0x3190 [ 30.412799] kasan_report+0x24e/0x340 [ 30.413317] __asan_report_load4_noabort+0x14/0x20 [ 30.413997] xfrm_state_find+0x305b/0x3190 [ 30.414592] ? xfrm_state_afinfo_get_rcu+0x160/0x160 [ 30.415272] ? print_usage_bug+0x480/0x480 [ 30.415855] ? __lock_acquire+0x732/0x4620 [ 30.416446] ? debug_check_no_locks_freed+0x3d0/0x3d0 [ 30.417167] ? __lock_acquire+0x732/0x4620 [ 30.417747] ? __lock_acquire+0x732/0x4620 [ 30.418324] ? debug_check_no_locks_freed+0x3d0/0x3d0 [ 30.419029] ? debug_check_no_locks_freed+0x3d0/0x3d0 [ 30.419737] ? check_noncircular+0x20/0x20 [ 30.420306] ? check_noncircular+0x20/0x20 [ 30.421450] xfrm_tmpl_resolve+0x2fb/0xbd0 [ 30.422056] ? __xfrm_decode_session+0x100/0x100 [ 30.422701] ? rcu_read_lock_sched_held+0x108/0x120 [ 30.423372] ? fib_table_lookup+0xa07/0x1a30 [ 30.427756] ? check_noncircular+0x20/0x20 [ 30.431973] xfrm_resolve_and_create_bundle+0x186/0x24b0 [ 30.437394] ? inet_netconf_get_devconf+0x4f0/0x4f0 [ 30.442398] ? xfrm_tmpl_resolve+0xbd0/0xbd0 [ 30.446780] ? lock_downgrade+0x990/0x990 [ 30.450908] ? xfrm_selector_match+0xe00/0xe00 [ 30.455468] ? rcu_read_lock_held+0xa9/0xc0 [ 30.459763] ? find_exception+0x3aa/0x520 [ 30.463896] ? lock_release+0xd70/0xd70 [ 30.467851] ? refcount_inc_not_zero+0xfe/0x180 [ 30.472496] ? xfrm_selector_match+0x3b/0xe00 [ 30.476967] ? xfrm_sk_policy_lookup+0x2cf/0x3d0 [ 30.481699] ? xfrm_selector_match+0xe00/0xe00 [ 30.486254] ? check_noncircular+0x20/0x20 [ 30.490465] ? ip_route_output_key_hash_rcu+0x604/0x2c20 [ 30.495901] xfrm_lookup+0xf0a/0x2540 [ 30.499673] ? xfrm_lookup+0xf0a/0x2540 [ 30.503622] ? ip_route_input_noref+0x1e0/0x1e0 [ 30.508268] ? xfrm_policy_lookup_bytype.constprop.49+0x16f0/0x16f0 [ 30.514645] ? find_held_lock+0x39/0x1d0 [ 30.518687] ? lock_downgrade+0x990/0x990 [ 30.522819] ? selinux_netlbl_sock_rcv_skb+0x9e/0x730 [ 30.527985] ? ip_route_output_key_hash+0x1a6/0x370 [ 30.532979] ? lock_release+0xd70/0xd70 [ 30.536925] ? selinux_nf_register+0x30/0x30 [ 30.541303] ? __lock_acquire+0x732/0x4620 [ 30.545516] ? selinux_sock_rcv_skb_compat+0x2f4/0x480 [ 30.550766] ? ip_route_output_key_hash+0x252/0x370 [ 30.555753] ? ip_route_output_key_hash_rcu+0x2c20/0x2c20 [ 30.561276] xfrm_lookup_route+0x39/0x1a0 [ 30.565401] ip_route_output_flow+0x7c/0xa0 [ 30.569697] inet_csk_route_req+0x5d8/0x990 [ 30.573995] tcp_v4_send_synack+0x1e4/0x270 [ 30.578288] ? tcp_v4_send_check+0x90/0x90 [ 30.582502] ? sk_filter_trim_cap+0x12f/0x9b0 [ 30.586965] ? prandom_u32_state+0x13/0x180 [ 30.591261] tcp_rtx_synack+0x119/0x2e0 [ 30.595208] ? tcp_event_new_data_sent+0x2e0/0x2e0 [ 30.600110] ? __lock_is_held+0xbc/0x140 [ 30.604153] inet_rtx_syn_ack+0x64/0xd0 [ 30.608099] tcp_check_req+0xaf5/0x1630 [ 30.612058] ? tcp_openreq_init_rwin+0xae0/0xae0 [ 30.616786] ? refcount_inc_not_zero+0xfe/0x180 [ 30.621424] ? refcount_add+0x60/0x60 [ 30.625194] ? tcp_v4_reqsk_send_ack+0x3e0/0x3e0 [ 30.629931] ? tcp_filter+0x111/0x160 [ 30.633704] tcp_v4_rcv+0x17b0/0x2f20 [ 30.637476] ? lock_acquire+0x1d5/0x580 [ 30.641439] ? tcp_v4_early_demux+0xa30/0xa30 [ 30.645916] ip_local_deliver_finish+0x2e2/0xba0 [ 30.650647] ? inet_del_offload+0x40/0x40 [ 30.654773] ? nf_hook_slow+0xd3/0x1a0 [ 30.658638] ip_local_deliver+0x1ce/0x6e0 [ 30.662758] ? ip_call_ra_chain+0x6d0/0x6d0 [ 30.667073] ? inet_del_offload+0x40/0x40 [ 30.671200] ip_rcv_finish+0x8db/0x19c0 [ 30.675418] ? ip_local_deliver_finish+0xba0/0xba0 [ 30.680319] ? iptable_nat_ipv4_fn+0x40/0x40 [ 30.684699] ? nf_nat_ipv4_in_range+0xf0/0xf0 [ 30.689162] ? ip_rcv+0xbb0/0x17d0 [ 30.692672] ? find_held_lock+0x39/0x1d0 [ 30.696702] ? tcp_v4_send_synack+0x270/0x270 [ 30.701173] ? nf_nat_ipv4_in+0x1cd/0x270 [ 30.705289] ? iptable_nat_ipv4_fn+0x40/0x40 [ 30.709676] ? nf_hook_slow+0xd3/0x1a0 [ 30.713539] ip_rcv+0xc3f/0x17d0 [ 30.716885] ? ip_local_deliver+0x6e0/0x6e0 [ 30.721179] ? __lock_acquire+0x732/0x4620 [ 30.725395] ? ip_local_deliver_finish+0xba0/0xba0 [ 30.730299] ? ip_local_deliver+0x6e0/0x6e0 [ 30.734603] __netif_receive_skb_core+0x19af/0x33d0 [ 30.739588] ? print_usage_bug+0x480/0x480 [ 30.743802] ? nf_ingress+0x9f0/0x9f0 [ 30.747572] ? save_stack+0x43/0xd0 [ 30.751168] ? kasan_slab_alloc+0x12/0x20 [ 30.755283] ? kmem_cache_alloc+0x12e/0x760 [ 30.759574] ? __build_skb+0x9d/0x450 [ 30.763350] ? build_skb+0x6f/0x260 [ 30.766947] ? tun_build_skb.isra.42+0x92f/0x1690 [ 30.771758] ? tun_get_user+0x1dad/0x2150 [ 30.775874] ? tun_chr_write_iter+0xde/0x190 [ 30.780252] ? vfs_write+0x18f/0x510 [ 30.783935] ? __skb_flow_get_ports+0x151/0x400 [ 30.788576] ? skb_flow_dissector_init+0x280/0x280 [ 30.793478] ? check_noncircular+0x20/0x20 [ 30.797680] ? __skb_flow_get_ports+0x151/0x400 [ 30.802322] ? __skb_flow_dissect+0x85b/0x3bc0 [ 30.806874] ? print_usage_bug+0x480/0x480 [ 30.811092] ? find_held_lock+0x39/0x1d0 [ 30.815136] ? lock_downgrade+0x990/0x990 [ 30.819257] ? debug_check_no_locks_freed+0x3d0/0x3d0 [ 30.824424] ? netif_receive_skb_internal+0x1d7/0x670 [ 30.829602] ? pvclock_read_flags+0x160/0x160 [ 30.834066] ? tun_build_skb.isra.42+0x455/0x1690 [ 30.838984] ? lock_acquire+0x1d5/0x580 [ 30.842928] ? netif_receive_skb_internal+0xa2/0x670 [ 30.848001] ? ktime_get_with_offset+0x2c1/0x420 [ 30.852740] ? lock_release+0xd70/0xd70 [ 30.856683] ? ktime_get+0x3a0/0x3a0 [ 30.860369] ? skb_put+0x149/0x1c0 [ 30.863889] __netif_receive_skb+0x2c/0x1b0 [ 30.868180] ? __netif_receive_skb+0x2c/0x1b0 [ 30.872646] netif_receive_skb_internal+0x10b/0x670 [ 30.877632] ? dev_cpu_dead+0xb00/0xb00 [ 30.881577] ? save_stack_trace+0x16/0x20 [ 30.885694] ? __lock_acquire+0x20fd/0x4620 [ 30.889989] ? is_bpf_text_address+0xa4/0x120 [ 30.894457] ? rcu_pm_notify+0xc0/0xc0 [ 30.898332] ? unwind_get_return_address+0x61/0xa0 [ 30.903251] netif_receive_skb+0xae/0x390 [ 30.907371] ? netif_receive_skb_internal+0x670/0x670 [ 30.912536] ? lock_downgrade+0x990/0x990 [ 30.916657] ? tun_rx_batched.isra.43+0x5c3/0x860 [ 30.921476] tun_rx_batched.isra.43+0x5ed/0x860 [ 30.926117] ? skb_get_hash_perturb+0x9d0/0x9d0 [ 30.930756] ? tun_sock_write_space+0x370/0x370 [ 30.935413] tun_get_user+0x11dd/0x2150 [ 30.939375] ? tun_build_skb.isra.42+0x1690/0x1690 [ 30.944276] ? lock_release+0xd70/0xd70 [ 30.948225] ? tun_chr_close+0x60/0x60 [ 30.952089] ? lock_release+0xd70/0xd70 [ 30.956036] ? __lock_is_held+0xbc/0x140 [ 30.960080] ? __tun_get+0x1d4/0x2e0 [ 30.963764] ? tun_chr_close+0x60/0x60 [ 30.967632] tun_chr_write_iter+0xde/0x190 [ 30.971851] __vfs_write+0x68a/0x970 [ 30.975539] ? kernel_read+0x120/0x120 [ 30.979414] ? avc_policy_seqno+0x9/0x20 [ 30.983447] ? selinux_file_permission+0x82/0x460 [ 30.988272] ? rw_verify_area+0xe5/0x2b0 [ 30.992301] ? __fdget_raw+0x20/0x20 [ 30.995992] vfs_write+0x18f/0x510 [ 30.999517] SyS_write+0xef/0x220 [ 31.002944] ? SyS_read+0x220/0x220 [ 31.006542] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 31.011535] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 31.016270] entry_SYSCALL_64_fastpath+0x1f/0xbe [ 31.020994] RIP: 0033:0x405b91 [ 31.024156] RSP: 002b:00007f40cdd05d90 EFLAGS: 00000293 ORIG_RAX: 0000000000000001 [ 31.031843] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 0000000000405b91 [ 31.039086] RDX: 0000000000000036 RSI: 0000000020002000 RDI: 0000000000000003 [ 31.046327] RBP: 0000000000000082 R08: 0000000000000013 R09: 00007f40cdd06700 [ 31.053569] R10: 00007f40cdd069d0 R11: 0000000000000293 R12: 0000000000000000 [ 31.060812] R13: 00007ffc02a88a4f R14: 00007f40cdd069c0 R15: 0000000000000000 [ 31.068073] [ 31.069669] The buggy address belongs to the page: [ 31.074569] page:ffffea000739c980 count:0 mapcount:0 mapping: (null) index:0xffff8801ce726e80 [ 31.083988] flags: 0x200000000000000() [ 31.087847] raw: 0200000000000000 0000000000000000 ffff8801ce726e80 00000000ffffffff [ 31.095707] raw: dead000000000100 dead000000000200 ffff8801dac00dc0 0000000000000000 [ 31.103561] page dumped because: kasan: bad access detected [ 31.109237] [ 31.110835] Memory state around the buggy address: [ 31.115732] ffff8801ce726780: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 31.123067] ffff8801ce726800: 00 00 00 00 00 00 00 00 f1 f1 f1 f1 00 00 00 00 [ 31.130402] >ffff8801ce726880: 00 00 00 f2 f3 f3 f3 f3 00 00 00 00 00 00 00 f1 [ 31.137993] ^ [ 31.142112] ffff8801ce726900: f1 f1 f1 00 00 00 00 00 00 00 00 00 00 00 f2 f3 [ 31.149450] ffff8801ce726980: f3 f3 f3 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 31.156778] ================================================================== [ 31.164106] Disabling lock debugging due to kernel taint [ 31.169571] Kernel panic - not syncing: panic_on_warn set ... [ 31.169571] [ 31.176901] CPU: 1 PID: 3018 Comm: syzkaller084950 Tainted: G B 4.13.0-mm1+ #7 [ 31.185352] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 31.194678] Call Trace: [ 31.197235] dump_stack+0x194/0x257 [ 31.200829] ? arch_local_irq_restore+0x53/0x53 [ 31.205463] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 31.210185] ? xfrm_state_find+0x2fe0/0x3190 [ 31.214559] panic+0x1e4/0x417 [ 31.217723] ? __warn+0x1d9/0x1d9 [ 31.221156] ? xfrm_state_find+0x305b/0x3190 [ 31.225529] kasan_end_report+0x50/0x50 [ 31.229468] kasan_report+0x137/0x340 [ 31.233234] __asan_report_load4_noabort+0x14/0x20 [ 31.238126] xfrm_state_find+0x305b/0x3190 [ 31.242337] ? xfrm_state_afinfo_get_rcu+0x160/0x160 [ 31.247404] ? print_usage_bug+0x480/0x480 [ 31.251605] ? __lock_acquire+0x732/0x4620 [ 31.255827] ? debug_check_no_locks_freed+0x3d0/0x3d0 [ 31.260996] ? __lock_acquire+0x732/0x4620 [ 31.265212] ? __lock_acquire+0x732/0x4620 [ 31.269414] ? debug_check_no_locks_freed+0x3d0/0x3d0 [ 31.274578] ? debug_check_no_locks_freed+0x3d0/0x3d0 [ 31.279740] ? check_noncircular+0x20/0x20 [ 31.283936] ? check_noncircular+0x20/0x20 [ 31.288140] xfrm_tmpl_resolve+0x2fb/0xbd0 [ 31.292347] ? __xfrm_decode_session+0x100/0x100 [ 31.297073] ? rcu_read_lock_sched_held+0x108/0x120 [ 31.302052] ? fib_table_lookup+0xa07/0x1a30 [ 31.306433] ? check_noncircular+0x20/0x20 [ 31.310635] xfrm_resolve_and_create_bundle+0x186/0x24b0 [ 31.316048] ? inet_netconf_get_devconf+0x4f0/0x4f0 [ 31.321037] ? xfrm_tmpl_resolve+0xbd0/0xbd0 [ 31.325409] ? lock_downgrade+0x990/0x990 [ 31.329526] ? xfrm_selector_match+0xe00/0xe00 [ 31.334071] ? rcu_read_lock_held+0xa9/0xc0 [ 31.338358] ? find_exception+0x3aa/0x520 [ 31.342471] ? lock_release+0xd70/0xd70 [ 31.346413] ? refcount_inc_not_zero+0xfe/0x180 [ 31.351049] ? xfrm_selector_match+0x3b/0xe00 [ 31.355511] ? xfrm_sk_policy_lookup+0x2cf/0x3d0 [ 31.360232] ? xfrm_selector_match+0xe00/0xe00 [ 31.364779] ? check_noncircular+0x20/0x20 [ 31.368978] ? ip_route_output_key_hash_rcu+0x604/0x2c20 [ 31.374395] xfrm_lookup+0xf0a/0x2540 [ 31.378159] ? xfrm_lookup+0xf0a/0x2540 [ 31.382099] ? ip_route_input_noref+0x1e0/0x1e0 [ 31.386735] ? xfrm_policy_lookup_bytype.constprop.49+0x16f0/0x16f0 [ 31.393106] ? find_held_lock+0x39/0x1d0 [ 31.397134] ? lock_downgrade+0x990/0x990 [ 31.401256] ? selinux_netlbl_sock_rcv_skb+0x9e/0x730