Link to home
Start Free TrialLog in
Avatar of kuanglee
kuanglee

asked on

How to configure the iptables

I have RH 9 machine with one NIC. I want to block all port other than 25,53 and 110 (mail and DNS) how can I do that? Can I just type the code below in terminal?

#iptables -P INPUT DROP
#iptables -P OUTPUT DROP
#iptables -P FORWARD DROP
#iptables -A INPUT -p tcp -m multiport --destination-port 25,53,110 -j ACCEPT
#iptables -A INPUT -p udp -m multiport --destination-port 25,53,110 -j ACCEPT

SOLUTION
Avatar of TroubleNow
TroubleNow

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of kuanglee
kuanglee

ASKER

How can I do that? (protect against the ping of dead and flood protection).
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
what natma sayd ..

thats your answer.. :)
SOLUTION
Avatar of Cyclops3590
Cyclops3590
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial