Date: Fri, 8 Oct 1999 17:12:37 -0400 From: Justin Wells <jread@semiotek.com> To: freebsd-security@freebsd.org Subject: more on chroot: "nochroot" filesystems Message-ID: <19991008171237.B1618@fever.semiotek.com>
next in thread | raw e-mail | index | archive | help
One more thing, a suggestion this time... I lurked through the previous discussion of chroot and it's been sitting in my mind ever since, fermenting. Here's a possible solution that wouldn't do too much damage to the standard chroot behavior: Add an option, similar to nodev and noexec, to the UFS filesystem called "nochroot". You are only allowed to chroot if the root of the filesystem you are currently in allows chroot. Thus the first chroot (with / as its root) would succeed because / allows chroot, but its target would be inside a filesystem with the nochroot flag. Further chroots would be disallowed. This solution has zero effect by default, since by default chroot is allowed. Only people who ask for this behavior by specifying the mount option would have the restriction imposed on them. This defeats the "cd ../../../../../.. ; chroot ." trick, and many others. Justin To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-security" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19991008171237.B1618>