[....] Starting enhanced syslogd: rsyslogd[ 12.423958] audit: type=1400 audit(1515647052.388:5): avc: denied { syslog } for pid=3358 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 mcstransd: [....] Starting periodic command scheduler: cron[?25l[?1c7[ ok 8[?25h[?0c. [....] 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: [ 19.257319] audit: type=1400 audit(1515647059.222:6): avc: denied { map } for pid=3498 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.21' (ECDSA) to the list of known hosts. executing program [ 25.462799] audit: type=1400 audit(1515647065.427:7): avc: denied { map } for pid=3512 comm="syzkaller247638" path="/root/syzkaller247638927" 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 [ 25.644058] [ 25.645719] ========================= [ 25.649484] WARNING: held lock freed! [ 25.653250] 4.15.0-rc7-next-20180110+ #93 Not tainted [ 25.658403] ------------------------- [ 25.662172] syzkaller247638/3516 is freeing memory 00000000b418d837-00000000da66d47b, with a lock still held there! [ 25.672714] (sk_lock-AF_INET6){+.+.}, at: [<000000003eb896b0>] sctp_wait_for_sndbuf+0x509/0x8d0 [ 25.681615] 1 lock held by syzkaller247638/3516: [ 25.686333] #0: (sk_lock-AF_INET6){+.+.}, at: [<000000003eb896b0>] sctp_wait_for_sndbuf+0x509/0x8d0 [ 25.695661] [ 25.695661] stack backtrace: [ 25.700123] CPU: 1 PID: 3516 Comm: syzkaller247638 Not tainted 4.15.0-rc7-next-20180110+ #93 [ 25.708662] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 25.717981] Call Trace: [ 25.720537] dump_stack+0x194/0x257 [ 25.724131] ? arch_local_irq_restore+0x53/0x53 [ 25.728770] debug_check_no_locks_freed+0x32f/0x3c0 [ 25.733756] kmem_cache_free+0x68/0x2b0 [ 25.737698] __sk_destruct+0x622/0x910 [ 25.741557] ? kfree+0xd9/0x260 [ 25.744810] ? sock_rfree+0x160/0x160 [ 25.748576] ? sock_sendmsg+0xca/0x110 [ 25.752430] ? SyS_sendto+0x40/0x50 [ 25.756023] ? entry_SYSCALL_64_fastpath+0x29/0xa0 [ 25.760929] ? debug_check_no_obj_freed+0x611/0xf1f [ 25.765917] ? check_noncircular+0x20/0x20 [ 25.770119] ? print_irqtrace_events+0x270/0x270 [ 25.774843] ? __local_bh_enable_ip+0x121/0x230 [ 25.779486] ? sctp_put_port+0x495/0x640 [ 25.783515] ? sctp_poll+0xc00/0xc00 [ 25.787197] ? refcount_sub_and_test+0x115/0x1b0 [ 25.791932] ? refcount_inc+0x50/0x50 [ 25.795699] ? refcount_inc+0x50/0x50 [ 25.799470] sk_destruct+0x47/0x80 [ 25.802977] __sk_free+0xf1/0x2b0 [ 25.806396] sk_free+0x2a/0x40 [ 25.809560] sctp_association_put+0x14c/0x2f0 [ 25.814021] ? sctp_association_hold+0x20/0x20 [ 25.818570] ? lock_sock_nested+0x91/0x110 [ 25.822772] ? trace_hardirqs_on+0xd/0x10 [ 25.826896] ? __local_bh_enable_ip+0x121/0x230 [ 25.831542] sctp_wait_for_sndbuf+0x673/0x8d0 [ 25.836017] ? sctp_init_sock+0x13b0/0x13b0 [ 25.840307] ? do_raw_spin_trylock+0x190/0x190 [ 25.844858] ? __local_bh_enable_ip+0x121/0x230 [ 25.849501] ? sctp_prsctp_prune+0x97/0x790 [ 25.853794] ? prepare_to_wait+0x4d0/0x4d0 [ 25.857998] ? trace_hardirqs_on+0xd/0x10 [ 25.862125] sctp_sendmsg+0x28f7/0x33f0 [ 25.866073] ? sctp_id2assoc+0x390/0x390 [ 25.870110] ? avc_has_perm+0x43e/0x680 [ 25.874051] ? avc_has_perm_noaudit+0x520/0x520 [ 25.878688] ? __fget+0x35c/0x570 [ 25.882111] ? iterate_fd+0x3f0/0x3f0 [ 25.885892] ? find_held_lock+0x35/0x1d0 [ 25.889926] ? sock_has_perm+0x2a4/0x420 [ 25.893963] ? lock_release+0x982/0xa40 [ 25.897904] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 25.903758] ? __check_object_size+0x8b/0x530 [ 25.908220] inet_sendmsg+0x11f/0x5e0 [ 25.911990] ? inet_sendmsg+0x11f/0x5e0 [ 25.915931] ? __might_sleep+0x95/0x190 [ 25.919870] ? inet_create+0xf50/0xf50 [ 25.923726] ? selinux_socket_sendmsg+0x36/0x40 [ 25.928363] ? security_socket_sendmsg+0x89/0xb0 [ 25.933093] ? inet_create+0xf50/0xf50 [ 25.936950] sock_sendmsg+0xca/0x110 [ 25.940632] SYSC_sendto+0x361/0x5c0 [ 25.944316] ? SYSC_connect+0x4a0/0x4a0 [ 25.948259] ? selinux_secmark_relabel_packet+0xc0/0xc0 [ 25.953592] ? __do_page_fault+0x3d6/0xc90 [ 25.958276] ? selinux_netlbl_sock_rcv_skb+0x730/0x730 [ 25.963540] ? SyS_futex+0x269/0x390 [ 25.967225] ? SyS_setsockopt+0x215/0x360 [ 25.971342] ? do_futex+0x22a0/0x22a0 [ 25.975230] ? entry_SYSCALL_64_fastpath+0x5/0xa0 [ 25.980056] SyS_sendto+0x40/0x50 [ 25.983482] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 25.988202] RIP: 0033:0x4457e9 [ 25.991366] RSP: 002b:00007f33a5d0cda8 EFLAGS: 00000216 ORIG_RAX: 000000000000002c [ 25.999040] RAX: ffffffffffffffda RBX: 00000000006dac6c RCX: 00000000004457e9 [ 26.006277] RDX: 0000000000000001 RSI: 000000002010bf14 RDI: 0000000000000004 [ 26.013512] RBP: 00000000006dac68 R08: 00000000204d9000 R09: 000000000000001c [ 26.020764] R10: 0000000000000000 R11: 0000000000000216 R12: 0000000000000000 [ 26.027999] R13: 00007ffc9d3d276f R14: 00007f33a5d0d9c0 R15: 0000000000000001 [ 26.035352] ================================================================== executing program [ 26.042692] BUG: KASAN: use-after-free in do_raw_spin_lock+0x1e0/0x220 [ 26.049325] Read of size 4 at addr ffff8801bf3f608c by task syzkaller247638/3516 [ 26.056822] [ 26.058421] CPU: 1 PID: 3516 Comm: syzkaller247638 Not tainted 4.15.0-rc7-next-20180110+ #93 [ 26.067053] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 26.076392] Call Trace: [ 26.078950] dump_stack+0x194/0x257 [ 26.082547] ? arch_local_irq_restore+0x53/0x53 [ 26.087181] ? show_regs_print_info+0x18/0x18 [ 26.091641] ? lock_acquire+0x1d5/0x580 [ 26.095583] ? trace_hardirqs_on+0xd/0x10 [ 26.099698] ? do_raw_spin_lock+0x1e0/0x220 [ 26.103991] print_address_description+0x73/0x250 [ 26.108802] ? do_raw_spin_lock+0x1e0/0x220 [ 26.113088] kasan_report+0x23b/0x360 [ 26.116858] __asan_report_load4_noabort+0x14/0x20 [ 26.121755] do_raw_spin_lock+0x1e0/0x220 [ 26.125872] _raw_spin_lock_bh+0x39/0x40 [ 26.129910] ? release_sock+0x74/0x2a0 [ 26.133764] release_sock+0x74/0x2a0 [ 26.137444] ? sctp_prsctp_prune+0x97/0x790 [ 26.141731] ? __release_sock+0x360/0x360 [ 26.145854] ? trace_hardirqs_on+0xd/0x10 [ 26.149972] sctp_sendmsg+0x2993/0x33f0 [ 26.153933] ? sctp_id2assoc+0x390/0x390 [ 26.157975] ? avc_has_perm+0x43e/0x680 [ 26.161919] ? avc_has_perm_noaudit+0x520/0x520 [ 26.166558] ? __fget+0x35c/0x570 [ 26.169982] ? iterate_fd+0x3f0/0x3f0 [ 26.173754] ? find_held_lock+0x35/0x1d0 [ 26.177787] ? sock_has_perm+0x2a4/0x420 [ 26.181817] ? lock_release+0x982/0xa40 [ 26.185760] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 26.191612] ? __check_object_size+0x8b/0x530 [ 26.196076] inet_sendmsg+0x11f/0x5e0 [ 26.199853] ? inet_sendmsg+0x11f/0x5e0 [ 26.203794] ? __might_sleep+0x95/0x190 [ 26.207743] ? inet_create+0xf50/0xf50 [ 26.211599] ? selinux_socket_sendmsg+0x36/0x40 [ 26.216235] ? security_socket_sendmsg+0x89/0xb0 [ 26.220956] ? inet_create+0xf50/0xf50 [ 26.224811] sock_sendmsg+0xca/0x110 [ 26.228491] SYSC_sendto+0x361/0x5c0 [ 26.232181] ? SYSC_connect+0x4a0/0x4a0 [ 26.236123] ? selinux_secmark_relabel_packet+0xc0/0xc0 [ 26.241453] ? __do_page_fault+0x3d6/0xc90 [ 26.245665] ? selinux_netlbl_sock_rcv_skb+0x730/0x730 [ 26.250920] ? SyS_futex+0x269/0x390 [ 26.254598] ? SyS_setsockopt+0x215/0x360 [ 26.258713] ? do_futex+0x22a0/0x22a0 [ 26.262481] ? entry_SYSCALL_64_fastpath+0x5/0xa0 [ 26.267295] SyS_sendto+0x40/0x50 [ 26.270719] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 26.275444] RIP: 0033:0x4457e9 [ 26.278600] RSP: 002b:00007f33a5d0cda8 EFLAGS: 00000216 ORIG_RAX: 000000000000002c [ 26.286271] RAX: ffffffffffffffda RBX: 00000000006dac6c RCX: 00000000004457e9 [ 26.293508] RDX: 0000000000000001 RSI: 000000002010bf14 RDI: 0000000000000004 [ 26.300744] RBP: 00000000006dac68 R08: 00000000204d9000 R09: 000000000000001c [ 26.307979] R10: 0000000000000000 R11: 0000000000000216 R12: 0000000000000000 [ 26.315216] R13: 00007ffc9d3d276f R14: 00007f33a5d0d9c0 R15: 0000000000000001 [ 26.322469] [ 26.324064] Allocated by task 3521: [ 26.327661] save_stack+0x43/0xd0 [ 26.331086] kasan_kmalloc+0xad/0xe0 [ 26.334772] kasan_slab_alloc+0x12/0x20 [ 26.338711] kmem_cache_alloc+0x12e/0x760 [ 26.342824] sk_prot_alloc+0x65/0x2a0 [ 26.346589] sk_alloc+0x105/0x1440 [ 26.350110] sctp_v6_create_accept_sk+0x15a/0x9b0 [ 26.354919] sctp_accept+0x5c4/0x970 [ 26.358608] inet_accept+0x12c/0x930 [ 26.362287] SYSC_accept4+0x38d/0x870 [ 26.366051] SyS_accept+0x26/0x30 [ 26.369473] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 26.374191] [ 26.375785] Freed by task 3516: [ 26.379041] save_stack+0x43/0xd0 [ 26.382466] __kasan_slab_free+0x11a/0x170 [ 26.386672] kasan_slab_free+0xe/0x10 [ 26.390436] kmem_cache_free+0x86/0x2b0 [ 26.394389] __sk_destruct+0x622/0x910 [ 26.398240] sk_destruct+0x47/0x80 [ 26.401744] __sk_free+0xf1/0x2b0 [ 26.405162] sk_free+0x2a/0x40 [ 26.408320] sctp_association_put+0x14c/0x2f0 [ 26.412781] sctp_wait_for_sndbuf+0x673/0x8d0 [ 26.417240] sctp_sendmsg+0x28f7/0x33f0 [ 26.421180] inet_sendmsg+0x11f/0x5e0 [ 26.424946] sock_sendmsg+0xca/0x110 [ 26.428626] SYSC_sendto+0x361/0x5c0 [ 26.432306] SyS_sendto+0x40/0x50 [ 26.435727] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 26.440445] [ 26.442041] The buggy address belongs to the object at ffff8801bf3f6000 [ 26.442041] which belongs to the cache SCTPv6 of size 1888 [ 26.454326] The buggy address is located 140 bytes inside of [ 26.454326] 1888-byte region [ffff8801bf3f6000, ffff8801bf3f6760) [ 26.466249] The buggy address belongs to the page: [ 26.471143] page:ffffea0006fcfd80 count:1 mapcount:0 mapping:ffff8801bf3f6000 index:0x0 [ 26.479249] flags: 0x2fffc0000000100(slab) [ 26.483450] raw: 02fffc0000000100 ffff8801bf3f6000 0000000000000000 0000000100000002 [ 26.491303] raw: ffffea00074b43a0 ffffea0006fcffe0 ffff8801d2d0b980 0000000000000000 [ 26.499156] page dumped because: kasan: bad access detected [ 26.504829] [ 26.506424] Memory state around the buggy address: [ 26.511325] ffff8801bf3f5f80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff [ 26.518650] ffff8801bf3f6000: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 26.525974] >ffff8801bf3f6080: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 26.533304] ^ [ 26.536895] ffff8801bf3f6100: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 26.544225] ffff8801bf3f6180: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 26.551555] ================================================================== [ 26.558934] Kernel panic - not syncing: panic_on_warn set ... [ 26.558934] [ 26.566275] CPU: 1 PID: 3516 Comm: syzkaller247638 Tainted: G B 4.15.0-rc7-next-20180110+ #93 [ 26.576121] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 26.585442] Call Trace: [ 26.588016] dump_stack+0x194/0x257 [ 26.591612] ? arch_local_irq_restore+0x53/0x53 executing program [ 26.596250] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 26.600972] ? vsnprintf+0x1ed/0x1900 [ 26.604741] ? do_raw_spin_lock+0x120/0x220 [ 26.609031] panic+0x1e4/0x41c [ 26.612192] ? refcount_error_report+0x214/0x214 [ 26.616915] ? add_taint+0x1c/0x50 [ 26.620424] ? add_taint+0x1c/0x50 [ 26.623941] ? do_raw_spin_lock+0x1e0/0x220 [ 26.628242] kasan_end_report+0x50/0x50 [ 26.632184] kasan_report+0x148/0x360 [ 26.635955] __asan_report_load4_noabort+0x14/0x20 [ 26.640852] do_raw_spin_lock+0x1e0/0x220 [ 26.644972] _raw_spin_lock_bh+0x39/0x40 [ 26.649000] ? release_sock+0x74/0x2a0 [ 26.652855] release_sock+0x74/0x2a0 [ 26.656544] ? sctp_prsctp_prune+0x97/0x790 [ 26.660832] ? __release_sock+0x360/0x360 [ 26.664958] ? trace_hardirqs_on+0xd/0x10 [ 26.669077] sctp_sendmsg+0x2993/0x33f0 [ 26.673033] ? sctp_id2assoc+0x390/0x390 [ 26.677065] ? avc_has_perm+0x43e/0x680 [ 26.681007] ? avc_has_perm_noaudit+0x520/0x520 [ 26.685642] ? __fget+0x35c/0x570 [ 26.689064] ? iterate_fd+0x3f0/0x3f0 [ 26.692835] ? find_held_lock+0x35/0x1d0 [ 26.696868] ? sock_has_perm+0x2a4/0x420 [ 26.700907] ? lock_release+0x982/0xa40 [ 26.704846] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 26.710695] ? __check_object_size+0x8b/0x530 [ 26.715167] inet_sendmsg+0x11f/0x5e0 [ 26.718931] ? inet_sendmsg+0x11f/0x5e0 [ 26.722882] ? __might_sleep+0x95/0x190 [ 26.726823] ? inet_create+0xf50/0xf50 [ 26.730678] ? selinux_socket_sendmsg+0x36/0x40 [ 26.735311] ? security_socket_sendmsg+0x89/0xb0 [ 26.740034] ? inet_create+0xf50/0xf50 [ 26.743899] sock_sendmsg+0xca/0x110 [ 26.747589] SYSC_sendto+0x361/0x5c0 [ 26.751273] ? SYSC_connect+0x4a0/0x4a0 [ 26.755216] ? selinux_secmark_relabel_packet+0xc0/0xc0 [ 26.760548] ? __do_page_fault+0x3d6/0xc90 [ 26.764750] ? selinux_netlbl_sock_rcv_skb+0x730/0x730 [ 26.770004] ? SyS_futex+0x269/0x390 [ 26.773683] ? SyS_setsockopt+0x215/0x360 [ 26.777798] ? do_futex+0x22a0/0x22a0 [ 26.781565] ? entry_SYSCALL_64_fastpath+0x5/0xa0 [ 26.786387] SyS_sendto+0x40/0x50 [ 26.789819] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 26.794541] RIP: 0033:0x4457e9 [ 26.797696] RSP: 002b:00007f33a5d0cda8 EFLAGS: 00000216 ORIG_RAX: 000000000000002c [ 26.805369] RAX: ffffffffffffffda RBX: 00000000006dac6c RCX: 00000000004457e9 [ 26.812605] RDX: 0000000000000001 RSI: 000000002010bf14 RDI: 0000000000000004 [ 26.819849] RBP: 00000000006dac68 R08: 00000000204d9000 R09: 000000000000001c [ 26.827083] R10: 0000000000000000 R11: 0000000000000216 R12: 0000000000000000 [ 26.834318] R13: 00007ffc9d3d276f R14: 00007f33a5d0d9c0 R15: 0000000000000001 [ 26.841603] Dumping ftrace buffer: [ 26.845112] (ftrace buffer empty) [ 26.848788] Kernel Offset: disabled [ 26.852382] Rebooting in 86400 seconds..