netfilter-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Patrick McHardy <kaber@trash.net>
To: panther@balabit.hu
Cc: netdev@vger.kernel.org, netfilter-devel@vger.kernel.org
Subject: Re: [PATCH 2/2] Interface group match - netfilter part
Date: Wed, 17 Oct 2007 11:11:12 +0200	[thread overview]
Message-ID: <4715D1B0.30209@trash.net> (raw)
In-Reply-To: <4715D117.3080405@balabit.hu>

Laszlo Attila Toth wrote:
> Patrick McHardy írta:
>
>> The input interface is only valid in PREROUTING, INPUT and FORWARD.
>> Why don't you support output-interface matching?
>>
> 
> The new version supports output-interface, currently I'm rewriting 
> iptables part. But I'm not sure what to do with the forward chain 
> because both input and output interface are valid here. My idea is that 
> the ifgroup_match function checks ifgroup values of both input and 
> output interfaces if they are set. An example:
> 
> iptables -A FORWARD -m ifgroup --in-ifgroup 4 --out-ifgroup 5/0x0f -j 
> ACCEPT
> 
> The packet's input interface must be in group 4 and output interface 
> must be in group 5 but only lower 4 bits are checked. If one of these 
> assumptions fails the match fails.
> 
> Is it ok, or only one of them should be checked as in xt_policy: if 
> input side matches, other one is not checked?


xt_policy is a special case because the policy structure is so
large I decided the user should better use the match twice if
he really needs it (its also a quite uncommon use). For the
ifgroup match I think it should behave exactly as the -i and -o
matches: allow matching both in FORWARD, input device in
PREROUTING and INPUT and output device in OUTPUT and POSTROUTING.
-
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  reply	other threads:[~2007-10-17  9:11 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <ifgroup.20071015.1192520046.panther@balabit.hu>
2007-10-16  8:01 ` [PATCH 0/2] Interface groups Laszlo Attila Toth
2007-10-16  8:01 ` Laszlo Attila Toth
2007-10-16  8:50   ` Philip Craig
2007-10-16  9:47     ` Laszlo Attila Toth
     [not found] ` <1824b3d462b1d85aaf33941cf082c4e018d5bff7.1192460167.git.panther@balabit.hu>
2007-10-16  8:01   ` [PATCH 1/2] Interface group: core (netlink) part Laszlo Attila Toth
2007-10-16  8:34     ` Patrick McHardy
2007-10-16  8:01   ` Laszlo Attila Toth
     [not found]   ` <661f8f2fdb86cc70bdefd12403ecb0eaa7cfadd6.1192460168.git.panther@balabit.hu>
2007-10-16  8:01     ` [PATCH 2/2] Interface group match - netfilter part Laszlo Attila Toth
2007-10-16  8:30       ` Patrick McHardy
2007-10-16  9:46         ` Laszlo Attila Toth
2007-10-16 14:46         ` Jan Engelhardt
2007-10-17  9:08         ` Laszlo Attila Toth
2007-10-17  9:11           ` Patrick McHardy [this message]
2007-10-16  8:01     ` Laszlo Attila Toth
     [not found] ` <a6713ba13c49b7fa20073d8abf1862480c2799e0.1192457385.git.panther@balabit.hu>
2007-10-16  8:01   ` [IPROUTE2 PATCH] Interface group as new ip link option Laszlo Attila Toth
2007-10-16  8:01   ` Laszlo Attila Toth
2007-10-16  8:38     ` Patrick McHardy
2007-10-16  9:33       ` Laszlo Attila Toth
2007-10-16  9:03   ` Resend: " Laszlo Attila Toth
2007-10-16  9:11     ` Patrick McHardy
2007-10-16  9:03   ` Laszlo Attila Toth
2007-10-16 10:45   ` jamal
2007-10-16 11:05     ` Laszlo Attila Toth
2007-10-16 11:26       ` jamal
2007-10-16 11:47         ` Laszlo Attila Toth
2007-10-16 12:08           ` jamal

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=4715D1B0.30209@trash.net \
    --to=kaber@trash.net \
    --cc=netdev@vger.kernel.org \
    --cc=netfilter-devel@vger.kernel.org \
    --cc=panther@balabit.hu \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).