netfilter-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jan Engelhardt <jengelh@inai.de>
To: Pablo Neira Ayuso <pablo@netfilter.org>
Cc: netfilter-devel@vger.kernel.org
Subject: Re: [PATCH 2/2] extensions: restore matching any SPI id by default
Date: Wed, 15 Jul 2015 19:46:05 +0200 (CEST)	[thread overview]
Message-ID: <alpine.LSU.2.20.1507151937160.528@nerf40.vanv.qr> (raw)
In-Reply-To: <20150715173035.GA5675@salvia>


On Wednesday 2015-07-15 19:30, Pablo Neira Ayuso wrote:
>> The printing via iptables -S was not the problem.
>> The patch is about that no AH/ESP packets were matched when using
>> just "-m esp" because of the implied --espspi 0:0.
>
>Without your patch:
>
>iptables -A INPUT -p ah
>
># iptables-save
>...
>-A INPUT -p ah -m ah --ahspi 0

That should not happen. -p implies -m only magically if one of the
options is used, i.e. "-p ah" alone should never imply "-m ah".

# XTABLES_LIBDIR=$PWD/extensions iptables/xtables-multi main4 -A z -p ah
# XTABLES_LIBDIR=$PWD/extensions iptables/xtables-multi main4 -S z
-N z
-A z -p ah


Second, without my patch:

# XTABLES_LIBDIR=$PWD/extensions iptables/xtables-multi main4 -A z -p ah -m ah
# XTABLES_LIBDIR=$PWD/extensions iptables/xtables-multi main4 -S z
-A z -p ah -m ah --ahspi 0

And that was the bug: --ahspi 0 is undesired behavior for when --ahspi
is never specified.


Printing it differently is a separate concern one can think about,
but with a separate patch. :-)

  reply	other threads:[~2015-07-15 17:46 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-15 12:53 iptables: AH/ESP init fix, and a build fix Jan Engelhardt
2015-07-15 12:53 ` [PATCH 1/2] build: resolve build error involving libnftnl Jan Engelhardt
2015-07-15 16:28   ` Pablo Neira Ayuso
2015-07-15 12:53 ` [PATCH 2/2] extensions: restore matching any SPI id by default Jan Engelhardt
2015-07-15 16:24   ` Pablo Neira Ayuso
2015-07-15 16:41     ` Jan Engelhardt
2015-07-15 16:55       ` Pablo Neira Ayuso
2015-07-15 17:10         ` Jan Engelhardt
2015-07-15 17:30           ` Pablo Neira Ayuso
2015-07-15 17:46             ` Jan Engelhardt [this message]
2015-08-07 11:07               ` Pablo Neira Ayuso
2015-08-07 11:38                 ` Jan Engelhardt
2015-08-10 12:04                   ` Pablo Neira Ayuso
2015-08-10 12:15                     ` Jan Engelhardt

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=alpine.LSU.2.20.1507151937160.528@nerf40.vanv.qr \
    --to=jengelh@inai.de \
    --cc=netfilter-devel@vger.kernel.org \
    --cc=pablo@netfilter.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 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).