Click to See Complete Forum and Search --> : Restricting Users to FTP only


pushback
02-02-2003, 03:54 PM
Anyone know how to restrict a user to ftp access only on RH 7.3?

Thanks!

slapNUT
02-02-2003, 04:16 PM
Are you saying you want to restrict one particular user to only be able to ftp into your computer?

Or you want to restrict one user of your computer to only be able to ftp out?

pushback
02-03-2003, 05:14 AM
I would to grant ftp access for a somone to ftp in to the box. I do not want them to be able to login and get to a shell, like via telnet or ssh.

adikgede
02-03-2003, 02:57 PM
In the /etc/passwd file change thier shell from /bin/bash to /bin/false . I think that there was a tick box for this in the linuxconf adduser wizard.

ag

pushback
02-03-2003, 10:39 PM
That does not seem to do it :(

raleigh:x:550:500::/home/ral:/bin/false

ftp> user ral
331 Password required for ral.
Password:
530 Login incorrect.
Login failed.


raleigh:x:550:500::/home/ral:/bin/bash

ftp> user ral
331 Password required for ral.
Password:
230 User ral logged in.
ftp>

Obrion
02-04-2003, 12:27 AM
when you make a user account make the shell this

/bin/false


see if that works

adikgede
02-04-2003, 02:45 AM
Then try changing /etc/shadow instead

BigCletus
02-05-2003, 01:42 AM
Originally posted by pushback
I would to grant ftp access for a somone to ftp in to the box. I do not want them to be able to login and get to a shell, like via telnet or ssh.

why don't you just edit your /etc/hosts.allow/deny files?

hetman
02-05-2003, 05:18 AM
another solution that works (which is what i used) is to have proftpd run with a database server (mysql for example). you can setup the ftp server to look to the database for the user/passwd homedir... etc... its a really good way to keep track of who can and cant access your server.

i even setup a transfer log system on the database for better record keeping... you can do this in a log file but the database makes it more handy to sort thru.

check out proftp and the sql modules.

momo
02-05-2003, 12:39 PM
Originally posted by adikgede
In the /etc/passwd file change thier shell from /bin/bash to /bin/false . I think that there was a tick box for this in the linuxconf adduser wizard.

ag

I think the above should do the trick, just make sure you have /bin/false in your /etc/shells file otherwise, I don't think it will work.....