Re: virtual ftp folders
On Wed, Feb 05, 2003 at 09:07:15AM -0600, Bernie Berg wrote:
> Howdy,
> I'm running woody with with the woody packages. I would like to
> make it so when a user logs in via ftp they only see the folder a specify,
> not the entire file structure. What would be the best ftp server to use
> for the task, and how would I configure it? I currently use proftp.
>
> Thanks!
>
> --
> Bernie Berg | bberg@circadesign.com
> Network Administrator | Office:(605)362-6361
> Circa Design Company | Cell:(605)359-2237
You might not find this useful since it's about vsftpd, but here it is:
pepe@espai5:~$ egrep -v '#|^ *$' /etc/vsftpd.conf
anonymous_enable=NO
local_enable=YES
write_enable=YES
local_umask=027
dirmessage_enable=YES
xferlog_enable=YES
connect_from_port_20=YES
nopriv_user=vsftp
ftpd_banner=Wellcome to my FTP service!
chroot_local_user=YES
And that's all. Currently I'm not using virtual users, maybe that's why
it's been so simple. "chroot_local_user=YES" does the magic of keeping
each user within their corresponding "cage".
Pay attention to "nopriv_user=vsftp". 'vsftpd' is a system user (no group,
uid < 1000) created with
adduser --system --no-create-home --shell /bin/false --disabled-login vsftp
For completeness:
/etc/inetd.conf
...
ftp stream tcp nowait root /usr/sbin/tcpd /usr/sbin/vsftpd
...
/etc/hosts.allow
...
vsftpd: <whatever which is enough>
...
Pepe.
--
José Marcos Chalmés García - Public key ID: 0x6FDE933B / gnupg.org
www.polinux.upv.es - www.debian.org - www.gnu.org - www.bsd.org - ...
I use free software | Utilitze programari lliure | Uso software libre
---------------------------------------------------------------------
Reply to: