Skip to contentSkip to conversation

IP + MAC + two subnets

DISCUSSION [email protected] 1 participant 1 message May 6, 2005

lore
Share & tools
lore
#0 lore raw
Quoted 8 lines
Quoted 7 lines

Is it possible to have two types of rules say :

1. for 192.168.0.0/24 IP + MAC filtering.

2. for 192.168.21.0/24 IP filtering.

Quoted 7 lines

yes.

Quoted 1 line

Thanks in advance

you're welcome in perpetuity.

-j

Sorry for the repost. While replying I din't
check the mail address.

Are the following rules OK :

1. Allow 192.168.0.5 ( IP + MAC filter )

A FORWARD -i eth1 -o eth0 -s 192.168.0.5 \
-m mac --mac-source XX:XX:XX:XX:XX:XX -j ACCEPT

2. Allow 192.168.21.5 ( IP filter )

A FORWARD -i eth1 -o eth0 -s 192.168.21.5 -j ACCEPT

DROP all other IPs

iptables -t filter -A FORWARD -i eth1 -o eth0 -s 192.168.0.0/24 -j DROP iptables -t filter -A FORWARD -i eth1 -o eth0 -s 192.168.21.0/24 -j DROP

Varun