chroot()

rsm%brl-bmd at sri-unix.UUCP rsm%brl-bmd at sri-unix.UUCP
Thu Jul 7 13:26:43 AEST 1983


From:      Robert S. Miles <rsm at brl-bmd>

You're both right!  The concept of each process having is own pointer
to a "root directory" introduced in UNIX Version 7 was not implemented
in a completely "secure" manner.  As you have shown, on a V7 system it
is possible to to access ".." above your root directory.  On System III,
BSD 4.1, and BSD 4.2 UNIX systems the kernel actually checks to see if
you're accessing the name ".." in the root directory, if so it just remaps
".." to be your root directory.  Therefore "/.." will always be the same
as "/" on one of these more modern systems.

					-Bob Miles, rsm at BRL



More information about the Comp.unix.wizards mailing list