[....] Starting enhanced syslogd: rsyslogd[ 16.068629] audit: type=1400 audit(1517223330.126:4): avc: denied { syslog } for pid=3920 comm="rsyslogd" capability=34 scontext=system_u:system_r:kernel_t:s0 tcontext=system_u:system_r:kernel_t:s0 tclass=capability2 permissive=1 [?25l[?1c7[ ok 8[?25h[?0c. [....] Starting periodic command scheduler: cron[?25l[?1c7[ ok 8[?25h[?0c. Starting mcstransd: [....] 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 Warning: Permanently added '10.128.0.19' (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 executing program executing program executing program syzkaller login: [ 27.619948] ================================================================== [ 27.627344] BUG: KASAN: use-after-free in pppol2tp_session_destruct+0xe9/0x110 [ 27.634706] Read of size 4 at addr ffff8801d9835900 by task syzkaller490994/4078 [ 27.642209] [ 27.643809] CPU: 1 PID: 4078 Comm: syzkaller490994 Not tainted 4.9.78-g68d447c #32 [ 27.651482] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 27.660808] ffff8801d40e7c18 ffffffff81d943a9 ffffea0007660d00 ffff8801d9835900 [ 27.668774] 0000000000000000 ffff8801d9835900 ffffffff82ed49f0 ffff8801d40e7c50 [ 27.676749] ffffffff8153dc23 ffff8801d9835900 0000000000000004 0000000000000000 [ 27.684713] Call Trace: [ 27.687278] [] dump_stack+0xc1/0x128 [ 27.692615] [] ? sock_release+0x1e0/0x1e0 [ 27.698387] [] print_address_description+0x73/0x280 [ 27.705022] [] ? sock_release+0x1e0/0x1e0 [ 27.710793] [] kasan_report+0x275/0x360 [ 27.716389] [] ? pppol2tp_session_destruct+0xe9/0x110 [ 27.723210] [] __asan_report_load4_noabort+0x14/0x20 [ 27.729941] [] pppol2tp_session_destruct+0xe9/0x110 [ 27.736579] [] ? pppol2tp_seq_start+0x4e0/0x4e0 [ 27.742872] [] __sk_destruct+0x53/0x570 [ 27.748479] [] ? sock_release+0x1e0/0x1e0 [ 27.754257] [] sk_destruct+0x47/0x80 [ 27.759590] [] __sk_free+0x57/0x230 [ 27.764835] [] sk_free+0x23/0x30 [ 27.769824] [] pppol2tp_release+0x23d/0x2e0 [ 27.775766] [] sock_release+0x8d/0x1e0 [ 27.781277] [] sock_close+0x16/0x20 [ 27.786524] [] __fput+0x28c/0x6e0 [ 27.791595] [] ____fput+0x15/0x20 [ 27.796671] [] task_work_run+0x115/0x190 [ 27.802358] [] exit_to_usermode_loop+0xfc/0x120 [ 27.808649] [] do_fast_syscall_32+0x5de/0x890 [ 27.814768] [] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 27.821407] [] entry_SYSENTER_compat+0x74/0x83 [ 27.827605] [ 27.829203] Allocated by task 4077: [ 27.832801] save_stack_trace+0x16/0x20 [ 27.836745] save_stack+0x43/0xd0 [ 27.840167] kasan_kmalloc+0xad/0xe0 [ 27.843856] __kmalloc+0x11d/0x310 [ 27.847368] l2tp_session_create+0x38/0x1770 [ 27.851747] pppol2tp_connect+0x10fe/0x18f0 [ 27.856038] SYSC_connect+0x1b6/0x310 [ 27.859807] SyS_connect+0x24/0x30 [ 27.863318] do_fast_syscall_32+0x2f7/0x890 [ 27.867610] entry_SYSENTER_compat+0x74/0x83 [ 27.871983] [ 27.873578] Freed by task 4077: [ 27.876825] save_stack_trace+0x16/0x20 [ 27.880768] save_stack+0x43/0xd0 [ 27.884192] kasan_slab_free+0x72/0xc0 [ 27.888045] kfree+0x103/0x300 [ 27.891211] l2tp_session_free+0x166/0x200 [ 27.895412] l2tp_tunnel_closeall+0x26c/0x3a0 [ 27.899877] l2tp_udp_encap_destroy+0x87/0xe0 [ 27.904341] udpv6_destroy_sock+0xb1/0xd0 [ 27.908459] sk_common_release+0x6b/0x2f0 [ 27.912576] udp_lib_close+0x15/0x20 [ 27.916261] inet_release+0xfa/0x1d0 [ 27.919954] inet6_release+0x50/0x70 [ 27.923639] sock_release+0x8d/0x1e0 [ 27.927322] sock_close+0x16/0x20 [ 27.930745] __fput+0x28c/0x6e0 [ 27.934008] ____fput+0x15/0x20 [ 27.937260] task_work_run+0x115/0x190 [ 27.941120] exit_to_usermode_loop+0xfc/0x120 [ 27.945583] do_fast_syscall_32+0x5de/0x890 [ 27.949876] entry_SYSENTER_compat+0x74/0x83 [ 27.954264] [ 27.955864] The buggy address belongs to the object at ffff8801d9835900 [ 27.955864] which belongs to the cache kmalloc-512 of size 512 [ 27.968495] The buggy address is located 0 bytes inside of [ 27.968495] 512-byte region [ffff8801d9835900, ffff8801d9835b00) [ 27.980164] The buggy address belongs to the page: [ 27.985075] page:ffffea0007660d00 count:1 mapcount:0 mapping: (null) index:0x0 compound_mapcount: 0 [ 27.995245] flags: 0x8000000000004080(slab|head) [ 27.999969] page dumped because: kasan: bad access detected [ 28.005647] [ 28.007243] Memory state around the buggy address: [ 28.012141] ffff8801d9835800: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 28.019475] ffff8801d9835880: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 28.026809] >ffff8801d9835900: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 28.034136] ^ [ 28.037470] ffff8801d9835980: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 28.044798] ffff8801d9835a00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 28.052125] ================================================================== [ 28.059462] Disabling lock debugging due to kernel taint [ 28.065278] Kernel panic - not syncing: panic_on_warn set ... [ 28.065278] [ 28.072635] CPU: 1 PID: 4078 Comm: syzkaller490994 Tainted: G B 4.9.78-g68d447c #32 [ 28.081533] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 28.090861] ffff8801d40e7b70 ffffffff81d943a9 ffffffff841971bf ffff8801d40e7c48 [ 28.098843] 0000000000000000 ffff8801d9835900 ffffffff82ed49f0 ffff8801d40e7c38 [ 28.106824] ffffffff8142f451 0000000041b58ab3 ffffffff8418ac30 ffffffff8142f295 [ 28.114804] Call Trace: [ 28.117372] [] dump_stack+0xc1/0x128 [ 28.122709] [] ? sock_release+0x1e0/0x1e0 [ 28.128478] [] panic+0x1bc/0x3a8 [ 28.133467] [] ? percpu_up_read_preempt_enable.constprop.53+0xd7/0xd7 [ 28.141670] [] ? preempt_schedule+0x25/0x30 [ 28.147615] [] ? ___preempt_schedule+0x16/0x18 [ 28.153821] [] kasan_end_report+0x50/0x50 [ 28.159589] [] kasan_report+0x167/0x360 [ 28.165187] [] ? pppol2tp_session_destruct+0xe9/0x110 [ 28.171997] [] __asan_report_load4_noabort+0x14/0x20 [ 28.178722] [] pppol2tp_session_destruct+0xe9/0x110 [ 28.185358] [] ? pppol2tp_seq_start+0x4e0/0x4e0 [ 28.191651] [] __sk_destruct+0x53/0x570 [ 28.197251] [] ? sock_release+0x1e0/0x1e0 [ 28.203018] [] sk_destruct+0x47/0x80 [ 28.208352] [] __sk_free+0x57/0x230 [ 28.213601] [] sk_free+0x23/0x30 [ 28.218588] [] pppol2tp_release+0x23d/0x2e0 [ 28.224530] [] sock_release+0x8d/0x1e0 [ 28.230039] [] sock_close+0x16/0x20 [ 28.235287] [] __fput+0x28c/0x6e0 [ 28.240359] [] ____fput+0x15/0x20 [ 28.245438] [] task_work_run+0x115/0x190 [ 28.251124] [] exit_to_usermode_loop+0xfc/0x120 [ 28.257416] [] do_fast_syscall_32+0x5de/0x890 [ 28.263532] [] ? trace_hardirqs_off_thunk+0x1a/0x1c [ 28.270172] [] entry_SYSENTER_compat+0x74/0x83 [ 28.276823] Dumping ftrace buffer: [ 28.280336] (ftrace buffer empty) [ 28.284017] Kernel Offset: disabled [ 28.287615] Rebooting in 86400 seconds..