How to invert tc matches?

Linux Advanced Routing and Traffic Control

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

I want to use inverted matches with tc-filter. I tried to invert the
matches with a "!", but this doesn't seem to be the correct syntax.


The following rules don't work:

---------------------------snip-----------------------------------------

$TC filter $ACTION dev $DEV protocol ip parent 1:0 u32 match ip src
${NETWORK[$i]} !match ip dst 192.168.0.0/24 flowid 1:$(($(($i+1))*10));

------------------------------------------------------------------------

$TC filter $ACTION dev $DEV protocol ip parent 1:0 u32 match ip src
${NETWORK[$i]} match ip dst !192.168.0.0/24 flowid 1:$(($(($i+1))*10));

---------------------------snap-----------------------------------------

The rules should match all ip packets coming from networks in
192.168.0.XXX (the NETWORK[]-Array) but not match if the packets are
destinated for 192.168.0.0/24 as this is my internal network ;-)

Thanx for any hint

Rene Bartsch




_______________________________________________
LARTC mailing list / LARTC@xxxxxxxxxxxxxxx
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

[Index of Archives]     [LARTC Home Page]     [Netfilter]     [Netfilter Development]     [Network Development]     [Bugtraq]     [GCC Help]     [Yosemite News]     [Linux Kernel]     [Fedora Users]
  Powered by Linux