On Fri, Apr 12, 2002 at 11:17:38AM +0200, Lars Roland Kristiansen wrote:
> Hi - i have just installed an mailserver with postfix and wu-imap/pop3
> now i just want to have iptables running. I am no iptables guro, i just
> want to close all exept from ssh(port 22), pop3(port 110) and 
> imap(port143). Is there and easy way to do this. ????

Sure it is easy...
iptables -P INPUT DROP
iptables -I INPUT -p tcp -s 0/0 --dport $port -i $dev -j DROP

where dev is your interface , and port is your port (last rule have to be
written thre times , each one for every port)

This is the easiest way ,(i'm not saying the best :) )


> 
> ___
> Mvh./Yours sincerely
> 
> Lars 
> 

-- 
Michael "carstein" Melewski      |      "One day, he said, in a taped segment   
[EMAIL PROTECTED]        |       that suggested chemical interrogation,
mobile: 502 545 913              |       everything had gone gray."
gpg: carstein.c.pl/carstein.txt  |       -- Corto , 'Neuromancer'

Attachment: pgpUX6VEhB7N8.pgp
Description: PGP signature

Reply via email to