netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [GIT PULL nf] IPVS Fixes for v3.18
@ 2014-10-28  1:05 Simon Horman
  2014-10-28  1:05 ` [PATCH nf] ipvs: Avoid null-pointer deref in debug code Simon Horman
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Simon Horman @ 2014-10-28  1:05 UTC (permalink / raw)
  To: Pablo Neira Ayuso
  Cc: lvs-devel, netdev, netfilter-devel, Wensong Zhang,
	Julian Anastasov, Simon Horman

Hi Pablo,

please consider this fix for v3.18.

It fixes a null-pointer dereference that may occur when logging
errors.

This problem was introduced by 4a4739d56b0 ("ipvs: Pull out
crosses_local_route_boundary logic") in v3.17-rc5. As such I would
also like it considered for 3.17-stable.


The following changes since commit 7965ee93719921ea5978f331da653dfa2d7b99f5:

  netfilter: nft_compat: fix wrong target lookup in nft_target_select_ops() (2014-10-27 22:17:46 +0100)

are available in the git repository at:

  https://git.kernel.org/pub/scm/linux/kernel/git/horms/ipvs.git tags/ipvs-fixes-for-v3.18

for you to fetch changes up to 3d53666b40007b55204ee8890618da79a20c9940:

  ipvs: Avoid null-pointer deref in debug code (2014-10-28 09:48:31 +0900)

----------------------------------------------------------------
Alex Gartrell (1):
      ipvs: Avoid null-pointer deref in debug code

 net/netfilter/ipvs/ip_vs_xmit.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH nf] ipvs: Avoid null-pointer deref in debug code
  2014-10-28  1:05 [GIT PULL nf] IPVS Fixes for v3.18 Simon Horman
@ 2014-10-28  1:05 ` Simon Horman
  2014-10-31 11:47 ` [GIT PULL nf] IPVS Fixes for v3.18 Pablo Neira Ayuso
  2014-11-04 17:57 ` Pablo Neira Ayuso
  2 siblings, 0 replies; 5+ messages in thread
From: Simon Horman @ 2014-10-28  1:05 UTC (permalink / raw)
  To: Pablo Neira Ayuso
  Cc: lvs-devel, netdev, netfilter-devel, Wensong Zhang,
	Julian Anastasov, Alex Gartrell, Simon Horman

From: Alex Gartrell <agartrell@fb.com>

Use daddr instead of reaching into dest.

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Alex Gartrell <agartrell@fb.com>
Signed-off-by: Simon Horman <horms@verge.net.au>
---
 net/netfilter/ipvs/ip_vs_xmit.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/net/netfilter/ipvs/ip_vs_xmit.c b/net/netfilter/ipvs/ip_vs_xmit.c
index 91f17c1..437a366 100644
--- a/net/netfilter/ipvs/ip_vs_xmit.c
+++ b/net/netfilter/ipvs/ip_vs_xmit.c
@@ -316,7 +316,7 @@ __ip_vs_get_out_rt(int skb_af, struct sk_buff *skb, struct ip_vs_dest *dest,
 	if (unlikely(crosses_local_route_boundary(skb_af, skb, rt_mode,
 						  local))) {
 		IP_VS_DBG_RL("We are crossing local and non-local addresses"
-			     " daddr=%pI4\n", &dest->addr.ip);
+			     " daddr=%pI4\n", &daddr);
 		goto err_put;
 	}
 
@@ -458,7 +458,7 @@ __ip_vs_get_out_rt_v6(int skb_af, struct sk_buff *skb, struct ip_vs_dest *dest,
 	if (unlikely(crosses_local_route_boundary(skb_af, skb, rt_mode,
 						  local))) {
 		IP_VS_DBG_RL("We are crossing local and non-local addresses"
-			     " daddr=%pI6\n", &dest->addr.in6);
+			     " daddr=%pI6\n", daddr);
 		goto err_put;
 	}
 
-- 
2.1.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [GIT PULL nf] IPVS Fixes for v3.18
  2014-10-28  1:05 [GIT PULL nf] IPVS Fixes for v3.18 Simon Horman
  2014-10-28  1:05 ` [PATCH nf] ipvs: Avoid null-pointer deref in debug code Simon Horman
@ 2014-10-31 11:47 ` Pablo Neira Ayuso
  2014-11-04 17:57 ` Pablo Neira Ayuso
  2 siblings, 0 replies; 5+ messages in thread
From: Pablo Neira Ayuso @ 2014-10-31 11:47 UTC (permalink / raw)
  To: Simon Horman
  Cc: lvs-devel, netdev, netfilter-devel, Wensong Zhang, Julian Anastasov

On Tue, Oct 28, 2014 at 10:05:33AM +0900, Simon Horman wrote:
> Hi Pablo,
> 
> please consider this fix for v3.18.
> 
> It fixes a null-pointer dereference that may occur when logging
> errors.
> 
> This problem was introduced by 4a4739d56b0 ("ipvs: Pull out
> crosses_local_route_boundary logic") in v3.17-rc5. As such I would
> also like it considered for 3.17-stable.
> 
> 
> The following changes since commit 7965ee93719921ea5978f331da653dfa2d7b99f5:
> 
>   netfilter: nft_compat: fix wrong target lookup in nft_target_select_ops() (2014-10-27 22:17:46 +0100)
> 
> are available in the git repository at:
> 
>   https://git.kernel.org/pub/scm/linux/kernel/git/horms/ipvs.git tags/ipvs-fixes-for-v3.18

Pulled, thanks Simon.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [GIT PULL nf] IPVS Fixes for v3.18
  2014-10-28  1:05 [GIT PULL nf] IPVS Fixes for v3.18 Simon Horman
  2014-10-28  1:05 ` [PATCH nf] ipvs: Avoid null-pointer deref in debug code Simon Horman
  2014-10-31 11:47 ` [GIT PULL nf] IPVS Fixes for v3.18 Pablo Neira Ayuso
@ 2014-11-04 17:57 ` Pablo Neira Ayuso
  2014-11-12  2:24   ` Simon Horman
  2 siblings, 1 reply; 5+ messages in thread
From: Pablo Neira Ayuso @ 2014-11-04 17:57 UTC (permalink / raw)
  To: Simon Horman
  Cc: lvs-devel, netdev, netfilter-devel, Wensong Zhang, Julian Anastasov

Hi Simon,

On Tue, Oct 28, 2014 at 10:05:33AM +0900, Simon Horman wrote:
> Hi Pablo,
> 
> please consider this fix for v3.18.
> 
> It fixes a null-pointer dereference that may occur when logging
> errors.
> 
> This problem was introduced by 4a4739d56b0 ("ipvs: Pull out
> crosses_local_route_boundary logic") in v3.17-rc5. As such I would
> also like it considered for 3.17-stable.

Regarding your request to pass this to 3.17-stable. According to git
am and my scripts:

3d53666 ipvs: Avoid null-pointer deref in debug code

doesn't apply cleanly 3.17.x. Please re-check and send me a backport if
you want to see this in 3.17.x. Let me know, sorry.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [GIT PULL nf] IPVS Fixes for v3.18
  2014-11-04 17:57 ` Pablo Neira Ayuso
@ 2014-11-12  2:24   ` Simon Horman
  0 siblings, 0 replies; 5+ messages in thread
From: Simon Horman @ 2014-11-12  2:24 UTC (permalink / raw)
  To: Pablo Neira Ayuso
  Cc: lvs-devel, netdev, netfilter-devel, Wensong Zhang, Julian Anastasov

On Tue, Nov 04, 2014 at 06:57:17PM +0100, Pablo Neira Ayuso wrote:
> Hi Simon,
> 
> On Tue, Oct 28, 2014 at 10:05:33AM +0900, Simon Horman wrote:
> > Hi Pablo,
> > 
> > please consider this fix for v3.18.
> > 
> > It fixes a null-pointer dereference that may occur when logging
> > errors.
> > 
> > This problem was introduced by 4a4739d56b0 ("ipvs: Pull out
> > crosses_local_route_boundary logic") in v3.17-rc5. As such I would
> > also like it considered for 3.17-stable.
> 
> Regarding your request to pass this to 3.17-stable. According to git
> am and my scripts:
> 
> 3d53666 ipvs: Avoid null-pointer deref in debug code
> 
> doesn't apply cleanly 3.17.x. Please re-check and send me a backport if
> you want to see this in 3.17.x. Let me know, sorry.

Sorry for creating some confusion here and sorry for not
cleaning it up earlier.

On further inspection I believe that 4a4739d56b0 was included
in v3.18-rc1 rather than v3.17. So this fix is not relevant to
v3.17 after all.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2014-11-12  2:24 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-10-28  1:05 [GIT PULL nf] IPVS Fixes for v3.18 Simon Horman
2014-10-28  1:05 ` [PATCH nf] ipvs: Avoid null-pointer deref in debug code Simon Horman
2014-10-31 11:47 ` [GIT PULL nf] IPVS Fixes for v3.18 Pablo Neira Ayuso
2014-11-04 17:57 ` Pablo Neira Ayuso
2014-11-12  2:24   ` Simon Horman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).