emerson2703
(usa CentOS)
Enviado em 28/07/2009 - 08:59h
colega como faço para o roteamento, de dois links de internet no firewall com iptables colocar a eth2 como outro link de internet
# Generated by iptables-save v1.3.5 on Sat Jul 11 14:45:48 2009
*nat
:PREROUTING ACCEPT [247:25323]
:POSTROUTING ACCEPT [7:415]
:OUTPUT ACCEPT [7:415]
-A PREROUTING -i eth0 -p tcp -m tcp --dport 80 -j REDIRECT --to-ports 3128
# Bloqueio de MSN
-A PREROUTING -p tcp -m tcp --dport 1863 -m mac --mac-source 00:17:C4:01:6F:E6 -j DROP
-A PREROUTING -p tcp -m tcp --dport 1863 -m mac --mac-source 00:1D:7D:36:D1:FC -j DROP
-A POSTROUTING -o eth1 -j MASQUERADE
COMMIT
# Completed on Sat Jul 11 14:45:48 2009
# Generated by iptables-save v1.3.5 on Sat Jul 11 14:45:48 2009
*filter
:INPUT DROP [3:287]
:FORWARD DROP [216:10833]
:OUTPUT DROP [14:1170]
-A INPUT -m state --state RELATED,ESTABLISHED -j ACCEPT
-A INPUT -i lo -j ACCEPT
-A INPUT -i eth0 -j ACCEPT
-A INPUT -i eth1 -j ACCEPT
-A INPUT -p tcp -m tcp --dport 80 -j ACCEPT
-A INPUT -p icmp --icmp-type echo-request -j ACCEPT
-A FORWARD -m state --state RELATED,ESTABLISHED -j ACCEPT
# Liberacao de Internet e Sistema
-A FORWARD -p tcp -m tcp --dport 1863 -j ACCEPT
-A FORWARD -p tcp -m tcp --dport 80 -j ACCEPT
-A FORWARD -p tcp -m tcp --dport 8080 -j ACCEPT
-A FORWARD -p tcp -m tcp --dport 53 -j ACCEPT
-A FORWARD -p tcp -m tcp --dport 443 -j ACCEPT
# Liberacao de Envio e Recebimento de E-mail
-A FORWARD -p tcp -m tcp --dport 110 -j ACCEPT
-A FORWARD -p tcp -m tcp --dport 465 -j ACCEPT
-A FORWARD -p tcp -m tcp --dport 25 -j ACCEPT
# Liberacao Conexao Remota (Teminal Server, VNC e Puty)
-A FORWARD -p tcp -m tcp --dport 3389 -j ACCEPT
-A FORWARD -d 192.168.0.110 -j ACCEPT
-A FORWARD -d 192.168.0.191 -j ACCEPT
-A FORWARD -d 192.168.254.109 -j ACCEPT
-A FORWARD -d 192.168.254.114 -j ACCEPT
-A FORWARD -d 192.168.254.115 -j ACCEPT
-A FORWARD -d 192.168.254.116 -j ACCEPT
-A FORWARD -d 10.104.0.30 -j ACCEPT
-A FORWARD -d 10.104.0.63 -j ACCEPT
-A FORWARD -d 10.104.0.80 -j ACCEPT
-A FORWARD -d 10.104.0.135 -j ACCEPT
-A FORWARD -p tcp -m tcp --dport 137 -j ACCEPT
-A FORWARD -p tcp -m tcp --dport 138 -j ACCEPT
-A FORWARD -p tcp -m tcp --dport 139 -j ACCEPT
-A FORWARD -p tcp -m tcp --dport 4901 -j ACCEPT
-A FORWARD -p tcp -m tcp --dport 22 -j ACCEPT
-A OUTPUT -m state --state RELATED,ESTABLISHED -j ACCEPT
-A OUTPUT -o lo -j ACCEPT
-A OUTPUT -o eth0 -j ACCEPT
-A OUTPUT -o eth1 -j ACCEPT
-A OUTPUT -p tcp -m tcp --dport 80 -j ACCEPT
COMMIT
# Completed on Sat Jul 11 14:45:48 2009