Re: blocking certain IP addresses
Jeremy Kitchen <[email protected]> Fri, 18 Nov 2005 09:58:26 -0800
| Newsgroups | gmane.network.pureftpd.user |
|---|---|
| Organization | GreyStar Solutions |
| Message-ID | <[email protected]> |
On Sunday 13 November 2005 11:18 am, kalyan kumar wrote:
> i read in the documentation that this mailing list is for newbies and
> their silly questions.
> so here's my question
> i am on LAN.i have set up a server and using configuration file to
> mange the server.
> i want to block certain ip addresses from logging in .what do i do
I set up my pure-ftpd server under daemontools [1] and tcpserver [2]. This
allows me the flexibility of being able to set arbitrary environment
variables and allow, deny access on a per-IP or per-range basis (even though
pure-ftpd probably won't do anything with them, I could modify the
pure-config.pl script to do something with them....)
my 'run' script for pure-ftpd is fairly simple:
kitchen@tranquility ~ $ cat /service/ftp/run
#!/bin/sh
exec 2>&1
exec tcpserver -DHRl0 -v -c "50" -x /etc/tcprules.d/tcp.ftp.cdb 0 21 \
./pure-config.pl pure-ftpd.conf
the /etc/tcprules.d/tcp.ftp.cdb file is a 'tcprules' database that contains
access control information.
the pure-ftpd.conf settings is what really makes it work. here is the full
command line my run script calls pure-ftpd with:
kitchen@tranquility /service/ftp $ ./pure-showcmd.pl pure-ftpd.conf
Running: /usr/local/sbin/pure-ftpd -c50 -E -fftp -I15
-lpuredb:/etc/pureftpd.pdb -lunix -L2000:8 -m4 -s -U133:022 -u100 -w -k90 -Z
-Jeremy
[1]: http://cr.yp.to/daemontools.html
[2]: http://cr.yp.to/ucspi-tcp/tcpserver.html
--
Jeremy Kitchen ++ [email protected]
In the beginning was The Word and The Word was Content-type: text/plain
-- The Word of Bob.
signature.asc
(application/pgp-signature, 189 B)
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (GNU/Linux) iD8DBQBDfhZLyBTJv0gb9+IRAlNbAKDL2vsFRUk4qmM0Voo7tLQ1twHPzgCbBJJs m3culVBeR8xH3U9IxGp7wwM= =kn6a -----END PGP SIGNATURE-----