[....] Starting file context maintaining daemon: restorecond[?25l[?1c7[ ok 8[?25h[?0c. [....] Starting OpenBSD Secure Shell server: sshd[?25l[?1c7[ ok 8[?25h[?0c. Debian GNU/Linux 7 syzkaller ttyS0 syzkaller login: [ 38.011002] random: sshd: uninitialized urandom read (32 bytes read) [ 38.259499] audit: type=1400 audit(1543956883.594:6): avc: denied { map } for pid=1781 comm="bash" path="/bin/bash" dev="sda1" ino=1457 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=system_u:object_r:file_t:s0 tclass=file permissive=1 [ 38.294466] random: sshd: uninitialized urandom read (32 bytes read) [ 38.764510] random: sshd: uninitialized urandom read (32 bytes read) [ 49.551750] random: sshd: uninitialized urandom read (32 bytes read) Warning: Permanently added '10.128.0.121' (ECDSA) to the list of known hosts. [ 55.243786] random: sshd: uninitialized urandom read (32 bytes read) [ 55.339981] audit: type=1400 audit(1543956900.674:7): avc: denied { map } for pid=1805 comm="syz-executor451" path="/root/syz-executor451079238" dev="sda1" ino=16481 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:user_home_t:s0 tclass=file permissive=1 net.ipv6.conf.syz_tun.accept_dad = 0 net.ipv6.conf.syz_tun.router_solicitations = 0 executing program [ 55.662320] ================================================================== [ 55.669828] BUG: KASAN: stack-out-of-bounds in xfrm_state_find+0x27f9/0x2880 [ 55.676990] Read of size 4 at addr ffff8881c4587680 by task syz-executor451/1806 [ 55.684497] [ 55.686103] CPU: 0 PID: 1806 Comm: syz-executor451 Not tainted 4.14.85+ #15 [ 55.693176] Call Trace: [ 55.695748] dump_stack+0xb9/0x11b [ 55.699310] print_address_description+0x60/0x22b [ 55.704144] kasan_report.cold.6+0x11b/0x2dd [ 55.708536] ? xfrm_state_find+0x27f9/0x2880 [ 55.713030] xfrm_state_find+0x27f9/0x2880 [ 55.717255] ? xfrm_state_afinfo_get_rcu+0xb0/0xb0 [ 55.722163] ? __lock_acquire+0x619/0x4320 [ 55.726381] ? trace_hardirqs_on+0x10/0x10 [ 55.730598] ? deref_stack_reg+0xa8/0xe0 [ 55.734642] ? __read_once_size_nocheck.constprop.4+0x10/0x10 [ 55.740587] ? depot_save_stack+0x20a/0x428 [ 55.744896] ? trace_hardirqs_on+0x10/0x10 [ 55.749113] ? unwind_next_frame+0xea9/0x1930 [ 55.753595] xfrm_tmpl_resolve_one+0x1c6/0x7f0 [ 55.758159] ? xfrm_expand_policies.constprop.13+0x280/0x280 [ 55.763934] ? __lock_acquire+0x619/0x4320 [ 55.768149] ? lock_acquire+0x10f/0x380 [ 55.772103] ? depot_save_stack+0x17f/0x428 [ 55.776404] xfrm_resolve_and_create_bundle+0x21a/0x2550 [ 55.781833] ? trace_hardirqs_on+0x10/0x10 [ 55.786047] ? dst_alloc+0xb1/0x1a0 [ 55.789652] ? xfrm_tmpl_resolve_one+0x7f0/0x7f0 [ 55.794383] ? trace_hardirqs_on+0x10/0x10 [ 55.798593] ? do_syscall_64+0x19b/0x4b0 [ 55.802630] ? entry_SYSCALL_64_after_hwframe+0x42/0xb7 [ 55.808003] ? xfrm_sk_policy_lookup+0x2ae/0x3b0 [ 55.812734] ? lock_downgrade+0x560/0x560 [ 55.816853] ? lock_acquire+0x10f/0x380 [ 55.820802] ? check_preemption_disabled+0x34/0x1e0 [ 55.825808] ? check_preemption_disabled+0x34/0x1e0 [ 55.830830] ? xfrm_sk_policy_lookup+0x2d5/0x3b0 [ 55.835629] ? xfrm_lookup_with_ifid+0x246/0x1870 [ 55.840554] xfrm_lookup_with_ifid+0x246/0x1870 [ 55.845206] ? xfrm_policy_lookup_bytype.constprop.15+0x1250/0x1250 [ 55.851608] ? trace_hardirqs_on_caller+0x381/0x520 [ 55.856601] ? rt_set_nexthop.constprop.14+0x242/0xc30 [ 55.861873] ? ip_route_output_key_hash+0x1c3/0x2d0 [ 55.866864] ? lock_downgrade+0x560/0x560 [ 55.870988] ? lock_acquire+0x10f/0x380 [ 55.874941] ? check_preemption_disabled+0x34/0x1e0 [ 55.879939] ? ip_route_output_key_hash+0x1ea/0x2d0 [ 55.884933] ? ip_route_output_key_hash_rcu+0x21a0/0x21a0 [ 55.890450] xfrm_lookup_route+0x37/0x1b0 [ 55.894574] ip_route_output_flow+0x86/0xa0 [ 55.898872] udp_sendmsg+0x1377/0x1da0 [ 55.902738] ? ip_reply_glue_bits+0xa0/0xa0 [ 55.907158] ? udp_v4_get_port+0xf0/0xf0 [ 55.911198] ? __ip6_local_out+0x349/0x580 [ 55.915685] ? __lock_acquire+0x619/0x4320 [ 55.919896] ? __lock_acquire+0x619/0x4320 [ 55.924108] ? lock_downgrade+0x560/0x560 [ 55.928234] ? lock_acquire+0x10f/0x380 [ 55.932193] udpv6_sendmsg+0x125f/0x2510 [ 55.936242] ? avc_has_perm+0x9e/0x390 [ 55.940108] ? check_preemption_disabled+0x34/0x1e0 [ 55.945103] ? udp_v6_flush_pending_frames+0xd0/0xd0 [ 55.950191] ? avc_has_perm_noaudit+0x300/0x300 [ 55.954846] ? __might_fault+0x104/0x1b0 [ 55.958888] ? rw_copy_check_uvector+0x215/0x2e0 [ 55.963622] ? lock_downgrade+0x560/0x560 [ 55.967745] ? lock_acquire+0x10f/0x380 [ 55.971742] ? sock_has_perm+0x1cb/0x260 [ 55.975787] ? selinux_tun_dev_create+0xb0/0xb0 [ 55.980436] ? __might_fault+0x177/0x1b0 [ 55.984476] ? _copy_from_user+0x94/0x100 [ 55.988611] ? inet_sendmsg+0x168/0x540 [ 55.992560] inet_sendmsg+0x168/0x540 [ 55.996339] ? inet_recvmsg+0x560/0x560 [ 56.000336] sock_sendmsg+0xb5/0x100 [ 56.004033] ___sys_sendmsg+0x41d/0x890 [ 56.007993] ? copy_msghdr_from_user+0x3b0/0x3b0 [ 56.012730] ? trace_hardirqs_on+0x10/0x10 [ 56.016950] ? trace_hardirqs_on+0x10/0x10 [ 56.021165] ? trace_hardirqs_on+0x10/0x10 [ 56.025373] ? trace_hardirqs_on+0x10/0x10 [ 56.029584] ? udp_lib_get_port+0x6b1/0x15a0 [ 56.033974] ? lock_downgrade+0x560/0x560 [ 56.038106] __sys_sendmmsg+0x13d/0x360 [ 56.042062] ? SyS_sendmsg+0x40/0x40 [ 56.045753] ? trace_hardirqs_on_caller+0x381/0x520 [ 56.050785] ? ip6_datagram_connect+0x34/0x40 [ 56.055262] ? __local_bh_enable_ip+0x65/0xb0 [ 56.059734] ? ip6_datagram_connect+0x34/0x40 [ 56.064205] ? inet_dgram_connect+0x118/0x1f0 [ 56.068685] ? ipv6_setsockopt+0x60/0x130 [ 56.072808] ? udpv6_setsockopt+0x4c/0x90 [ 56.076935] ? SyS_recv+0x40/0x40 [ 56.080366] ? up_read+0x17/0x30 [ 56.083706] ? __do_page_fault+0x64c/0xb60 [ 56.087921] SyS_sendmmsg+0x2f/0x50 [ 56.091524] ? __sys_sendmmsg+0x360/0x360 [ 56.095649] do_syscall_64+0x19b/0x4b0 [ 56.099516] entry_SYSCALL_64_after_hwframe+0x42/0xb7 [ 56.104688] RIP: 0033:0x441529 [ 56.107853] RSP: 002b:00007ffe48a047c8 EFLAGS: 00000217 ORIG_RAX: 0000000000000133 [ 56.115635] RAX: ffffffffffffffda RBX: 0000000000000003 RCX: 0000000000441529 [ 56.122896] RDX: 0000000000000002 RSI: 0000000020000000 RDI: 0000000000000003 [ 56.130148] RBP: 00000000006cc018 R08: 0000000000000100 R09: 0000000000000100 [ 56.137396] R10: 0000000000000000 R11: 0000000000000217 R12: 00000000004022e0 [ 56.144640] R13: 0000000000402370 R14: 0000000000000000 R15: 0000000000000000 [ 56.151891] [ 56.153493] The buggy address belongs to the page: [ 56.158394] page:ffffea00071161c0 count:0 mapcount:0 mapping: (null) index:0x0 [ 56.166509] flags: 0x4000000000000000() [ 56.170462] raw: 4000000000000000 0000000000000000 0000000000000000 00000000ffffffff [ 56.178314] raw: 0000000000000000 ffffea00071161e0 0000000000000000 0000000000000000 [ 56.186167] page dumped because: kasan: bad access detected [ 56.191852] [ 56.193455] Memory state around the buggy address: [ 56.198358] ffff8881c4587580: 00 00 00 00 00 f1 f1 f1 f1 00 f2 f2 f2 f2 f2 f2 [ 56.205695] ffff8881c4587600: f2 00 00 00 00 f2 f2 f2 f2 00 00 00 00 00 00 00 [ 56.213026] >ffff8881c4587680: f2 f2 f2 f2 f2 00 00 00 00 00 00 00 00 00 f2 f2 [ 56.220355] ^ [ 56.223694] ffff8881c4587700: f2 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 56.231027] ffff8881c4587780: 00 00 00 00 00 00 00 00 00 00 f1 f1 f1 f1 00 f2 [ 56.238358] ================================================================== [ 56.245766] Disabling lock debugging due to kernel taint [ 56.251259] Kernel panic - not syncing: panic_on_warn set ... [ 56.251259] [ 56.258600] CPU: 0 PID: 1806 Comm: syz-executor451 Tainted: G B 4.14.85+ #15 [ 56.266899] Call Trace: [ 56.269465] dump_stack+0xb9/0x11b [ 56.273003] panic+0x1bf/0x3a4 [ 56.276170] ? add_taint.cold.4+0x16/0x16 [ 56.280309] kasan_end_report+0x43/0x49 [ 56.284273] kasan_report.cold.6+0x77/0x2dd [ 56.288601] ? xfrm_state_find+0x27f9/0x2880 [ 56.292985] xfrm_state_find+0x27f9/0x2880 [ 56.297203] ? xfrm_state_afinfo_get_rcu+0xb0/0xb0 [ 56.302105] ? __lock_acquire+0x619/0x4320 [ 56.306309] ? trace_hardirqs_on+0x10/0x10 [ 56.310519] ? deref_stack_reg+0xa8/0xe0 [ 56.314550] ? __read_once_size_nocheck.constprop.4+0x10/0x10 [ 56.320421] ? depot_save_stack+0x20a/0x428 [ 56.324717] ? trace_hardirqs_on+0x10/0x10 [ 56.328925] ? unwind_next_frame+0xea9/0x1930 [ 56.333442] xfrm_tmpl_resolve_one+0x1c6/0x7f0 [ 56.338011] ? xfrm_expand_policies.constprop.13+0x280/0x280 [ 56.343782] ? __lock_acquire+0x619/0x4320 [ 56.348003] ? lock_acquire+0x10f/0x380 [ 56.351962] ? depot_save_stack+0x17f/0x428 [ 56.356259] xfrm_resolve_and_create_bundle+0x21a/0x2550 [ 56.361682] ? trace_hardirqs_on+0x10/0x10 [ 56.365896] ? dst_alloc+0xb1/0x1a0 [ 56.369498] ? xfrm_tmpl_resolve_one+0x7f0/0x7f0 [ 56.374233] ? trace_hardirqs_on+0x10/0x10 [ 56.378442] ? do_syscall_64+0x19b/0x4b0 [ 56.382483] ? entry_SYSCALL_64_after_hwframe+0x42/0xb7 [ 56.387823] ? xfrm_sk_policy_lookup+0x2ae/0x3b0 [ 56.392552] ? lock_downgrade+0x560/0x560 [ 56.396755] ? lock_acquire+0x10f/0x380 [ 56.400726] ? check_preemption_disabled+0x34/0x1e0 [ 56.405722] ? check_preemption_disabled+0x34/0x1e0 [ 56.410717] ? xfrm_sk_policy_lookup+0x2d5/0x3b0 [ 56.415448] ? xfrm_lookup_with_ifid+0x246/0x1870 [ 56.420265] xfrm_lookup_with_ifid+0x246/0x1870 [ 56.424920] ? xfrm_policy_lookup_bytype.constprop.15+0x1250/0x1250 [ 56.431303] ? trace_hardirqs_on_caller+0x381/0x520 [ 56.436295] ? rt_set_nexthop.constprop.14+0x242/0xc30 [ 56.441547] ? ip_route_output_key_hash+0x1c3/0x2d0 [ 56.446542] ? lock_downgrade+0x560/0x560 [ 56.450840] ? lock_acquire+0x10f/0x380 [ 56.454790] ? check_preemption_disabled+0x34/0x1e0 [ 56.459781] ? ip_route_output_key_hash+0x1ea/0x2d0 [ 56.464773] ? ip_route_output_key_hash_rcu+0x21a0/0x21a0 [ 56.470291] xfrm_lookup_route+0x37/0x1b0 [ 56.474417] ip_route_output_flow+0x86/0xa0 [ 56.478718] udp_sendmsg+0x1377/0x1da0 [ 56.482584] ? ip_reply_glue_bits+0xa0/0xa0 [ 56.486883] ? udp_v4_get_port+0xf0/0xf0 [ 56.490921] ? __ip6_local_out+0x349/0x580 [ 56.495132] ? __lock_acquire+0x619/0x4320 [ 56.499337] ? __lock_acquire+0x619/0x4320 [ 56.503545] ? lock_downgrade+0x560/0x560 [ 56.507668] ? lock_acquire+0x10f/0x380 [ 56.511675] udpv6_sendmsg+0x125f/0x2510 [ 56.515725] ? avc_has_perm+0x9e/0x390 [ 56.519588] ? check_preemption_disabled+0x34/0x1e0 [ 56.524580] ? udp_v6_flush_pending_frames+0xd0/0xd0 [ 56.529660] ? avc_has_perm_noaudit+0x300/0x300 [ 56.534310] ? __might_fault+0x104/0x1b0 [ 56.538345] ? rw_copy_check_uvector+0x215/0x2e0 [ 56.543076] ? lock_downgrade+0x560/0x560 [ 56.547197] ? lock_acquire+0x10f/0x380 [ 56.551149] ? sock_has_perm+0x1cb/0x260 [ 56.555256] ? selinux_tun_dev_create+0xb0/0xb0 [ 56.559908] ? __might_fault+0x177/0x1b0 [ 56.563945] ? _copy_from_user+0x94/0x100 [ 56.568071] ? inet_sendmsg+0x168/0x540 [ 56.572128] inet_sendmsg+0x168/0x540 [ 56.575910] ? inet_recvmsg+0x560/0x560 [ 56.579860] sock_sendmsg+0xb5/0x100 [ 56.583551] ___sys_sendmsg+0x41d/0x890 [ 56.587507] ? copy_msghdr_from_user+0x3b0/0x3b0 [ 56.592247] ? trace_hardirqs_on+0x10/0x10 [ 56.596455] ? trace_hardirqs_on+0x10/0x10 [ 56.600668] ? trace_hardirqs_on+0x10/0x10 [ 56.604877] ? trace_hardirqs_on+0x10/0x10 [ 56.609090] ? udp_lib_get_port+0x6b1/0x15a0 [ 56.613477] ? lock_downgrade+0x560/0x560 [ 56.617614] __sys_sendmmsg+0x13d/0x360 [ 56.621613] ? SyS_sendmsg+0x40/0x40 [ 56.625312] ? trace_hardirqs_on_caller+0x381/0x520 [ 56.630309] ? ip6_datagram_connect+0x34/0x40 [ 56.634793] ? __local_bh_enable_ip+0x65/0xb0 [ 56.639368] ? ip6_datagram_connect+0x34/0x40 [ 56.643841] ? inet_dgram_connect+0x118/0x1f0 [ 56.648317] ? ipv6_setsockopt+0x60/0x130 [ 56.652439] ? udpv6_setsockopt+0x4c/0x90 [ 56.656566] ? SyS_recv+0x40/0x40 [ 56.660001] ? up_read+0x17/0x30 [ 56.663388] ? __do_page_fault+0x64c/0xb60 [ 56.667610] SyS_sendmmsg+0x2f/0x50 [ 56.671216] ? __sys_sendmmsg+0x360/0x360 [ 56.675343] do_syscall_64+0x19b/0x4b0 [ 56.679207] entry_SYSCALL_64_after_hwframe+0x42/0xb7 [ 56.684377] RIP: 0033:0x441529 [ 56.687539] RSP: 002b:00007ffe48a047c8 EFLAGS: 00000217 ORIG_RAX: 0000000000000133 [ 56.695219] RAX: ffffffffffffffda RBX: 0000000000000003 RCX: 0000000000441529 [ 56.702471] RDX: 0000000000000002 RSI: 0000000020000000 RDI: 0000000000000003 [ 56.709719] RBP: 00000000006cc018 R08: 0000000000000100 R09: 0000000000000100 [ 56.716965] R10: 0000000000000000 R11: 0000000000000217 R12: 00000000004022e0 [ 56.724215] R13: 0000000000402370 R14: 0000000000000000 R15: 0000000000000000 [ 56.731790] Kernel Offset: 0x11400000 from 0xffffffff81000000 (relocation range: 0xffffffff80000000-0xffffffffbfffffff) [ 56.742797] Rebooting in 86400 seconds..