Click to See Complete Forum and Search --> : FTP Permissions


MysticMike
07-26-2001, 01:45 PM
Greetings,

True newbie here, trying to set ftp permissions on our RH7 wu-ftp server. We have a few clients that need ftp access to their webpages. I have it configured to allow them in, but they can access any directory on the box (other than the password and core files). How do I restrict them to their home directories? TFTH.

mychl
07-26-2001, 03:26 PM
One thing you might try (I hope someone else answers you also) is to make a group for each user, and allow only that group to access each individual directory.

If user mike belongs to group mike, then you can just let group mike access mike's home dir.

HTH
Good Luck
:)

MysticMike
07-26-2001, 03:40 PM
Yes, I tried this, and it works to a certain extent in that one user cannot access another users web directory. I.E. User1 ftp's into their home directory, they are able to go to every directory on the box except user2's home directory where they get a permission denied error. I'm going to try to take away 'other' permissions on the toplevel directory. Anyone think of anything else? Thanks for the reply.

hux
07-26-2001, 04:18 PM
as root:

pico /etc/ftpaccess

below the line

allow-gid ftp

add this:

restricted-uid *
unrestricted-uid username

I think you'll not hafta reboot...works on RH7.1, locks em in to their ~username directory, anybody you specify after the unrestricted tag is not restricted other than file permissions.

credit to the late great craig mcpherson.

MysticMike
07-27-2001, 06:47 PM
Hate to say it, after having to rebuild the box :eek: I got everything back to the way it was, tried this configuration, and while it didn't break the ftp ability for those users, it didn't fix the problem at all. They can still access any directory or file on the box. Something so simple shouldn't be so difficult! Anyone else have any suggestions?

APHRODITE007
07-31-2001, 10:12 AM
1. have u added user in /etc/passwd.
should be like this:
zeus:x:1007:100:Zeus:/home/zeus:/bin/false
thus home dir set

2. chown -R zeus zeus/homedir/

3. chmod drwxr-xr-x 9 zeus users

this should sort it out
can put all sub users of site into group zeus-xxx