Re: quick syntax query

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

 



On Mon, 7 Jun 2004 11:53:10 +0100
"Knight, Steve" <Steve.Knight@xxxxxxxxx> wrote:

> Hi there
> 
> Can one use syntax other than CIDR notation when defining things like
> networks?
> 
> i.e. it's common to see
> 
> LAN_RANGE="192.168.0.0/24"
> 
> in rule bases, but I would like to use
> 
> DODGY_RANGE="192.168.0.1-5"
> GOOD_RANGE="192.168.0.6-30"
> BAD_BAD_RANGE="192.168.31-40"
> 
> 
> a la `nmap` syntax.
> 
> Is this something netfilter can handle?
> 
> Thanks in advance
> 
> 
> Steve
> 

patch-o-matic iprange patch have this feature:

The base/iprange patch:
   Author: Jozsef Kadlecsik <kadlec@xxxxxxxxxxxxxxxxx>
   Status: Works

   This patch makes possible to match source/destination IP
   addresses against inclusive IP address ranges.

   Examples.

   iptables -A FORWARD -m iprange --src-range 192.168.1.5-192.168.1.124 -j ACCEPT
   iptables -A FORWARD -m iprange --dst-range 10.0.0.0-10.5.255.255.255 -j ACCEPT

-- 
Best regards,
Raileanu Grigore
mail: grisha at unixro dot net
phone: +40 742759147


[Index of Archives]     [Linux Netfilter Development]     [Linux Kernel Networking Development]     [Netem]     [Berkeley Packet Filter]     [Linux Kernel Development]     [Advanced Routing & Traffice Control]     [Bugtraq]

  Powered by Linux