From: Patrick McHardy <kaber@trash.net>
To: davem@davemloft.net
Cc: netdev@vger.kernel.org, Patrick McHardy <kaber@trash.net>,
netfilter-devel@vger.kernel.org
Subject: netfilter 04/05: ctnetlink: fix echo if not subscribed to any multicast group
Date: Mon, 9 Feb 2009 17:39:32 +0100 (MET) [thread overview]
Message-ID: <20090209163931.13918.35499.sendpatchset@x2.localnet> (raw)
In-Reply-To: <20090209163926.13918.96177.sendpatchset@x2.localnet>
commit 8f0613c03d2bb8ab39f6e21ff555026dce503179
Author: Pablo Neira Ayuso <pablo@netfilter.org>
Date: Mon Feb 9 14:26:52 2009 +0100
netfilter: ctnetlink: fix echo if not subscribed to any multicast group
This patch fixes echoing if the socket that has sent the request to
create/update/delete an entry is not subscribed to any multicast
group. With the current code, ctnetlink would not send the echo
message via unicast as nfnetlink_send() would be skip.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Patrick McHardy <kaber@trash.net>
diff --git a/net/netfilter/nf_conntrack_netlink.c b/net/netfilter/nf_conntrack_netlink.c
index 9051bb4..cb78aa0 100644
--- a/net/netfilter/nf_conntrack_netlink.c
+++ b/net/netfilter/nf_conntrack_netlink.c
@@ -434,7 +434,7 @@ static int ctnetlink_conntrack_event(struct notifier_block *this,
} else
return NOTIFY_DONE;
- if (!nfnetlink_has_listeners(group))
+ if (!item->report && !nfnetlink_has_listeners(group))
return NOTIFY_DONE;
skb = alloc_skb(NLMSG_GOODSIZE, GFP_ATOMIC);
@@ -1502,7 +1502,8 @@ static int ctnetlink_expect_event(struct notifier_block *this,
} else
return NOTIFY_DONE;
- if (!nfnetlink_has_listeners(NFNLGRP_CONNTRACK_EXP_NEW))
+ if (!item->report &&
+ !nfnetlink_has_listeners(NFNLGRP_CONNTRACK_EXP_NEW))
return NOTIFY_DONE;
skb = alloc_skb(NLMSG_GOODSIZE, GFP_ATOMIC);
next prev parent reply other threads:[~2009-02-09 16:39 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-09 16:39 netfilter 00/05: netfilter fixes Patrick McHardy
2009-02-09 16:39 ` netfilter 01/05: fix tuple inversion for Node information request Patrick McHardy
2009-02-09 16:39 ` netfilter 02/05: nf_conntrack_ipv6: don't track ICMPv6 negotiation message Patrick McHardy
2009-02-09 16:39 ` netfilter 03/05: ctnetlink: allow changing NAT sequence adjustment in creation Patrick McHardy
2009-02-09 16:39 ` Patrick McHardy [this message]
2009-02-09 16:39 ` netfilter 05/05: xt_sctp: sctp chunk mapping doesn't work Patrick McHardy
2009-02-09 22:32 ` netfilter 00/05: netfilter fixes David Miller
2009-02-09 22:47 ` Patrick McHardy
2009-02-09 23:18 ` David Miller
2009-02-09 23:36 ` Patrick McHardy
2009-02-10 0:28 ` David Miller
2009-02-10 0:31 ` Patrick McHardy
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=20090209163931.13918.35499.sendpatchset@x2.localnet \
--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.