handling of 'use chroot'

John E. Malmberg malmberg at Encompasserve.org
Sat Sep 1 06:09:06 EST 2001


The OpenVMS C runtime support currently does not have a chroot().

So I have to go to "The Single UNIX (R) specification, Version 2 from The
Open Group" web pages to find out what it does.

It lists the function as LEGACY implying that it should not be used in
new code.  It also states that "There is no portable use that an
application can make of this interface."


The concept of a single root directory does not exist on OpenVMS.
As such, the chroot() function does not mean anything more than chdir().

My guess is that on UNIX, it's main purpose is to prevent ".." from
traversing below a certain point in the directory tree.  Primarily to
prevent an application running as root or setuid from using a relative
path to gain unintended access to files.

The concept of a single root directory does not exist on OpenVMS.
As such I have been aliasing chroot() to just be chdir() just to get
rid of the "no chroot" diagnostics.


In the OpenVMS environment, it appears that there should be little reason
to run the rsyncd as the "root" equivalent account.  I will probably have
to look at this issue further to determine what the root type privileges
are used for.

-John
wb8tyw at qsl.network
Personal Opinion Only





More information about the rsync mailing list