[....] Starting enhanced syslogd: rsyslogd[ 13.162530] audit: type=1400 audit(1546377292.152:4): avc: denied { syslog } for pid=1919 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 Warning: Permanently added '10.128.0.61' (ECDSA) to the list of known hosts. executing program syzkaller login: [ 33.478490] [ 33.480272] ====================================================== [ 33.486561] [ INFO: possible circular locking dependency detected ] [ 33.492937] 4.4.169+ #1 Not tainted [ 33.496528] ------------------------------------------------------- [ 33.503044] syz-executor660/2073 is trying to acquire lock: [ 33.508739] (&pipe->mutex/1){+.+.+.}, at: [] fifo_open+0x15d/0xa00 [ 33.517279] [ 33.517279] but task is already holding lock: [ 33.523220] (&sig->cred_guard_mutex){+.+.+.}, at: [] prepare_bprm_creds+0x55/0x120 [ 33.533044] [ 33.533044] which lock already depends on the new lock. [ 33.533044] [ 33.541330] [ 33.541330] the existing dependency chain (in reverse order) is: [ 33.548923] -> #1 (&sig->cred_guard_mutex){+.+.+.}: [ 33.554565] [] lock_acquire+0x15e/0x450 [ 33.560810] [] mutex_lock_interruptible_nested+0xd2/0xce0 [ 33.568616] [] proc_pid_attr_write+0x1a8/0x2a0 [ 33.575474] [] __vfs_write+0x116/0x3d0 [ 33.581623] [] __kernel_write+0x112/0x370 [ 33.588042] [] write_pipe_buf+0x15d/0x1f0 [ 33.594458] [] __splice_from_pipe+0x37e/0x7a0 [ 33.601219] [] splice_from_pipe+0x108/0x170 [ 33.607803] [] default_file_splice_write+0x3c/0x80 [ 33.615012] [] SyS_splice+0xd71/0x13a0 [ 33.621165] [] entry_SYSCALL_64_fastpath+0x1e/0x9a [ 33.628358] -> #0 (&pipe->mutex/1){+.+.+.}: [ 33.633434] [] __lock_acquire+0x37d6/0x4f50 [ 33.640016] [] lock_acquire+0x15e/0x450 [ 33.646253] [] mutex_lock_nested+0xc1/0xb80 [ 33.652836] [] fifo_open+0x15d/0xa00 [ 33.658807] [] do_dentry_open+0x38f/0xbd0 [ 33.665247] [] vfs_open+0x10b/0x210 [ 33.671163] [] path_openat+0x136f/0x4470 [ 33.677481] [] do_filp_open+0x1a1/0x270 [ 33.683718] [] do_open_execat+0x10c/0x6e0 [ 33.690124] [] do_execveat_common.isra.0+0x6f6/0x1e90 [ 33.697575] [] SyS_execve+0x42/0x50 [ 33.703461] [] return_from_execve+0x0/0x23 [ 33.709955] [ 33.709955] other info that might help us debug this: [ 33.709955] [ 33.718068] Possible unsafe locking scenario: [ 33.718068] [ 33.724096] CPU0 CPU1 [ 33.728734] ---- ---- [ 33.733369] lock(&sig->cred_guard_mutex); [ 33.737899] lock(&pipe->mutex/1); [ 33.744365] lock(&sig->cred_guard_mutex); [ 33.751412] lock(&pipe->mutex/1); [ 33.755369] [ 33.755369] *** DEADLOCK *** [ 33.755369] [ 33.761406] 1 lock held by syz-executor660/2073: [ 33.766146] #0: (&sig->cred_guard_mutex){+.+.+.}, at: [] prepare_bprm_creds+0x55/0x120 [ 33.776517] [ 33.776517] stack backtrace: [ 33.780987] CPU: 0 PID: 2073 Comm: syz-executor660 Not tainted 4.4.169+ #1 [ 33.787968] 0000000000000000 f30260fe0067902d ffff8800b6edf530 ffffffff81aab9c1 [ 33.795949] ffffffff84055ac0 ffff8800b808c740 ffffffff83abb2b0 ffffffff83ab4500 [ 33.803933] ffffffff83abb2b0 ffff8800b6edf580 ffffffff813abaf4 ffff8800b6edf660 [ 33.811910] Call Trace: [ 33.814500] [] dump_stack+0xc1/0x120 [ 33.819834] [] print_circular_bug.cold+0x2f7/0x44e [ 33.826414] [] __lock_acquire+0x37d6/0x4f50 [ 33.832361] [] ? trace_hardirqs_on+0x10/0x10 [ 33.838413] [] ? do_filp_open+0x1a1/0x270 [ 33.844184] [] ? do_execveat_common.isra.0+0x6f6/0x1e90 [ 33.851206] [] ? SyS_execve+0x42/0x50 [ 33.856635] [] ? stub_execve+0x5/0x5 [ 33.861983] [] ? debug_lockdep_rcu_enabled+0x71/0xa0 [ 33.868708] [] ? debug_lockdep_rcu_enabled+0x71/0xa0 [ 33.875436] [] lock_acquire+0x15e/0x450 [ 33.881030] [] ? fifo_open+0x15d/0xa00 [ 33.886543] [] ? fifo_open+0x15d/0xa00 [ 33.892058] [] mutex_lock_nested+0xc1/0xb80 [ 33.898000] [] ? fifo_open+0x15d/0xa00 [ 33.903513] [] ? debug_lockdep_rcu_enabled+0x71/0xa0 [ 33.910240] [] ? mutex_trylock+0x500/0x500 [ 33.916095] [] ? fifo_open+0x24d/0xa00 [ 33.921606] [] ? fifo_open+0x28c/0xa00 [ 33.927114] [] fifo_open+0x15d/0xa00 [ 33.932450] [] do_dentry_open+0x38f/0xbd0 [ 33.938220] [] ? __inode_permission2+0x9e/0x250 [ 33.944511] [] ? pipe_release+0x250/0x250 [ 33.950279] [] vfs_open+0x10b/0x210 [ 33.955526] [] ? may_open.isra.0+0xe7/0x210 [ 33.961475] [] path_openat+0x136f/0x4470 [ 33.967159] [] ? depot_save_stack+0x1c3/0x5f0 [ 33.973276] [] ? may_open.isra.0+0x210/0x210 [ 33.979303] [] ? kmemdup+0x27/0x60 [ 33.984471] [] ? selinux_cred_prepare+0x43/0xa0 [ 33.990761] [] ? security_prepare_creds+0x83/0xc0 [ 33.997230] [] ? prepare_creds+0x228/0x2b0 [ 34.003084] [] ? prepare_exec_creds+0x12/0xf0 [ 34.009201] [] ? do_execveat_common.isra.0+0x2d6/0x1e90 [ 34.016186] [] ? stub_execve+0x5/0x5 [ 34.021522] [] ? kasan_kmalloc+0xb7/0xd0 [ 34.027203] [] ? kasan_slab_alloc+0xf/0x20 [ 34.033074] [] ? kmem_cache_alloc+0xdc/0x2c0 [ 34.039114] [] ? prepare_creds+0x28/0x2b0 [ 34.044882] [] ? prepare_exec_creds+0x12/0xf0 [ 34.050998] [] do_filp_open+0x1a1/0x270 [ 34.056600] [] ? user_path_mountpoint_at+0x50/0x50 [ 34.063153] [] ? new_slab+0x2a1/0x380 [ 34.068575] [] ? __lock_acquire+0xa4f/0x4f50 [ 34.074608] [] ? trace_hardirqs_on+0x10/0x10 [ 34.080635] [] ? rcu_read_lock_sched_held+0x10b/0x130 [ 34.087451] [] do_open_execat+0x10c/0x6e0 [ 34.093222] [] ? debug_lockdep_rcu_enabled+0x71/0xa0 [ 34.099961] [] ? setup_arg_pages+0x7b0/0x7b0 [ 34.105990] [] ? do_execveat_common.isra.0+0x6b8/0x1e90 [ 34.112977] [] do_execveat_common.isra.0+0x6f6/0x1e90 [ 34.119788] [] ? do_execveat_common.isra.0+0x422/0x1e90 [ 34.126775] [] ? __check_object_s