From: Patrick McHardy <kaber@trash.net>
To: "David S. Miller" <davem@davemloft.net>
Cc: Netfilter Development Mailinglist
<netfilter-devel@vger.kernel.org>,
Linux Netdev List <netdev@vger.kernel.org>
Subject: netfilter: ctnetlink: fix missing CTA_NAT_SEQ_UNSPEC
Date: Mon, 15 Dec 2008 16:42:04 +0100 [thread overview]
Message-ID: <49467ACC.8080107@trash.net> (raw)
[-- Attachment #1: Type: text/plain, Size: 189 bytes --]
Hi Dave,
following is a single netfilter patch for 2.6.28, fixing incorrect
ctnetlink NAT attribute definitions that break common userspace
attribute parsing code.
Please apply, thanks.
[-- Attachment #2: 01.diff --]
[-- Type: text/x-patch, Size: 1400 bytes --]
commit 492092c2b1fc3d74b24d8744ba419dbcefadaf5e
Author: Pablo Neira Ayuso <pablo@netfilter.org>
Date: Thu Dec 11 14:00:21 2008 +0100
netfilter: ctnetlink: fix missing CTA_NAT_SEQ_UNSPEC
This patch fixes an inconsistency in nfnetlink_conntrack.h that
I introduced myself. The problem is that CTA_NAT_SEQ_UNSPEC is
missing from enum ctattr_natseq. This inconsistency may lead to
problems in the message parsing in userspace (if the message
contains the CTA_NAT_SEQ_* attributes, of course).
This patch breaks backward compatibility, however, the only known
client of this code is libnetfilter_conntrack which indeed crashes
because it assumes the existence of CTA_NAT_SEQ_UNSPEC to do
the parsing.
The CTA_NAT_SEQ_* attributes were introduced in 2.6.25.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Patrick McHardy <kaber@trash.net>
diff --git a/include/linux/netfilter/nfnetlink_conntrack.h b/include/linux/netfilter/nfnetlink_conntrack.h
index c19595c..29fe9ea 100644
--- a/include/linux/netfilter/nfnetlink_conntrack.h
+++ b/include/linux/netfilter/nfnetlink_conntrack.h
@@ -141,6 +141,7 @@ enum ctattr_protonat {
#define CTA_PROTONAT_MAX (__CTA_PROTONAT_MAX - 1)
enum ctattr_natseq {
+ CTA_NAT_SEQ_UNSPEC,
CTA_NAT_SEQ_CORRECTION_POS,
CTA_NAT_SEQ_OFFSET_BEFORE,
CTA_NAT_SEQ_OFFSET_AFTER,
next reply other threads:[~2008-12-15 15:42 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-15 15:42 Patrick McHardy [this message]
2008-12-16 9:20 ` netfilter: ctnetlink: fix missing CTA_NAT_SEQ_UNSPEC David Miller
2008-12-17 20:22 ` [PATCH 1/1 ] Conntrack extensions : Interrupt timeout Piotr Duszynski
2008-12-18 2:36 ` James King
[not found] ` <494D4A11.5080304@gmail.com>
2008-12-22 9:07 ` James King
2008-12-22 10:46 ` Piotr Duszynski
2008-12-22 19:22 ` Piotr Duszynski
2008-12-24 19:10 ` Jan Engelhardt
2008-12-22 10:36 ` Piotr Duszynski
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=49467ACC.8080107@trash.net \
--to=kaber@trash.net \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=netfilter-devel@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.