[....] Starting enhanced syslogd: rsyslogd[ 17.701855] audit: type=1400 audit(1517604232.679:5): avc: denied { syslog } for pid=4029 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: [ 22.774883] audit: type=1400 audit(1517604237.752:6): avc: denied { map } for pid=4168 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.38' (ECDSA) to the list of known hosts. executing program [ 29.055484] audit: type=1400 audit(1517604244.033:7): avc: denied { map } for pid=4182 comm="syzkaller236586" path="/root/syzkaller236586102" 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 [ 29.058871] [ 29.081416] audit: type=1400 audit(1517604244.036:8): avc: denied { map } for pid=4182 comm="syzkaller236586" path="/dev/ashmem" dev="devtmpfs" ino=1194 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=system_u:object_r:device_t:s0 tclass=chr_file permissive=1 [ 29.082982] ====================================================== [ 29.082984] WARNING: possible circular locking dependency detected [ 29.082989] 4.15.0+ #293 Not tainted [ 29.082990] ------------------------------------------------------ [ 29.082996] syzkaller236586/4182 is trying to acquire lock: [ 29.135877] (&sb->s_type->i_mutex_key#11){++++}, at: [<00000000f7907249>] shmem_file_llseek+0xef/0x240 [ 29.145393] [ 29.145393] but task is already holding lock: [ 29.151328] (ashmem_mutex){+.+.}, at: [<00000000d4319e2b>] ashmem_llseek+0x56/0x1f0 [ 29.159179] [ 29.159179] which lock already depends on the new lock. [ 29.159179] [ 29.167461] [ 29.167461] the existing dependency chain (in reverse order) is: [ 29.175052] [ 29.175052] -> #2 (ashmem_mutex){+.+.}: [ 29.180487] __mutex_lock+0x16f/0x1a80 [ 29.184862] mutex_lock_nested+0x16/0x20 [ 29.189413] ashmem_mmap+0x53/0x410 [ 29.193525] mmap_region+0xa99/0x15a0 [ 29.197814] do_mmap+0x6c0/0xe00 [ 29.201670] vm_mmap_pgoff+0x1de/0x280 [ 29.206043] SyS_mmap_pgoff+0x462/0x5f0 [ 29.210506] SyS_mmap+0x16/0x20 [ 29.214276] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 29.219515] [ 29.219515] -> #1 (&mm->mmap_sem){++++}: [ 29.225028] __might_fault+0x13a/0x1d0 [ 29.229406] _copy_to_user+0x2c/0xc0 [ 29.233613] filldir+0x1a7/0x320 [ 29.237468] dcache_readdir+0x12d/0x5e0 [ 29.241931] iterate_dir+0x1ca/0x530 [ 29.246132] SyS_getdents+0x225/0x450 [ 29.250419] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 29.255658] [ 29.255658] -> #0 (&sb->s_type->i_mutex_key#11){++++}: [ 29.262385] lock_acquire+0x1d5/0x580 [ 29.266672] down_write+0x87/0x120 [ 29.270703] shmem_file_llseek+0xef/0x240 [ 29.275340] vfs_llseek+0xa2/0xd0 [ 29.279282] ashmem_llseek+0xe7/0x1f0 [ 29.283571] SyS_lseek+0xeb/0x170 [ 29.287512] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 29.292753] [ 29.292753] other info that might help us debug this: [ 29.292753] [ 29.300862] Chain exists of: [ 29.300862] &sb->s_type->i_mutex_key#11 --> &mm->mmap_sem --> ashmem_mutex [ 29.300862] [ 29.312364] Possible unsafe locking scenario: [ 29.312364] [ 29.318386] CPU0 CPU1 [ 29.323025] ---- ---- [ 29.327657] lock(ashmem_mutex); [ 29.331077] lock(&mm->mmap_sem); [ 29.337101] lock(ashmem_mutex); [ 29.343036] lock(&sb->s_type->i_mutex_key#11); [ 29.347773] [ 29.347773] *** DEADLOCK *** [ 29.347773] [ 29.353799] 1 lock held by syzkaller236586/4182: [ 29.358517] #0: (ashmem_mutex){+.+.}, at: [<00000000d4319e2b>] ashmem_llseek+0x56/0x1f0 [ 29.366805] [ 29.366805] stack backtrace: [ 29.371269] CPU: 0 PID: 4182 Comm: syzkaller236586 Not tainted 4.15.0+ #293 [ 29.378334] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 29.387656] Call Trace: [ 29.390213] dump_stack+0x194/0x257 [ 29.393809] ? arch_local_irq_restore+0x53/0x53 [ 29.398448] print_circular_bug.isra.38+0x2cd/0x2dc [ 29.403431] ? save_trace+0xe0/0x2b0 [ 29.407111] __lock_acquire+0x30a8/0x3e00 [ 29.411231] ? debug_check_no_locks_freed+0x3c0/0x3c0 [ 29.416389] ? ashmem_llseek+0x56/0x1f0 [ 29.420338] ? lock_release+0xa40/0xa40 [ 29.424283] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 29.430138] ? rcu_note_context_switch+0x710/0x710 [ 29.435037] ? vma_wants_writenotify+0x3b0/0x3b0 [ 29.439760] ? __might_sleep+0x95/0x190 [ 29.443702] ? ashmem_llseek+0x56/0x1f0 [ 29.447647] ? __mutex_lock+0x16f/0x1a80 [ 29.451675] ? ashmem_llseek+0x56/0x1f0 [ 29.455619] ? mmap_region+0x52e/0x15a0 [ 29.459738] ? ashmem_llseek+0x56/0x1f0 [ 29.463694] ? mutex_lock_io_nested+0x1900/0x1900 [ 29.468509] ? userfaultfd_unmap_complete+0x327/0x510 [ 29.473670] lock_acquire+0x1d5/0x580 [ 29.477437] ? lock_acquire+0x1d5/0x580 [ 29.481384] ? shmem_file_llseek+0xef/0x240 [ 29.485683] ? lock_release+0xa40/0xa40 [ 29.489627] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 29.495481] ? rcu_note_context_switch+0x710/0x710 [ 29.500378] ? __fget_light+0x297/0x380 [ 29.504321] ? __might_sleep+0x95/0x190 [ 29.508261] down_write+0x87/0x120 [ 29.512086] ? shmem_file_llseek+0xef/0x240 [ 29.516374] ? down_read+0x150/0x150 [ 29.520056] ? selinux_capable+0x40/0x40 [ 29.524087] shmem_file_llseek+0xef/0x240 [ 29.528203] ? shmem_free_swap+0x80/0x80 [ 29.532240] vfs_llseek+0xa2/0xd0 [ 29.535669] ashmem_llseek+0xe7/0x1f0 [ 29.539437] ? ashmem_read_iter+0x230/0x230 [ 29.543728] SyS_lseek+0xeb/0x170 [ 29.547149] entry_SYSCALL_64_fastpath+0x29/0xa0 [ 29.551873] RIP: 0033:0x43fd19 [ 29.555034] RSP: 002b:00007ff