Subject: Re: chmod +

From: [email-masked] (Andy Church)
Date: Fri, 03 Oct 1997 13:54:05 EDT

>Each user has a home directory in /home/users/uname
>
>When they ftp in, they are chroot'd into their homes and locked their. From
>there, they can modify their personal web documents.
>
>BUT, some users are working as groups to make department web documents
>stored in /home/web/depts/dept-name.
>
>Those who can only access the server via ftp need to ftp into that
>directory. I would like the same locked environment they have in their home
>directories that the chroot provides. Unfortunatly, I can't figure a way to
>allow them to ftp, chroot'd, into multiple directories.

     So it sounds like what you want to be able to happen is this:

mymachine:~> ftp your.machine
Username: joe
Password: <whatever>
ftp> cd /
ftp> put file.in.joes.home.directory
ftp> cd /depts/dept-name
ftp> put file.in.dept.directory

     If this is what you're looking for, it's not possible; the best you
could do would be chroot them to /home and have them start out in their
home directory (i.e. the directory entry in /etc/passwd would be
/home/./users/uname).  Of course, another option is simply to assign them
a second username with the same UID but a different home directory, e.g.:

joe:x:501:100:Joe User:/home/users/joe:/bin/false
joe2:x:501:100:Joe User:/home/web/depts/joes-dept:/bin/false

I haven't tested this approach, mind you, but it _ought_ to work, at least
theoretically...

  --Andy Church                  | If Bell Atlantic really is the heart
    [email-masked]       | of communication, then it desperately
    www.dragonfire.net/~achurch/ | needs a quadruple bypass.