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.0.46' (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: [ 31.112300] ================================================================== [ 31.113454] BUG: KASAN: stack-out-of-bounds in xfrm_state_find+0x303d/0x3170 [ 31.114500] Read of size 4 at addr ffff8801d116e5e8 by task syzkaller768349/2950 [ 31.115583] [ 31.115839] CPU: 0 PID: 2950 Comm: syzkaller768349 Not tainted 4.13.0-rc4+ #30 [ 31.116862] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 31.118179] Call Trace: [ 31.118574] dump_stack+0x194/0x257 [ 31.119106] ? arch_local_irq_restore+0x53/0x53 [ 31.119731] ? show_regs_print_info+0x65/0x65 [ 31.120339] ? lock_release+0xa40/0xa40 [ 31.120873] ? xfrm_state_find+0x303d/0x3170 [ 31.121482] print_address_description+0x7f/0x260 [ 31.122247] ? xfrm_state_find+0x303d/0x3170 [ 31.122977] kasan_report+0x24e/0x340 [ 31.123604] __asan_report_load4_noabort+0x14/0x20 [ 31.124301] xfrm_state_find+0x303d/0x3170 [ 31.124890] ? xfrm_state_afinfo_get_rcu+0x160/0x160 [ 31.125632] ? __lock_acquire+0x6ef/0x3dc0 [ 31.126327] ? print_usage_bug+0x480/0x480 [ 31.127033] ? check_noncircular+0x20/0x20 [ 31.127599] ? check_noncircular+0x20/0x20 [ 31.128173] ? __lock_acquire+0x6ef/0x3dc0 [ 31.128846] ? print_usage_bug+0x480/0x480 [ 31.129439] ? print_usage_bug+0x480/0x480 [ 31.130090] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 31.130988] ? rcu_read_lock_sched_held+0x108/0x120 [ 31.131719] ? fib_table_lookup+0xa07/0x1a30 [ 31.132384] xfrm_tmpl_resolve+0x309/0xbf0 [ 31.136406] ? __xfrm_dst_lookup+0x120/0x120 [ 31.140787] ? __lock_is_held+0xb6/0x140 [ 31.144825] ? check_noncircular+0x20/0x20 [ 31.149040] ? check_noncircular+0x20/0x20 [ 31.153259] ? rcu_read_lock_held+0xa9/0xc0 [ 31.157549] ? find_exception+0x3aa/0x520 [ 31.161675] xfrm_resolve_and_create_bundle+0x102/0x2080 [ 31.167100] ? lock_downgrade+0x990/0x990 [ 31.171250] ? __xfrm_decode_session+0x100/0x100 [ 31.176066] ? xfrm_sk_policy_lookup+0x2a6/0x3d0 [ 31.180791] ? lock_downgrade+0x990/0x990 [ 31.184918] ? lock_release+0xa40/0xa40 [ 31.188868] ? refcount_inc_not_zero+0xfe/0x180 [ 31.193519] ? xfrm_selector_match+0x3b/0xe00 [ 31.197996] ? xfrm_sk_policy_lookup+0x2cf/0x3d0 [ 31.202726] ? xfrm_selector_match+0xe00/0xe00 [ 31.207285] xfrm_lookup+0xd39/0x11c0 [ 31.211051] ? xfrm_lookup+0xd39/0x11c0 [ 31.215002] ? xfrm_sk_policy_lookup+0x3d0/0x3d0 [ 31.219735] ? lock_release+0xa40/0xa40 [ 31.223702] ? ip_route_output_key_hash+0x252/0x370 [ 31.228691] ? ip_route_output_key_hash_rcu+0x2bb0/0x2bb0 [ 31.234226] xfrm_lookup_route+0x39/0x1a0 [ 31.238350] ip_route_output_flow+0x7c/0xa0 [ 31.242648] inet_csk_route_req+0x5d8/0x990 [ 31.246947] tcp_v4_send_synack+0x1e4/0x270 [ 31.251240] ? tcp_v4_send_check+0x90/0x90 [ 31.255452] ? prandom_u32_state+0x13/0x180 [ 31.259764] tcp_rtx_synack+0x119/0x2e0 [ 31.263727] ? tcp_event_new_data_sent+0x2e0/0x2e0 [ 31.268641] ? tcp_md5_do_del+0x2a0/0x2a0 [ 31.272855] inet_rtx_syn_ack+0x64/0xd0 [ 31.276806] tcp_check_req+0xae3/0x1620 [ 31.280761] ? tcp_error+0x740/0x740 [ 31.284443] ? tcp_parse_md5sig_option+0xbe/0x160 [ 31.289264] ? tcp_openreq_init_rwin+0xae0/0xae0 [ 31.293996] ? refcount_inc_not_zero+0xfe/0x180 [ 31.298646] ? refcount_add+0x60/0x60 [ 31.302417] ? tcp_v4_reqsk_send_ack+0x3e0/0x3e0 [ 31.307145] ? check_noncircular+0x20/0x20 [ 31.311354] tcp_v4_rcv+0x168e/0x2df0 [ 31.315125] ? lock_acquire+0x1d5/0x580 [ 31.319067] ? lock_acquire+0x1d5/0x580 [ 31.323024] ? tcp_v4_early_demux+0xa30/0xa30 [ 31.327499] ip_local_deliver_finish+0x2e2/0xba0 [ 31.332226] ? inet_del_offload+0x40/0x40 [ 31.336351] ip_local_deliver+0x1ce/0x6d0 [ 31.340470] ? ip_call_ra_chain+0x6d0/0x6d0 [ 31.344770] ? inet_del_offload+0x40/0x40 [ 31.348903] ip_rcv_finish+0x8db/0x19c0 [ 31.352850] ? iptable_nat_ipv4_fn+0x40/0x40 [ 31.357233] ? ip_local_deliver_finish+0xba0/0xba0 [ 31.362136] ? ip_rcv+0xf05/0x17d0 [ 31.365743] ? lock_downgrade+0x990/0x990 [ 31.369861] ? tcp_v4_send_synack+0x270/0x270 [ 31.374330] ? rcu_read_lock_held+0xa9/0xc0 [ 31.378620] ? nf_hook_slow+0x12d/0x290 [ 31.382592] ip_rcv+0xc3f/0x17d0 [ 31.385937] ? ip_local_deliver+0x6d0/0x6d0 [ 31.390243] ? ip_local_deliver_finish+0xba0/0xba0 [ 31.395144] ? ip_local_deliver+0x6d0/0x6d0 [ 31.399438] __netif_receive_skb_core+0x1b05/0x3230 [ 31.404432] ? nf_ingress+0x980/0x980 [ 31.408200] ? print_usage_bug+0x480/0x480 [ 31.412401] ? lock_downgrade+0x990/0x990 [ 31.416524] ? __free_insn_slot+0x5c0/0x5c0 [ 31.420820] ? unwind_get_return_address+0x61/0xa0 [ 31.425724] ? is_bpf_text_address+0xa4/0x120 [ 31.430193] ? check_noncircular+0x20/0x20 [ 31.434396] ? unwind_get_return_address+0x61/0xa0 [ 31.439295] ? __save_stack_trace+0x7e/0xd0 [ 31.443596] ? depot_save_stack+0x12c/0x490 [ 31.447897] ? find_held_lock+0x35/0x1d0 [ 31.452031] ? lock_downgrade+0x990/0x990 [ 31.456146] ? __skb_flow_get_ports+0x151/0x400 [ 31.460805] ? pvclock_read_flags+0x160/0x160 [ 31.465276] ? lock_acquire+0x1d5/0x580 [ 31.469216] ? lock_acquire+0x1d5/0x580 [ 31.473159] ? netif_receive_skb_internal+0xf1/0x1a50 [ 31.478320] ? ktime_get_with_offset+0x2c1/0x420 [ 31.483047] ? lock_release+0xa40/0xa40 [ 31.486991] ? do_gettimeofday+0x190/0x190 [ 31.491217] ? netif_receive_skb_internal+0xf1/0x1a50 [ 31.496382] __netif_receive_skb+0x2c/0x1b0 [ 31.500671] ? __netif_receive_skb+0x2c/0x1b0 [ 31.505313] ? netif_receive_skb_internal+0xf1/0x1a50 [ 31.510564] netif_receive_skb_internal+0x16a/0x1a50 [ 31.515724] ? __alloc_skb+0x548/0x740 [ 31.519592] ? dev_queue_xmit_accel+0x30/0x30 [ 31.524058] ? print_usage_bug+0x480/0x480 [ 31.528270] ? check_noncircular+0x20/0x20 [ 31.532483] ? find_held_lock+0x35/0x1d0 [ 31.536627] ? __might_fault+0x110/0x1d0 [ 31.540658] ? lock_downgrade+0x990/0x990 [ 31.544780] ? lock_release+0xa40/0xa40 [ 31.548724] ? check_same_owner+0x320/0x320 [ 31.553020] ? rcu_pm_notify+0xc0/0xc0 [ 31.556889] netif_receive_skb+0xae/0x390 [ 31.561008] ? netif_receive_skb_internal+0x1a50/0x1a50 [ 31.566361] ? _copy_from_iter+0x367/0xf30 [ 31.570584] ? __check_object_size+0x268/0x500 [ 31.575144] ? tun_rx_batched.isra.42+0x5bd/0x860 [ 31.579968] tun_rx_batched.isra.42+0x5e7/0x860 [ 31.584610] ? skb_get_hash_perturb+0x9d0/0x9d0 [ 31.589255] ? tun_sock_write_space+0x370/0x370 [ 31.593904] ? tun_free_netdev+0x1b0/0x1b0 [ 31.598120] tun_get_user+0xde5/0x2910 [ 31.602011] ? tun_chr_ioctl+0x40/0x40 [ 31.605895] ? find_held_lock+0x35/0x1d0 [ 31.610026] ? __fget+0x333/0x570 [ 31.613471] ? find_held_lock+0x35/0x1d0 [ 31.617515] ? __tun_get+0x1ab/0x2e0 [ 31.621199] ? lock_downgrade+0x990/0x990 [ 31.625319] ? lock_release+0xa40/0xa40 [ 31.629263] ? __lock_is_held+0xb6/0x140 [ 31.633312] ? __tun_get+0x1d4/0x2e0 [ 31.637003] ? tun_chr_close+0x60/0x60 [ 31.640868] tun_chr_write_iter+0xd8/0x190 [ 31.645075] __vfs_write+0x684/0x970 [ 31.648764] ? default_llseek+0x290/0x290 [ 31.652903] ? avc_policy_seqno+0x9/0x20 [ 31.656938] ? selinux_file_permission+0x82/0x460 [ 31.662416] ? rw_verify_area+0xe5/0x2b0 [ 31.666448] ? __fdget_raw+0x20/0x20 [ 31.670133] vfs_write+0x189/0x510 [ 31.673686] SyS_write+0xef/0x220 [ 31.677112] ? SyS_read+0x220/0x220 [ 31.680724] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 31.685712] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 31.690471] entry_SYSCALL_64_fastpath+0x1f/0xbe [ 31.695197] RIP: 0033:0x405b91 [ 31.698371] RSP: 002b:00007fe1b1958d90 EFLAGS: 00000293 ORIG_RAX: 0000000000000001 [ 31.706048] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 0000000000405b91 [ 31.713288] RDX: 0000000000000036 RSI: 0000000020002000 RDI: 0000000000000003 [ 31.720525] RBP: 0000000000000086 R08: 0000000000000013 R09: 00007fe1b1959700 [ 31.727773] R10: 00007fe1b19599d0 R11: 0000000000000293 R12: 0000000000000000 [ 31.735015] R13: 00007fff69ebca2f R14: 00007fe1b19599c0 R15: 0000000000000000 [ 31.742285] [ 31.743882] The buggy address belongs to the page: [ 31.748781] page:ffffea00065bd010 count:0 mapcount:0 mapping: (null) index:0xffff8801d116e500 [ 31.758201] flags: 0x200000000000000() [ 31.762165] raw: 0200000000000000 0000000000000000 ffff8801d116e500 00000000ffffffff [ 31.770280] raw: dead000000000100 dead000000000200 0000000000000000 [ 31.776659] page dumped because: kasan: bad access detected [ 31.782342] [ 31.783938] Memory state around the buggy address: [ 31.788834] ffff8801d116e480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 31.796253] ffff8801d116e500: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 31.803584] >ffff8801d116e580: 00 00 f1 f1 f1 f1 00 00 00 00 00 00 00 f2 f3 f3 [ 31.810909] ^ [ 31.817627] ffff8801d116e600: f3 f3 00 00 00 00 00 00 00 f1 f1 f1 f1 00 00 00 [ 31.824955] ffff8801d116e680: 00 00 00 00 00 00 00 f2 f2 f3 f3 f3 f3 00 00 00 [ 31.832367] ================================================================== [ 31.839873] Disabling lock debugging due to kernel taint [ 31.845422] Kernel panic - not syncing: panic_on_warn set ... [ 31.845422] [ 31.852756] CPU: 0 PID: 2950 Comm: syzkaller768349 Tainted: G B 4.13.0-rc4+ #30 [ 31.861297] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 31.870708] Call Trace: [ 31.873284] dump_stack+0x194/0x257 [ 31.876881] ? arch_local_irq_restore+0x53/0x53 [ 31.881523] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 31.886260] ? xfrm_state_find+0x2f50/0x3170 [ 31.890638] panic+0x1e4/0x417 [ 31.893797] ? __warn+0x1d9/0x1d9 [ 31.897228] ? xfrm_state_find+0x303d/0x3170 [ 31.901605] kasan_end_report+0x50/0x50 [ 31.905546] kasan_report+0x137/0x340 [ 31.909315] __asan_report_load4_noabort+0x14/0x20 [ 31.914216] xfrm_state_find+0x303d/0x3170 [ 31.918436] ? xfrm_state_afinfo_get_rcu+0x160/0x160 [ 31.923520] ? __lock_acquire+0x6ef/0x3dc0 [ 31.927728] ? print_usage_bug+0x480/0x480 [ 31.931931] ? check_noncircular+0x20/0x20 [ 31.936133] ? check_noncircular+0x20/0x20 [ 31.940337] ? __lock_acquire+0x6ef/0x3dc0 [ 31.944545] ? print_usage_bug+0x480/0x480 [ 31.948770] ? print_usage_bug+0x480/0x480 [ 31.952977] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 31.958136] ? rcu_read_lock_sched_held+0x108/0x120 [ 31.963119] ? fib_table_lookup+0xa07/0x1a30 [ 31.967501] xfrm_tmpl_resolve+0x309/0xbf0 [ 31.971710] ? __xfrm_dst_lookup+0x120/0x120 [ 31.976086] ? __lock_is_held+0xb6/0x140 [ 31.980123] ? check_noncircular+0x20/0x20 [ 31.984325] ? check_noncircular+0x20/0x20 [ 31.988526] ? rcu_read_lock_held+0xa9/0xc0 [ 31.993001] ? find_exception+0x3aa/0x520 [ 31.997124] xfrm_resolve_and_create_bundle+0x102/0x2080 [ 32.002540] ? lock_downgrade+0x990/0x990 [ 32.006673] ? __xfrm_decode_session+0x100/0x100 [ 32.011394] ? xfrm_sk_policy_lookup+0x2a6/0x3d0 [ 32.016114] ? lock_downgrade+0x990/0x990 [ 32.020230] ? lock_release+0xa40/0xa40 [ 32.024172] ? refcount_inc_not_zero+0xfe/0x180 [ 32.028811] ? xfrm_selector_match+0x3b/0xe00 [ 32.033275] ? xfrm_sk_policy_lookup+0x2cf/0x3d0 [ 32.038001] ? xfrm_selector_match+0xe00/0xe00 [ 32.042560] xfrm_lookup+0xd39/0x11c0 [ 32.046325] ? xfrm_lookup+0xd39/0x11c0 [ 32.050268] ? xfrm_sk_policy_lookup+0x3d0/0x3d0 [ 32.054995] ? lock_release+0xa40/0xa40 [ 32.058946] ? ip_route_output_key_hash+0x252/0x370 [ 32.063941] ? ip_route_output_key_hash_rcu+0x2bb0/0x2bb0 [ 32.069448] xfrm_lookup_route+0x39/0x1a0 [ 32.073576] ip_route_output_flow+0x7c/0xa0 [ 32.077866] inet_csk_route_req+0x5d8/0x990 [ 32.082163] tcp_v4_send_synack+0x1e4/0x270 [ 32.086453] ? tcp_v4_send_check+0x90/0x90 [ 32.090660] ? prandom_u32_state+0x13/0x180 [ 32.094949] tcp_rtx_synack+0x119/0x2e0 [ 32.098891] ? tcp_event_new_data_sent+0x2e0/0x2e0 [ 32.104752] ? tcp_md5_do_del+0x2a0/0x2a0 [ 32.108871] inet_rtx_syn_ack+0x64/0xd0 [ 32.112813] tcp_check_req+0xae3/0x1620