From: Pablo Neira Ayuso <pablo@netfilter.org>
Hi David,
The following patches provide two fixes:
* One to get the timeout special parameter for the SET target back working
(this was introduced while trying to fix another bug in 3.4) from
Jozsef Kadlecsik.
* One crash fix if containers and nf_conntrack are used reported by Hans
Schillstrom by myself.
You can pull these fixes from:
git://1984.lsi.us.es/nf master
Thanks.
little notice: I forgot to add my Signed-off-by while manually applying
Jozsef's patch, sorry. It was a bit too late to fix, I already pushed out
to my master branch.
Jozsef Kadlecsik (1):
netfilter: ipset: timeout fixing bug broke SET target special timeout value
Pablo Neira Ayuso (1):
netfilter: nf_ct_ecache: fix crash with multiple containers, one shutting down
include/net/netfilter/nf_conntrack_ecache.h | 2 +-
net/netfilter/xt_set.c | 4 +++-
2 files changed, 4 insertions(+), 2 deletions(-)
--
1.7.10
From: Pablo Neira Ayuso <pablo@netfilter.org>
Hans reports that he's still hitting:
BUG: unable to handle kernel NULL pointer dereference at 000000000000027c
IP: [<ffffffff813615db>] netlink_has_listeners+0xb/0x60
PGD 0
Oops: 0000 [#3] PREEMPT SMP
CPU 0
It happens when adding a number of containers with do:
nfct_query(h, NFCT_Q_CREATE, ct);
and most likely one namespace shuts down.
this problem was supposed to be fixed by:
70e9942 netfilter: nf_conntrack: make event callback registration per-netns
Still, it was missing one rcu_access_pointer to check if the callback
is set or not.
Reported-by: Hans Schillstrom <redacted>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
---
include/net/netfilter/nf_conntrack_ecache.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
+ if (add_opt.timeout != IPSET_NO_TIMEOUT
+ && add_opt.timeout > UINT_MAX/MSEC_PER_SEC)
We do not write conditionals like this, with operators beginning
a continued line. Instead, write this as:
if (a &&
b)
Oops, indeed, sorry. New patch attached.
I've also rebased my tree to include this change. Should I send a new
pull request?
Let me know what you prefer.