Document a bug in our chroot(2) implementation: if access control

checks, including the "open directory" check or a MAC check fail,
after the working directory of the process has been changed, then
the cwd of the process will be left as the target directory rather
than the original directory.

At some point, this bug might be fixable by performing the directory
change only after permission is granted for the change.  In the
mean time document it (it's been there for a while).
This commit is contained in:
Robert Watson 2003-01-31 21:19:22 +00:00
parent a908904a1e
commit bd5466d65a

View file

@ -137,3 +137,9 @@ The
.Fn chroot
system call appeared in
.Bx 4.2 .
.Sh BUGS
If the process is able to change its working directory to the target
directory, but another access control check fails (such as a check for
open directories, or a MAC check), it is possible that this system
call may return an error, with the working directory of the process
left changed.