Operating System - HP-UX
1752603 Members
5310 Online
108788 Solutions
New Discussion юеВ

how to setup an account that can only use ftp function

 
SOLVED
Go to solution
Yu Zhen_1
Occasional Contributor

how to setup an account that can only use ftp function

i am trying to setup an account which can only use the ftp function, could you tell me how to make it happen?
5 REPLIES 5
Deepak Extross
Honored Contributor

Re: how to setup an account that can only use ftp function

By "only ftp", do you mean that the user should not be allowed do anything else, even a 'ls' or 'cd'?
In that case, you can add the following in the user's startup script ($HOME/.profile or $HOME/.login):
exec ftp

Hope this helps.
Michael Tully
Honored Contributor
Solution

Re: how to setup an account that can only use ftp function

Hi,

Set up the account as normal, except
change the users shell to be
/usr/bin/false

Entry should appear as this:
fred:FqK/ouvuPutg2:102:199:FTP account,,,:/home/ftpdir:/usr/bin/false

HTH
-Michael
Anyone for a Mutiny ?
Yu Zhen_1
Occasional Contributor

Re: how to setup an account that can only use ftp function

thanks for your help.
I have tried to setup an account with /usr/bin/false, but it doesn't work.
when I ftp from the other box, and type in the ftpuser, the connection was closed immediately.
My intent is to setup this account which can be used by the other systems. Any more advices?
Deepak Extross
Honored Contributor

Re: how to setup an account that can only use ftp function

Yu Zhen_1
Occasional Contributor

Re: how to setup an account that can only use ftp function

Michael, your suggestion works after I edited the /etc/shells to include the /usr/bin/false.
Deepak, thanks for your reference.