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

    ipv4: fix a potential use after free in ip_tunnel_core.c

to the 3.17-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:
     ipv4-fix-a-potential-use-after-free-in-ip_tunnel_core.c.patch
and it can be found in the queue-3.17 subdirectory.

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


>From foo@baz Fri Nov  7 11:36:50 PST 2014
From: Li RongQing <[email protected]>
Date: Fri, 17 Oct 2014 16:53:23 +0800
Subject: ipv4: fix a potential use after free in ip_tunnel_core.c

From: Li RongQing <[email protected]>

[ Upstream commit 1245dfc8cadb258386fcd27df38215a0eccb1f17 ]

pskb_may_pull() maybe change skb->data and make eth pointer oboslete,
so set eth after pskb_may_pull()

Fixes:3d7b46cd("ip_tunnel: push generic protocol handling to ip_tunnel module")
Cc: Pravin B Shelar <[email protected]>
Signed-off-by: Li RongQing <[email protected]>
Acked-by: Pravin B Shelar <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
---
 net/ipv4/ip_tunnel_core.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

--- a/net/ipv4/ip_tunnel_core.c
+++ b/net/ipv4/ip_tunnel_core.c
@@ -91,11 +91,12 @@ int iptunnel_pull_header(struct sk_buff
        skb_pull_rcsum(skb, hdr_len);
 
        if (inner_proto == htons(ETH_P_TEB)) {
-               struct ethhdr *eh = (struct ethhdr *)skb->data;
+               struct ethhdr *eh;
 
                if (unlikely(!pskb_may_pull(skb, ETH_HLEN)))
                        return -ENOMEM;
 
+               eh = (struct ethhdr *)skb->data;
                if (likely(ntohs(eh->h_proto) >= ETH_P_802_3_MIN))
                        skb->protocol = eh->h_proto;
                else


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

queue-3.17/vxlan-fix-a-use-after-free-in-vxlan_encap_bypass.patch
queue-3.17/vxlan-using-pskb_may_pull-as-early-as-possible.patch
queue-3.17/vxlan-fix-a-free-after-use.patch
queue-3.17/ipv4-fix-a-potential-use-after-free-in-ip_tunnel_core.c.patch
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to