Skip to contentSkip to conversation

Patch "ipv6: Don't unset flowi6_proto in ipxip6_tnl_xmit()" has been added to the 4.7-stable tree

PATCH [email protected] 1 participant 1 message Sep 22, 2016

Subsystems (3)
lore
Share & tools
lore

[email protected]

author maintainer Applied
#0 lore raw

This is a note to let you know that I've just added the patch titled

ipv6: Don't unset flowi6_proto in ipxip6_tnl_xmit()

to the 4.7-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
ipv6-don-t-unset-flowi6_proto-in-ipxip6_tnl_xmit.patch
and it can be found in the queue-4.7 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.

Quoted 1 line

From ab34380162cbc9b5172afdadf5136643c687bb73 Mon Sep 17 00:00:00 2001

From: Eli Cooper <[email protected]>
Date: Fri, 26 Aug 2016 23:52:29 +0800
Subject: ipv6: Don't unset flowi6_proto in ipxip6_tnl_xmit()

From: Eli Cooper <[email protected]>

commit ab34380162cbc9b5172afdadf5136643c687bb73 upstream.

Commit 8eb30be0352d0916 ("ipv6: Create ip6_tnl_xmit") unsets flowi6_proto in ip4ip6_tnl_xmit() and ip6ip6_tnl_xmit(). Since xfrm_selector_match() relies on this info, IPv6 packets sent by an ip6tunnel cannot be properly selected by their protocols after removing it. This patch puts flowi6_proto back.

Fixes 8eb30be0352d ("ipv6: Create ip6_tnl_xmit")
---
 net/ipv6/ip6_tunnel.c |    2 ++
 1 file changed, 2 insertions(+)
net/ipv6/ip6_tunnel.c +2 -0
@@ -1174,6 +1174,7 @@ ip4ip6_tnl_xmit(struct sk_buff *skb, str
 		encap_limit = t->parms.encap_limit;
 
 	memcpy(&fl6, &t->fl.u.ip6, sizeof(fl6));
+	fl6.flowi6_proto = IPPROTO_IPIP;
 
 	dsfield = ipv4_get_dsfield(iph);
 
@@ -1233,6 +1234,7 @@ ip6ip6_tnl_xmit(struct sk_buff *skb, str
 		encap_limit = t->parms.encap_limit;
 
 	memcpy(&fl6, &t->fl.u.ip6, sizeof(fl6));
+	fl6.flowi6_proto = IPPROTO_IPV6;
 
 	dsfield = ipv6_get_dsfield(ipv6h);
 	if (t->parms.flags & IP6_TNL_F_USE_ORIG_TCLASS)

Patches currently in stable-queue which might be from [email protected] are

queue-4.7/ipv6-don-t-unset-flowi6_proto-in-ipxip6_tnl_xmit.patch