All of lore.kernel.org
 help / color / mirror / Atom feed
From: Aidas Kasparas <a.kasparas@gmc.lt>
To: "İbrahim Ercan" <ibrahim.ercan@engineer.com>
Cc: netfilter@vger.kernel.org, netfilter-devel@vger.kernel.org
Subject: Re: How to add wildcard netmask to ipset?
Date: Fri, 21 Sep 2012 11:27:17 +0300	[thread overview]
Message-ID: <505C24E5.1090307@gmc.lt> (raw)
In-Reply-To: <CAK6Qs9=Q4tpOjB6JfcSS3fbnyQdAv_Oqcz4zzqqZx5e10PvrAg@mail.gmail.com>

On 2012.09.21 10:35, İbrahim Ercan wrote:
> Hello,
>
> We are using ipset and we want to add wildcard netmasks to ipset. We
> are using hash:net to store our ips. Ipset does not accept adding
> netmasks so when adding a network like 192.168.1.0/255.255.255.0 we
> convert it to 192.168.1.0/24 CIDR notation and add. But a network like
> 192.168.2.0/255.0.255.0 cannot be converted to CIDR nor can be added
> to ipset. What can we do?
>
You can allways add 256 entries into your ipset: 192.i.2.0/24 for all i
in 0..255 .
On the other hand, what do you use masks like these for?

-- 
Aidas Kasparas
IT administrator
GM Consult Group, UAB

+370 686 08473
http://www.gmc.lt


WARNING: multiple messages have this Message-ID (diff)
From: Aidas Kasparas <a.kasparas@gmc.lt>
To: "İbrahim Ercan" <ibrahim.ercan@engineer.com>
Cc: netfilter@vger.kernel.org, netfilter-devel@vger.kernel.org
Subject: Re: How to add wildcard netmask to ipset?
Date: Fri, 21 Sep 2012 11:27:17 +0300	[thread overview]
Message-ID: <505C24E5.1090307@gmc.lt> (raw)
In-Reply-To: <CAK6Qs9=Q4tpOjB6JfcSS3fbnyQdAv_Oqcz4zzqqZx5e10PvrAg@mail.gmail.com>

On 2012.09.21 10:35, İbrahim Ercan wrote:
> Hello,
>
> We are using ipset and we want to add wildcard netmasks to ipset. We
> are using hash:net to store our ips. Ipset does not accept adding
> netmasks so when adding a network like 192.168.1.0/255.255.255.0 we
> convert it to 192.168.1.0/24 CIDR notation and add. But a network like
> 192.168.2.0/255.0.255.0 cannot be converted to CIDR nor can be added
> to ipset. What can we do?
>
You can allways add 256 entries into your ipset: 192.i.2.0/24 for all i
in 0..255 .
On the other hand, what do you use masks like these for?

-- 
Aidas Kasparas
IT administrator
GM Consult Group, UAB

+370 686 08473
http://www.gmc.lt


  parent reply	other threads:[~2012-09-21  8:27 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-09-21  7:35 How to add wildcard netmask to ipset? İbrahim Ercan
2012-09-21  7:35 ` İbrahim Ercan
2012-09-21  8:10 ` Jozsef Kadlecsik
2012-09-21  8:27 ` Aidas Kasparas [this message]
2012-09-21  8:27   ` Aidas Kasparas

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=505C24E5.1090307@gmc.lt \
    --to=a.kasparas@gmc.lt \
    --cc=ibrahim.ercan@engineer.com \
    --cc=netfilter-devel@vger.kernel.org \
    --cc=netfilter@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.