1847086 Members
5936 Online
110262 Solutions
New Discussion

Re: Create FTP user

 
Mike_21
Frequent Advisor

Create FTP user

I would like to create a user who can only have FTP access to a specific directory, and not see anything else. We do have anonymous running. Can I just add this user to the passwd file, and set his directory to the /ftpdir/userx??

Thanks
8 REPLIES 8
Roger Baptiste
Honored Contributor

Re: Create FTP user

hi,

To give the user only ftp access, make the user SHELL as /usr/bin/false during the user creation.

HTH
raj
Take it easy.
Uday_S_Ankolekar
Honored Contributor

Re: Create FTP user

Hi,

Perform the following steps to create an ftp account that does not have
telnet access to a system:

1. Setup anonymous ftp.

2. Change the home directory for your user to that of ftp

Note: See /etc/passwd.

3. Change the shell to /usr/bin/false.

Goodluck,
-USA
Good Luck..
Christopher Caldwell
Honored Contributor

Re: Create FTP user

For access to specific directories (11.X), you need to set up a chroot environment for the user. The instructions are available from
man ftpaccess (find guestgroup).
Helen French
Honored Contributor

Re: Create FTP user

hey,

Check out this document in the Knowledge Base

#A5651654

HTH,

Shiju
Life is a promise, fulfill it!
Mike_21
Frequent Advisor

Re: Create FTP user

When I assign /usr/bin/false I get the following

Invalid user shell

Christopher Caldwell
Honored Contributor

Re: Create FTP user

you have to add /usr/bin/false to /etc/shells:

man ftpd:

ftpd authenticates users according to three rules:


+ The user must have a standard shell returned by
getusershell().


Kevin Wright
Honored Contributor

Re: Create FTP user

bin/false will only deny telnet access, but when you ftp, you will have access to the whole system..as mentioned, you need WU-ftpd server and setup a chroot environment. then use the /./ hack in /etc/passwd to chroot the ftp session.