This is a discussion on Iptables rules between subnets eth1 WLAN eth2 LAN within the Linux Security forums, part of the System Security and Security Related category; I have 3 networkcards eth0,1,2 eth0=internet I want a rule between eth1 and eth2 eth1= wirelesslan eth2= ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
I have 3 networkcards eth0,1,2
eth0=internet I want a rule between eth1 and eth2 eth1= wirelesslan eth2= servers Windows 2000, LAN So the wireless lan users go only to tcp port 25,80,100,110,143,443 to eth2 I think the firewall works whit first open and at last close everything? /etc/rc.d/rc.firewall.local # Custom firewall rules. # This file is executed by the firewall on stop/start/restart WAP_IF="eth1" #nothing WLAN INT_IF="eth2" # DMZ (LAN) INT_LAN_IP=`ifconfig $INT_IF | grep inet | cut -d : -f 2 | cut -d \ -f 1 | cut -d . -f 1,2,3` INT_LAN=$INT_LAN_IP.0/24 WAP_TCP_PORTS_LAN_ALLOWED="25,80,100,110,143,443" #$IPTABLES -A FORWARD -i $WAP_IF -d $INT_LAN -p tcp -m multiport --destination-ports $WAP_TCP_PORTS_LAN_ALLOWED -m state --state NEW -j ACCEPT $IPTABLES -A FORWARD -i $WAP_IF -d $INT_LAN -j DROP |