[....] Starting enhanced syslogd: rsyslogd[?25l[?1c7[ ok 8[?25h[?0c. [ 35.664059] audit: type=1800 audit(1538220588.325:25): pid=5888 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=collect_data cause=failed(directio) comm="startpar" name="cron" dev="sda1" ino=2414 res=0 [ 35.689613] audit: type=1800 audit(1538220588.335:26): pid=5888 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=collect_data cause=failed(directio) comm="startpar" name="mcstrans" dev="sda1" ino=2457 res=0 [ 35.712759] audit: type=1800 audit(1538220588.335:27): pid=5888 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=collect_data cause=failed(directio) comm="startpar" name="restorecond" dev="sda1" ino=2436 res=0 [....] 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 '10.128.0.38' (ECDSA) to the list of known hosts. executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program syzkaller login: [ 63.384990] raw_sendmsg: syz-executor351 forgot to set AF_INET. Fix it! executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 63.553359] ================================================================== [ 63.560829] BUG: KASAN: use-after-free in ip_cmsg_recv_offset+0x12be/0x1390 [ 63.567919] Read of size 4 at addr ffff8801d4d402a0 by task syz-executor351/6085 [ 63.575431] [ 63.577055] CPU: 0 PID: 6085 Comm: syz-executor351 Not tainted 4.19.0-rc5-next-20180928+ #84 [ 63.585630] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 63.594969] Call Trace: [ 63.597558] dump_stack+0x1d3/0x2c4 executing program executing program executing program [ 63.601176] ? dump_stack_print_info.cold.2+0x52/0x52 [ 63.606364] ? printk+0xa7/0xcf [ 63.609656] ? kmsg_dump_rewind_nolock+0xe4/0xe4 [ 63.614441] print_address_description.cold.8+0x9/0x1ff [ 63.619812] kasan_report.cold.9+0x242/0x309 [ 63.624210] ? ip_cmsg_recv_offset+0x12be/0x1390 [ 63.628968] __asan_report_load4_noabort+0x14/0x20 [ 63.633897] ip_cmsg_recv_offset+0x12be/0x1390 [ 63.638475] ? ip_send_unicast_reply+0x1770/0x1770 [ 63.643403] ? copy_page_from_iter+0x8e0/0x8e0 [ 63.647977] ? __skb_recv_datagram+0x262/0x300 executing program executing program executing program [ 63.652800] ? finish_task_switch+0x1f5/0x900 [ 63.657299] ? __bpf_trace_preemptirq_template+0x30/0x30 [ 63.662771] ? __sanitizer_cov_trace_const_cmp4+0x16/0x20 [ 63.668319] ? skb_copy_datagram_iter+0x269/0xc10 [ 63.673240] ? __sk_queue_drop_skb+0x1f0/0x1f0 [ 63.677832] ? lock_downgrade+0x900/0x900 [ 63.681990] ? check_same_owner+0x330/0x330 [ 63.686309] ? rcu_read_unlock_special+0x1c0/0x1c0 [ 63.691249] raw_recvmsg+0x71d/0x8b0 [ 63.694965] ? raw_abort+0xa0/0xa0 [ 63.698506] ? aa_file_perm+0x490/0x1060 executing program [ 63.702584] ? __sched_text_start+0x8/0x8 [ 63.706725] inet_recvmsg+0x17c/0x6c0 [ 63.710513] ? aa_path_link+0x5e0/0x5e0 [ 63.714489] ? inet_sendpage+0x740/0x740 [ 63.718576] ? aa_sock_msg_perm.isra.12+0xba/0x160 [ 63.723522] ? apparmor_socket_recvmsg+0x29/0x30 [ 63.728427] ? __sanitizer_cov_trace_const_cmp4+0x16/0x20 [ 63.733974] ? security_socket_recvmsg+0x9c/0xc0 [ 63.738731] ? inet_sendpage+0x740/0x740 [ 63.742794] sock_recvmsg+0xd0/0x110 [ 63.746504] sock_read_iter+0x39b/0x570 executing program executing program [ 63.750488] ? sock_recvmsg+0x110/0x110 [ 63.754686] do_iter_readv_writev+0x77c/0xa80 [ 63.759173] ? vfs_dedupe_file_range+0x670/0x670 [ 63.763917] ? rw_verify_area+0x118/0x360 [ 63.768057] do_iter_read+0x26e/0x650 [ 63.771861] ? dup_iter+0x270/0x270 [ 63.775774] vfs_readv+0x175/0x1c0 [ 63.779328] ? compat_rw_copy_check_uvector+0x440/0x440 [ 63.784697] ? __ia32_sys_getpeername+0xb0/0xb0 [ 63.789435] ? __sanitizer_cov_trace_const_cmp4+0x16/0x20 [ 63.794966] ? __fdget_pos+0xde/0x200 [ 63.798756] ? __fdget_raw+0x20/0x20 [ 63.802473] ? __sanitizer_cov_trace_const_cmp1+0x1a/0x20 [ 63.808009] ? fput+0x130/0x1a0 [ 63.811277] do_readv+0x11a/0x310 [ 63.814720] ? vfs_readv+0x1c0/0x1c0 [ 63.818431] ? __bpf_trace_preemptirq_template+0x30/0x30 [ 63.823919] __x64_sys_readv+0x75/0xb0 [ 63.827805] do_syscall_64+0x1b9/0x820 [ 63.831689] ? entry_SYSCALL_64_after_hwframe+0x3e/0xbe [ 63.837041] ? syscall_return_slowpath+0x5e0/0x5e0 [ 63.841954] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 63.846782] ? trace_hardirqs_on_caller+0x310/0x310 [ 63.851786] ? prepare_exit_to_usermode+0x3b0/0x3b0 [ 63.856885] ? prepare_exit_to_usermode+0x291/0x3b0 [ 63.861892] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 63.866730] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 63.871901] RIP: 0033:0x446579 [ 63.875083] Code: e8 0c e8 ff ff 48 83 c4 18 c3 0f 1f 80 00 00 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 0f 83 7b 08 fc ff c3 66 2e 0f 1f 84 00 00 00 00 [ 63.893975] RSP: 002b:00007fb4cc6eeda8 EFLAGS: 00000293 ORIG_RAX: 0000000000000013 [ 63.901676] RAX: ffffffffffffffda RBX: 00000000006dbc28 RCX: 0000000000446579 [ 63.908933] RDX: 0000000000000001 RSI: 0000000020000500 RDI: 0000000000000003 [ 63.916236] RBP: 00000000006dbc20 R08: 000000000000006e R09: 0000000000000000 [ 63.923496] R10: 000000000000006e R11: 0000000000000293 R12: 00000000006dbc2c [ 63.930752] R13: 00000000004ae620 R14: 0000000020001300 R15: 0000000000000000 [ 63.938120] [ 63.939732] Allocated by task 6079: [ 63.943395] save_stack+0x43/0xd0 [ 63.946836] kasan_kmalloc+0xc7/0xe0 [ 63.950546] __kmalloc_node_track_caller+0x47/0x70 [ 63.955463] __kmalloc_reserve.isra.39+0x41/0xe0 [ 63.960249] __alloc_skb+0x150/0x770 [ 63.963955] __ip_append_data.isra.48+0x21d6/0x29b0 [ 63.969082] ip_append_data.part.49+0xef/0x170 [ 63.973655] ip_append_data+0x6d/0x90 [ 63.977445] raw_sendmsg+0x1220/0x4370 [ 63.981324] inet_sendmsg+0x19c/0x690 [ 63.985116] sock_sendmsg+0xd5/0x120 [ 63.988818] __sys_sendto+0x3d7/0x670 [ 63.992602] __x64_sys_sendto+0xe1/0x1a0 [ 63.996660] do_syscall_64+0x1b9/0x820 [ 64.000544] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 64.005714] [ 64.007325] Freed by task 6085: [ 64.010595] save_stack+0x43/0xd0 [ 64.014033] __kasan_slab_free+0x102/0x150 [ 64.018299] kasan_slab_free+0xe/0x10 [ 64.022089] kfree+0xcf/0x230 [ 64.025181] skb_free_head+0x99/0xc0 [ 64.028941] pskb_expand_head+0x3bb/0x10f0 [ 64.033208] __pskb_pull_tail+0x156/0x1890 [ 64.037435] ip_cmsg_recv_offset+0x113b/0x1390 [ 64.042000] raw_recvmsg+0x71d/0x8b0 [ 64.045696] inet_recvmsg+0x17c/0x6c0 [ 64.049489] sock_recvmsg+0xd0/0x110 [ 64.053268] sock_read_iter+0x39b/0x570 [ 64.057241] do_iter_readv_writev+0x77c/0xa80 [ 64.061720] do_iter_read+0x26e/0x650 [ 64.065576] vfs_readv+0x175/0x1c0 [ 64.069108] do_readv+0x11a/0x310 [ 64.072550] __x64_sys_readv+0x75/0xb0 [ 64.076425] do_syscall_64+0x1b9/0x820 [ 64.080361] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 64.085543] [ 64.087157] The buggy address belongs to the object at ffff8801d4d40280 [ 64.087157] which belongs to the cache kmalloc-512 of size 512 [ 64.099799] The buggy address is located 32 bytes inside of [ 64.099799] 512-byte region [ffff8801d4d40280, ffff8801d4d40480) [ 64.111615] The buggy address belongs to the page: [ 64.116596] page:ffffea0007535000 count:1 mapcount:0 mapping:ffff8801da800940 index:0x0 [ 64.124800] flags: 0x2fffc0000000200(slab) [ 64.129025] raw: 02fffc0000000200 ffffea0007534fc8 ffffea00075352c8 ffff8801da800940 [ 64.136893] raw: 0000000000000000 ffff8801d4d40000 0000000100000006 0000000000000000 [ 64.144756] page dumped because: kasan: bad access detected [ 64.150451] executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program executing program [ 64.152061] Memory state around the buggy address: [ 64.156975] ffff8801d4d40180: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 64.164319] ffff8801d4d40200: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 64.171663] >ffff8801d4d40280: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 64.179015] ^ [ 64.183408] ffff8801d4d40300: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 64.190751] ffff8801d4d40380: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 64.198134] ================================================================== executing program executing program executing program [ 64.210130] Kernel panic - not syncing: panic_on_warn set ... [ 64.210130] [ 64.217498] CPU: 0 PID: 6085 Comm: syz-executor351 Tainted: G B 4.19.0-rc5-next-20180928+ #84 [ 64.227446] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 64.236820] Call Trace: [ 64.239403] dump_stack+0x1d3/0x2c4 [ 64.243022] ? dump_stack_print_info.cold.2+0x52/0x52 [ 64.248209] panic+0x238/0x4e7 [ 64.251392] ? add_taint.cold.5+0x16/0x16 [ 64.255542] ? preempt_schedule+0x4d/0x60 executing program executing program executing program [ 64.259700] ? ___preempt_schedule+0x16/0x18 [ 64.264102] ? trace_hardirqs_on+0xb4/0x310 [ 64.268421] kasan_end_report+0x47/0x4f [ 64.272388] kasan_report.cold.9+0x76/0x309 [ 64.276706] ? ip_cmsg_recv_offset+0x12be/0x1390 [ 64.281456] __asan_report_load4_noabort+0x14/0x20 [ 64.286375] ip_cmsg_recv_offset+0x12be/0x1390 [ 64.290944] ? ip_send_unicast_reply+0x1770/0x1770 [ 64.295911] ? copy_page_from_iter+0x8e0/0x8e0 [ 64.300488] ? __skb_recv_datagram+0x262/0x300 [ 64.305121] ? finish_task_switch+0x1f5/0x900 executing program executing program executing program [ 64.309676] ? __bpf_trace_preemptirq_template+0x30/0x30 [ 64.315127] ? __sanitizer_cov_trace_const_cmp4+0x16/0x20 [ 64.320648] ? skb_copy_datagram_iter+0x269/0xc10 [ 64.325526] ? __sk_queue_drop_skb+0x1f0/0x1f0 [ 64.330114] ? lock_downgrade+0x900/0x900 [ 64.334255] ? check_same_owner+0x330/0x330 [ 64.338629] ? rcu_read_unlock_special+0x1c0/0x1c0 [ 64.343563] raw_recvmsg+0x71d/0x8b0 [ 64.347272] ? raw_abort+0xa0/0xa0 [ 64.350800] ? aa_file_perm+0x490/0x1060 [ 64.354851] ? __sched_text_start+0x8/0x8 executing program executing program executing program [ 64.358991] inet_recvmsg+0x17c/0x6c0 [ 64.362780] ? aa_path_link+0x5e0/0x5e0 [ 64.366744] ? inet_sendpage+0x740/0x740 [ 64.370793] ? aa_sock_msg_perm.isra.12+0xba/0x160 [ 64.375712] ? apparmor_socket_recvmsg+0x29/0x30 [ 64.380464] ? __sanitizer_cov_trace_const_cmp4+0x16/0x20 [ 64.385993] ? security_socket_recvmsg+0x9c/0xc0 [ 64.390740] ? inet_sendpage+0x740/0x740 [ 64.394797] sock_recvmsg+0xd0/0x110 [ 64.398557] sock_read_iter+0x39b/0x570 [ 64.402538] ? sock_recvmsg+0x110/0x110 [ 64.406512] do_iter_readv_writev+0x77c/0xa80 executing program executing program executing program [ 64.411010] ? vfs_dedupe_file_range+0x670/0x670 [ 64.415803] ? rw_verify_area+0x118/0x360 [ 64.419947] do_iter_read+0x26e/0x650 [ 64.423741] ? dup_iter+0x270/0x270 [ 64.427362] vfs_readv+0x175/0x1c0 [ 64.430900] ? compat_rw_copy_check_uvector+0x440/0x440 [ 64.436263] ? __ia32_sys_getpeername+0xb0/0xb0 [ 64.440931] ? __sanitizer_cov_trace_const_cmp4+0x16/0x20 [ 64.446458] ? __fdget_pos+0xde/0x200 [ 64.450248] ? __fdget_raw+0x20/0x20 [ 64.453954] ? __sanitizer_cov_trace_const_cmp1+0x1a/0x20 [ 64.459479] ? fput+0x130/0x1a0 [ 64.462749] do_readv+0x11a/0x310 [ 64.466190] ? vfs_readv+0x1c0/0x1c0 [ 64.469934] ? __bpf_trace_preemptirq_template+0x30/0x30 [ 64.475524] __x64_sys_readv+0x75/0xb0 [ 64.479415] do_syscall_64+0x1b9/0x820 [ 64.483336] ? entry_SYSCALL_64_after_hwframe+0x3e/0xbe [ 64.488730] ? syscall_return_slowpath+0x5e0/0x5e0 [ 64.493654] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 64.498596] ? trace_hardirqs_on_caller+0x310/0x310 [ 64.503603] ? prepare_exit_to_usermode+0x3b0/0x3b0 [ 64.508616] ? prepare_exit_to_usermode+0x291/0x3b0 [ 64.513625] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 64.518461] entry_SYSCALL_64_after_hwframe+0x49/0xbe [ 64.523759] RIP: 0033:0x446579 [ 64.526938] Code: e8 0c e8 ff ff 48 83 c4 18 c3 0f 1f 80 00 00 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 0f 83 7b 08 fc ff c3 66 2e 0f 1f 84 00 00 00 00 [ 64.545835] RSP: 002b:00007fb4cc6eeda8 EFLAGS: 00000293 ORIG_RAX: 0000000000000013 [ 64.553640] RAX: ffffffffffffffda RBX: 00000000006dbc28 RCX: 0000000000446579 [ 64.560902] RDX: 0000000000000001 RSI: 0000000020000500 RDI: 0000000000000003 [ 64.568171] RBP: 00000000006dbc20 R08: 000000000000006e R09: 0000000000000000 [ 64.575424] R10: 000000000000006e R11: 0000000000000293 R12: 00000000006dbc2c [ 64.582721] R13: 00000000004ae620 R14: 0000000020001300 R15: 0000000000000000 [ 64.590871] Kernel Offset: disabled [ 64.594494] Rebooting in 86400 seconds..