Date: Mon, 26 May 1997 23:30:13 +0200 From: Peter Korsten <peter@grendel.IAEhv.nl> To: Jaye Mathisen <mrcpu@cdsnet.net> Cc: hackers@FreeBSD.ORG Subject: Re: Correct way to chroot for shell account users? Message-ID: <19970526233013.13944@hw.nl> In-Reply-To: <Pine.NEB.3.95.970525144745.28807A-100000@mail.cdsnet.net>; from Jaye Mathisen on Sun, May 25, 1997 at 02:50:55PM -0700 References: <Pine.NEB.3.95.970525144745.28807A-100000@mail.cdsnet.net>
next in thread | previous in thread | raw e-mail | index | archive | help
Jaye Mathisen shared with us: > > Anybody got any tips on how to write a secure shell to exec on login to > set a users environment to the "right thing". > > (I don't mean a rsh type secure shell, but rather a good secure thing > to have in /etc/master.passwd that execs the real shell in a chroot'd > environment.). I don't think you can build a real shell (like sh or csh) and have it run safely inside a chroot environment. Someone (as a matter of fact, the FreeBSD security officer :) ) showed me how to break out of a chroot environment with a simple 'ln' or something like that. Indeed, you'd better use a restricted Lynx. With a shell, you would have to disable everything that could cause a break out of the chroot cage. It's better to permit certain actions than to have to forbid them. - Peter
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19970526233013.13944>