VXLAN: fix potential NULL dereference in arp_reduce()
Subsystems (2)
PATCH 1/1 VXLAN: fix potential NULL dereference in arp_reduce()
This patch fixes a NULL pointer dereference in the event of an
skb allocation failure in arp_reduce().
drivers/net/vxlan.c +3 -0
@@ -1315,6 +1315,9 @@ static int arp_reduce(struct net_device *dev, struct sk_buff *skb)neigh_release (n); +if (reply ==NULL ) + goto out; +skb_reset_mac_header (reply);__skb_pull (reply,skb_network_offset (reply)); reply->ip_summed =CHECKSUM_UNNECESSARY ;
Quoted 11 lines · David L Stevens
This patch fixes a NULL pointer dereference in the event of an
skb allocation failure inarp_reduce().Signed-off-by David L Stevens <[email protected]>drivers/net/vxlan.c +0
-0
drivers/net/vxlan.c static int arp_reduce(struct net_device *dev, struct sk_buff *skb) · line 1320
Quoted 6 lines
drivers/net/vxlan.c +3
-0@@ -1315,6 +1315,9 @@ static int arp_reduce(struct net_device *dev, struct sk_buff *skb)neigh_release (n); +if (reply ==NULL ) + goto out; +
Nit: move it right after arp_create(). Otherwise:
Quoted 7 lines
From: Cong Wang
Nit: move it right after
arp_create(). Otherwise:
That would exit without releasing the neighbor reference.
+-DLS
Quoted 10 lines · David Stevens
Quoted 7 lines
From: Cong Wang
Nit: move it right after
arp_create(). Otherwise:That would exit without releasing the neighbor reference.
Ah, then it's ok.
From: David L Stevens <[email protected]>
Date: Tue, 18 Mar 2014 12:32:29 -0400
Quoted 4 lines
This patch fixes a NULL pointer dereference in the event of an
skb allocation failure inarp_reduce().Signed-off-by David L Stevens <[email protected]>
Applied, thanks.
Please refer to subsystems in your Subject lines using lowercase letters, as is the convention these days. I've fixed it up this time.
Thanks.