From: dominick.grift@gmail.com (Dominick Grift) Date: Wed, 24 Apr 2013 22:21:00 +0200 Subject: [refpolicy] Problem with chroot login on a RHEL6 Selinux system In-Reply-To: <51770B8E.5060803@library.berkeley.edu> References: <51770B8E.5060803@library.berkeley.edu> Message-ID: <1366834860.4562.108.camel@x220.localdomain> To: refpolicy@oss.tresys.com List-Id: refpolicy.oss.tresys.com On Tue, 2013-04-23 at 15:30 -0700, Garey Mills wrote: > Apr 22 15:10:44 srblib3 kernel: type=1400 audit(1366668644.309:100143): > avc: denied { transition } for pid=4852 comm="sshd" path="/bin/sh" > dev=sda3 ino=524299 > scontext=system_u:system_r:chroot_user_t:s0-s0:c0.c1023 > tcontext=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 > tclass=process > > Trying to solve this by going to Google, I found that this problem (that > 'chroot_user_t' cannot 'transition' to the sh process) had been solved > and patches submitted on a Debian Selinux list, but apparently not in > RHEL6. > > Does anyone know a solution to this that could be applied by > someone who knows how to use audit2allow but not much else about Selinux? > Hmm, i remember that i encountered this issue as well and i also thought that i brought the issue to the fedora list but i cannot find any related mails so maybe i am just mistaken. I also do not remember how i solved this issue, other than that i decided to just map the user account to guest_u and that now the sftpchrootuser logs in a guest_u. I seem to have not added any custom policy with regard to this although i do seem to have some related booleans set like: setsebool -P selinuxuser_use_ssh_chroot on Not sure if that fixed it for me unfortunately.