[1/5] netfilter: reset nf_trace in nf_reset

Message ID 1365080169-6880-2-git-send-email-pablo@netfilter.org
State Accepted
Headers show

Commit Message

Pablo Neira Ayuso April 4, 2013, 12:56 p.m.
From: Gao feng <gaofeng@cn.fujitsu.com>

We forgot to clear the nf_trace of sk_buff in nf_reset,
When we use veth device, this nf_trace information will
be leaked from one net namespace to another net namespace.

Signed-off-by: Gao feng <gaofeng@cn.fujitsu.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
 include/linux/skbuff.h |    3 +++
 1 file changed, 3 insertions(+)


diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h
index 441f5bf..72b3967 100644
--- a/include/linux/skbuff.h
+++ b/include/linux/skbuff.h
@@ -2641,6 +2641,9 @@  static inline void nf_reset(struct sk_buff *skb)
 	skb->nf_bridge = NULL;
+	skb->nf_trace = 0;
 /* Note: This doesn't put any conntrack and bridge info in dst. */