[....] Starting enhanced syslogd: rsyslogd[ 12.104491] audit: type=1400 audit(1515647944.576:5): avc: denied { syslog } for pid=3343 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 syzkaller login: [ 20.375982] audit: type=1400 audit(1515647952.847:6): avc: denied { map } for pid=3482 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 Warning: Permanently added '10.128.0.39' (ECDSA) to the list of known hosts. executing program [ 26.629832] audit: type=1400 audit(1515647959.101:7): avc: denied { map } for pid=3496 comm="syzkaller813454" path="/root/syzkaller813454543" 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 executing program executing program [ 26.811142] [ 26.812819] ========================= [ 26.816589] WARNING: held lock freed! [ 26.820357] 4.15.0-rc7+ #182 Not tainted [ 26.824385] ------------------------- [ 26.828174] syzkaller813454/3500 is freeing memory 00000000a774c8d9-0000000046d64d99, with a lock still held there! [ 26.838712] (sk_lock-AF_INET6){+.+.}, at: [<00000000f20472e2>] sctp_wait_for_sndbuf+0x509/0x8d0 [ 26.849007] 1 lock held by syzkaller813454/3500: [ 26.854423] #0: (sk_lock-AF_INET6){+.+.}, at: [<00000000f20472e2>] sctp_wait_for_sndbuf+0x509/0x8d0 [ 26.863759] [ 26.863759] stack backtrace: [ 26.868225] CPU: 1 PID: 3500 Comm: syzkaller813454 Not tainted 4.15.0-rc7+ #182 [ 26.875638] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 26.884960] Call Trace: [ 26.887518] dump_stack+0x194/0x257 [ 26.891116] ? arch_local_irq_restore+0x53/0x53 [ 26.895763] debug_check_no_locks_freed+0x32f/0x3c0 [ 26.900752] kmem_cache_free+0x68/0x2a0 [ 26.904707] __sk_destruct+0x622/0x910 [ 26.908744] ? save_stack+0x43/0xd0 [ 26.912341] ? sock_rfree+0x160/0x160 [ 26.916110] ? sctp_sendmsg+0x28f7/0x33f0 [ 26.920228] ? sock_sendmsg+0xca/0x110 [ 26.924091] ? SYSC_sendto+0x361/0x5c0 [ 26.927956] ? SyS_sendto+0x40/0x50 [ 26.931552] ? entry_SYSCALL_64_fastpath+0x23/0x9a [ 26.936453] ? check_noncircular+0x20/0x20 [ 26.940665] ? print_irqtrace_events+0x270/0x270 [ 26.945393] ? __local_bh_enable_ip+0x121/0x230 [ 26.950030] ? sctp_put_port+0x495/0x640 [ 26.954061] ? sctp_poll+0xc00/0xc00 [ 26.957748] ? refcount_sub_and_test+0x115/0x1b0 [ 26.962471] ? refcount_inc+0x50/0x50 [ 26.966240] ? refcount_inc+0x50/0x50 [ 26.970023] sk_destruct+0x47/0x80 [ 26.973881] __sk_free+0xf1/0x2b0 [ 26.977304] sk_free+0x2a/0x40 [ 26.980478] sctp_association_put+0x14c/0x2f0 [ 26.984942] ? sctp_association_hold+0x20/0x20 [ 26.989494] ? lock_sock_nested+0x91/0x110 [ 26.993705] ? trace_hardirqs_on+0xd/0x10 [ 26.997834] ? __local_bh_enable_ip+0x121/0x230 [ 27.002477] sctp_wait_for_sndbuf+0x673/0x8d0 [ 27.006948] ? sctp_init_sock+0x13b0/0x13b0 [ 27.011239] ? do_raw_spin_trylock+0x190/0x190 [ 27.017601] ? __local_bh_enable_ip+0x121/0x230 [ 27.022237] ? sctp_prsctp_prune+0x97/0x790 [ 27.026527] ? prepare_to_wait+0x4d0/0x4d0 [ 27.030730] ? trace_hardirqs_on+0xd/0x10 [ 27.034858] sctp_sendmsg+0x28f7/0x33f0 [ 27.038813] ? sctp_id2assoc+0x390/0x390 [ 27.042851] ? avc_has_perm+0x43e/0x680 [ 27.046798] ? avc_has_perm_noaudit+0x520/0x520 [ 27.051437] ? __fget+0x35c/0x570 [ 27.054864] ? iterate_fd+0x3f0/0x3f0 [ 27.058639] ? find_held_lock+0x35/0x1d0 [ 27.062673] ? sock_has_perm+0x2a4/0x420 [ 27.066704] ? lock_release+0x9a2/0xa40 [ 27.070648] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 27.076499] ? __check_object_size+0x25d/0x4f0 [ 27.081054] inet_sendmsg+0x11f/0x5e0 [ 27.084825] ? inet_sendmsg+0x11f/0x5e0 [ 27.088765] ? __might_sleep+0x95/0x190 [ 27.092708] ? inet_create+0xf50/0xf50 [ 27.096566] ? selinux_socket_sendmsg+0x36/0x40 [ 27.101203] ? security_socket_sendmsg+0x89/0xb0 [ 27.105936] ? inet_create+0xf50/0xf50 [ 27.109795] sock_sendmsg+0xca/0x110 [ 27.113478] SYSC_sendto+0x361/0x5c0 [ 27.117162] ? SYSC_connect+0x4a0/0x4a0 [ 27.121106] ? selinux_secmark_relabel_packet+0xc0/0xc0 [ 27.126437] ? __do_page_fault+0x3d6/0xc90 [ 27.130646] ? selinux_netlbl_sock_rcv_skb+0x730/0x730 [ 27.135907] ? SyS_futex+0x269/0x390 [ 27.139589] ? SyS_setsockopt+0x215/0x360 [ 27.143707] ? do_futex+0x22a0/0x22a0 [ 27.147477] ? entry_SYSCALL_64_fastpath+0x5/0x9a [ 27.152292] SyS_sendto+0x40/0x50 [ 27.155717] entry_SYSCALL_64_fastpath+0x23/0x9a [ 27.160439] RIP: 0033:0x4457e9 [ 27.163598] RSP: 002b:00007f2e16a47da8 EFLAGS: 00000216 ORIG_RAX: 000000000000002c [ 27.171277] RAX: ffffffffffffffda RBX: 00000000006dac6c RCX: 00000000004457e9 [ 27.179123] RDX: 0000000000000001 RSI: 000000002010bf14 RDI: 0000000000000004 [ 27.186361] RBP: 00000000006dac68 R08: 00000000204d9000 R09: 000000000000001c [ 27.193597] R10: 0000000000000000 R11: 0000000000000216 R12: 0000000000000000 [ 27.200837] R13: 00007ffc7b48e20f R14: 00007f2e16a489c0 R15: 0000000000000001 [ 27.208168] ================================================================== [ 27.215514] BUG: KASAN: use-after-free in do_raw_spin_lock+0x1e0/0x220 [ 27.222161] Read of size 4 at addr ffff8801bf43e08c by task syzkaller813454/3500 [ 27.229664] [ 27.231272] CPU: 1 PID: 3500 Comm: syzkaller813454 Not tainted 4.15.0-rc7+ #182 [ 27.238697] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 27.248037] Call Trace: [ 27.250597] dump_stack+0x194/0x257 [ 27.254191] ? arch_local_irq_restore+0x53/0x53 [ 27.258836] ? show_regs_print_info+0x18/0x18 executing program [ 27.263297] ? lock_acquire+0x1d5/0x580 [ 27.267238] ? trace_hardirqs_on+0xd/0x10 [ 27.271351] ? do_raw_spin_lock+0x1e0/0x220 [ 27.275639] print_address_description+0x73/0x250 [ 27.280457] ? do_raw_spin_lock+0x1e0/0x220 [ 27.284754] kasan_report+0x25b/0x340 [ 27.288526] __asan_report_load4_noabort+0x14/0x20 [ 27.293432] do_raw_spin_lock+0x1e0/0x220 [ 27.297563] _raw_spin_lock_bh+0x39/0x40 [ 27.301602] ? release_sock+0x74/0x2a0 [ 27.305464] release_sock+0x74/0x2a0 [ 27.309149] ? sctp_prsctp_prune+0x97/0x790 [ 27.313787] ? __release_sock+0x360/0x360 [ 27.318772] ? trace_hardirqs_on+0xd/0x10 [ 27.322895] sctp_sendmsg+0x2993/0x33f0 [ 27.326846] ? sctp_id2assoc+0x390/0x390 [ 27.330876] ? avc_has_perm+0x43e/0x680 [ 27.334823] ? avc_has_perm_noaudit+0x520/0x520 [ 27.339462] ? __fget+0x35c/0x570 [ 27.342888] ? iterate_fd+0x3f0/0x3f0 [ 27.346661] ? find_held_lock+0x35/0x1d0 [ 27.350705] ? sock_has_perm+0x2a4/0x420 [ 27.354737] ? lock_release+0x9a2/0xa40 [ 27.358679] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 27.364531] ? __check_object_size+0x25d/0x4f0 [ 27.369086] inet_sendmsg+0x11f/0x5e0 [ 27.372855] ? inet_sendmsg+0x11f/0x5e0 [ 27.376801] ? __might_sleep+0x95/0x190 [ 27.380758] ? inet_create+0xf50/0xf50 [ 27.384615] ? selinux_socket_sendmsg+0x36/0x40 [ 27.389252] ? security_socket_sendmsg+0x89/0xb0 [ 27.393987] ? inet_create+0xf50/0xf50 [ 27.398109] sock_sendmsg+0xca/0x110 [ 27.402759] SYSC_sendto+0x361/0x5c0 [ 27.406445] ? SYSC_connect+0x4a0/0x4a0 [ 27.410390] ? selinux_secmark_relabel_packet+0xc0/0xc0 [ 27.416071] ? __do_page_fault+0x3d6/0xc90 [ 27.420276] ? selinux_netlbl_sock_rcv_skb+0x730/0x730 [ 27.425536] ? SyS_futex+0x269/0x390 [ 27.429219] ? SyS_setsockopt+0x215/0x360 [ 27.433337] ? do_futex+0x22a0/0x22a0 [ 27.437109] ? entry_SYSCALL_64_fastpath+0x5/0x9a [ 27.441926] SyS_sendto+0x40/0x50 [ 27.445351] entry_SYSCALL_64_fastpath+0x23/0x9a [ 27.450075] RIP: 0033:0x4457e9 [ 27.453235] RSP: 002b:00007f2e16a47da8 EFLAGS: 00000216 ORIG_RAX: 000000000000002c [ 27.460911] RAX: ffffffffffffffda RBX: 00000000006dac6c RCX: 00000000004457e9 [ 27.468149] RDX: 0000000000000001 RSI: 000000002010bf14 RDI: 0000000000000004 [ 27.475388] RBP: 00000000006dac68 R08: 00000000204d9000 R09: 000000000000001c [ 27.482629] R10: 0000000000000000 R11: 0000000000000216 R12: 0000000000000000 [ 27.489868] R13: 00007ffc7b48e20f R14: 00007f2e16a489c0 R15: 0000000000000001 [ 27.497116] [ 27.498715] Allocated by task 3505: [ 27.502313] save_stack+0x43/0xd0 [ 27.505734] kasan_kmalloc+0xad/0xe0 [ 27.509426] kasan_slab_alloc+0x12/0x20 [ 27.513368] kmem_cache_alloc+0x12e/0x760 [ 27.517492] sk_prot_alloc+0x65/0x2a0 [ 27.521260] sk_alloc+0x105/0x1440 [ 27.526610] sctp_v6_create_accept_sk+0x15a/0x9b0 [ 27.532377] sctp_accept+0x5c4/0x970 [ 27.536058] inet_accept+0x12c/0x930 [ 27.539739] SYSC_accept4+0x38d/0x870 [ 27.543507] SyS_accept+0x26/0x30 [ 27.546937] entry_SYSCALL_64_fastpath+0x23/0x9a [ 27.551655] [ 27.553250] Freed by task 3500: [ 27.556497] save_stack+0x43/0xd0 [ 27.559926] kasan_slab_free+0x71/0xc0 [ 27.563782] kmem_cache_free+0x83/0x2a0 [ 27.567721] __sk_destruct+0x622/0x910 [ 27.571573] sk_destruct+0x47/0x80 [ 27.575079] __sk_free+0xf1/0x2b0 [ 27.578509] sk_free+0x2a/0x40 [ 27.582201] sctp_association_put+0x14c/0x2f0 [ 27.587715] sctp_wait_for_sndbuf+0x673/0x8d0 [ 27.592179] sctp_sendmsg+0x28f7/0x33f0 [ 27.596122] inet_sendmsg+0x11f/0x5e0 [ 27.599891] sock_sendmsg+0xca/0x110 [ 27.603571] SYSC_sendto+0x361/0x5c0 [ 27.607253] SyS_sendto+0x40/0x50 [ 27.611023] entry_SYSCALL_64_fastpath+0x23/0x9a [ 27.615742] [ 27.617339] The buggy address belongs to the object at ffff8801bf43e000 [ 27.617339] which belongs to the cache SCTPv6 of size 1888 [ 27.629617] The buggy address is located 140 bytes inside of [ 27.629617] 1888-byte region [ffff8801bf43e000, ffff8801bf43e760) [ 27.641553] The buggy address belongs to the page: [ 27.646452] page:ffffea0006fd0f80 count:1 mapcount:0 mapping:ffff8801bf43e000 index:0x0 [ 27.654572] flags: 0x2fffc0000000100(slab) [ 27.658778] raw: 02fffc0000000100 ffff8801bf43e000 0000000000000000 0000000100000002 [ 27.666625] raw: ffffea00074c98e0 ffffea0006fe9160 ffff8801d3260980 0000000000000000 [ 27.674470] page dumped because: kasan: bad access detected [ 27.680157] [ 27.681752] Memory state around the buggy address: [ 27.686647] ffff8801bf43df80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 27.693973] ffff8801bf43e000: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 27.701301] >ffff8801bf43e080: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 27.708626] ^ [ 27.712219] ffff8801bf43e100: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 27.719543] ffff8801bf43e180: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 27.726875] ================================================================== [ 27.734239] Kernel panic - not syncing: panic_on_warn set ... [ 27.734239] [ 27.741587] CPU: 1 PID: 3500 Comm: syzkaller813454 Tainted: G B 4.15.0-rc7+ #182 [ 27.750325] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 27.759647] Call Trace: [ 27.762211] dump_stack+0x194/0x257 [ 27.765818] ? arch_local_irq_restore+0x53/0x53 [ 27.770469] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 27.775203] ? vsnprintf+0x1ed/0x1900 [ 27.778972] ? do_raw_spin_lock+0x140/0x220 [ 27.783276] panic+0x1e4/0x41c [ 27.786457] ? refcount_error_report+0x214/0x214 [ 27.791180] ? add_taint+0x1c/0x50 [ 27.794686] ? add_taint+0x1c/0x50 [ 27.798195] ? do_raw_spin_lock+0x1e0/0x220 [ 27.802494] kasan_end_report+0x50/0x50 [ 27.806439] kasan_report+0x144/0x340 [ 27.810225] __asan_report_load4_noabort+0x14/0x20 executing program [ 27.815126] do_raw_spin_lock+0x1e0/0x220 [ 27.819249] _raw_spin_lock_bh+0x39/0x40 [ 27.823282] ? release_sock+0x74/0x2a0 [ 27.827138] release_sock+0x74/0x2a0 [ 27.830828] ? sctp_prsctp_prune+0x97/0x790 [ 27.835119] ? __release_sock+0x360/0x360 [ 27.839246] ? trace_hardirqs_on+0xd/0x10 [ 27.843370] sctp_sendmsg+0x2993/0x33f0 [ 27.847321] ? sctp_id2assoc+0x390/0x390 [ 27.851354] ? avc_has_perm+0x43e/0x680 [ 27.855300] ? avc_has_perm_noaudit+0x520/0x520 [ 27.859937] ? __fget+0x35c/0x570 [ 27.863363] ? iterate_fd+0x3f0/0x3f0 [ 27.867135] ? find_held_lock+0x35/0x1d0 [ 27.871181] ? sock_has_perm+0x2a4/0x420 [ 27.875213] ? lock_release+0x9a2/0xa40 [ 27.879156] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 27.885012] ? __check_object_size+0x25d/0x4f0 [ 27.889569] inet_sendmsg+0x11f/0x5e0 [ 27.894033] ? inet_sendmsg+0x11f/0x5e0 [ 27.899198] ? __might_sleep+0x95/0x190 [ 27.904794] ? inet_create+0xf50/0xf50 [ 27.909189] ? selinux_socket_sendmsg+0x36/0x40 [ 27.913828] ? security_socket_sendmsg+0x89/0xb0 [ 27.918551] ? inet_create+0xf50/0xf50 [ 27.922409] sock_sendmsg+0xca/0x110 [ 27.926094] SYSC_sendto+0x361/0x5c0 [ 27.929797] ? SYSC_connect+0x4a0/0x4a0 [ 27.933743] ? selinux_secmark_relabel_packet+0xc0/0xc0 [ 27.939076] ? __do_page_fault+0x3d6/0xc90 [ 27.943293] ? selinux_netlbl_sock_rcv_skb+0x730/0x730 [ 27.948555] ? SyS_futex+0x269/0x390 [ 27.952239] ? SyS_setsockopt+0x215/0x360 [ 27.956356] ? do_futex+0x22a0/0x22a0 [ 27.960128] ? entry_SYSCALL_64_fastpath+0x5/0x9a [ 27.964943] SyS_sendto+0x40/0x50 [ 27.968368] entry_SYSCALL_64_fastpath+0x23/0x9a [ 27.973092] RIP: 0033:0x4457e9 [ 27.976250] RSP: 002b:00007f2e16a47da8 EFLAGS: 00000216 ORIG_RAX: 000000000000002c [ 27.983927] RAX: ffffffffffffffda RBX: 00000000006dac6c RCX: 00000000004457e9 [ 27.991165] RDX: 0000000000000001 RSI: 000000002010bf14 RDI: 0000000000000004 [ 27.998417] RBP: 00000000006dac68 R08: 00000000204d9000 R09: 000000000000001c [ 28.005656] R10: 0000000000000000 R11: 0000000000000216 R12: 0000000000000000 [ 28.012904] R13: 00007ffc7b48e20f R14: 00007f2e16a489c0 R15: 0000000000000001 [ 28.020923] Dumping ftrace buffer: [ 28.024441] (ftrace buffer empty) [ 28.028117] Kernel Offset: disabled [ 28.031711] Rebooting in 86400 seconds..