]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
net: dev_forward_skb should call nf_reset
authorBen Greear <greearb@candelatech.com>
Thu, 22 Jul 2010 09:54:47 +0000 (09:54 +0000)
committerGreg Kroah-Hartman <gregkh@suse.de>
Thu, 26 Aug 2010 23:43:45 +0000 (16:43 -0700)
[ Upstream commit c736eefadb71a01a5e61e0de700f28f6952b4444 ]

With conn-track zones and probably with different network
namespaces, the netfilter logic needs to be re-calculated
on packet receive.  If the netfilter logic is not reset,
it will not be recalculated properly.  This patch adds
the nf_reset logic to dev_forward_skb.

Signed-off-by: Ben Greear <greearb@candelatech.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
net/core/dev.c

index ece33fd435eee4073892663167954d198b43ab2d..e463f77d42d23ef4b09ac35a3941adf8c07d4e67 100644 (file)
@@ -1464,6 +1464,7 @@ static inline void net_timestamp(struct sk_buff *skb)
 int dev_forward_skb(struct net_device *dev, struct sk_buff *skb)
 {
        skb_orphan(skb);
+       nf_reset(skb);
 
        if (!(dev->flags & IFF_UP) ||
            (skb->len > (dev->mtu + dev->hard_header_len))) {