|Subject:||Re: [Jailkit-users] is it possible to "sudo su - user" to a jailkit user?|
|Date:||Thu, 30 May 2013 22:21:33 +0100|
I use the su command in this format to change to a jailed user "richard" in a jail created in "/home/scott"
address@hidden ~]# cat /etc/passwd| grep richard
address@hidden ~]# cat /home/scott/etc/passwd | grep richard
address@hidden ~]# su - richard
So the su command should work and start a shell if the jail is created correctly.
On 30/05/2013 22:14, Olivier Sessink wrote:
that is probably because the jk_chrootsh code is very strict and abort on anything that could be the start of hacking. su does a funny thing when calling the shell. su <> -c <> is explicitly enabled in the code (earlier versions aborted on su -c too). Olivier On 05/30/2013 02:56 AM, Marcus Eting wrote:Thanks Olivier and Rich. I changed the shell for the user to bash in /home/jail/etc/etc so I can SSH into the box as the user and the jail seems to be working fine - I have a pretty good understanding of what's going on with things so I think it is set up right. However, I can't "su testuser" but I was able to run "su testuser -c bash" to get the behavior I want - that bit of progress was pretty exciting. Do you know why it won't work without the "-c bash" ? _______________________________________________ Jailkit-users mailing list address@hidden https://lists.nongnu.org/mailman/listinfo/jailkit-users
|[Prev in Thread]||Current Thread||[Next in Thread]|