Operating System - HP-UX
1837106 Members
2252 Online
110112 Solutions
New Discussion

Re: setting the user root directory

 
Don Ferderber_1
Occasional Advisor

setting the user root directory


I am attempting to set up a few users with restricted directories. When they ftp in they are able to move around freely. So I amattempting to use the suggestions given in the man pages of ftpaccess. Here is the changes I have made to the passwd file..

gsds:u2GKr011vo5RU:515:515:GSDSRepository:/NGCS/./gsds:/bin/ksh

I want to not have the ability to move past the NGCS directory. I amnot sure what I am forgetting but any help would be appreciated.
4 REPLIES 4
Sridhar Bhaskarla
Honored Contributor

Re: setting the user root directory

Hi,

You will also have to configure your ftpaccess file.

Create a group called 'guest' (or anything that you want) and add it as a guestgroup in ftpaccess file. Make gsds as a member of this guest group.

guestgroup guest

Try to ftp again. When you ftp you should see the following message.

230 User gsds logged in. Access restrictions apply.
Remote system type is UNIX.
Using binary mode to transfer files.
ftp>pwd

You can also put other restrictions like

chmod no guest
delete no guest

etc.,

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Don Ferderber_1
Occasional Advisor

Re: setting the user root directory


Ok .. I must be opushing my luck here. What would that entry look like. I am confused about the class entry and where the group is set etc...
Don Ferderber_1
Occasional Advisor

Re: setting the user root directory


Sorry my file looks something like this right now ..

class local real,anonymous *.domain 0.0.0.0
class remote real,anonymous *

# Display secure Nortel Networks banner
banner /etc/ftpd/ftpd_banner

suppresshostname yes
suppressversion yes
Sridhar Bhaskarla
Honored Contributor

Re: setting the user root directory

Create a group called "guest" and add gsds as a member to it.

$grep guest /etc/group
guest::2001:gsds

Your ftpaccess should look like this

class local real,anonymous *.domain 0.0.0.0
class remote real,anonymous *

# Display secure Nortel Networks banner
banner /etc/ftpd/ftpd_banner

suppresshostname yes
suppressversion yes
guestgroup guest

Try 'ftp' to verify it.

-Sri

You may be disappointed if you fail, but you are doomed if you don't try