[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1427974448.2093675.248500389.6D8AFBB6@webmail.messagingengine.com>
Date: Thu, 02 Apr 2015 13:34:08 +0200
From: Hannes Frederic Sowa <hannes@...essinduktion.org>
To: Eric Dumazet <eric.dumazet@...il.com>
Cc: Cong Wang <cwang@...pensource.com>,
netdev <netdev@...r.kernel.org>, Jiri Pirko <jiri@...nulli.us>
Subject: Re: [PATCH net-next] ipv6: protect skb->sk accesses from recursive
dereference inside the stack
On Thu, Apr 2, 2015, at 03:53, Eric Dumazet wrote:
> On Thu, 2015-04-02 at 02:56 +0200, Hannes Frederic Sowa wrote:
> >
> > On Thu, Apr 2, 2015, at 02:48, Eric Dumazet wrote:
> > > On Thu, 2015-04-02 at 02:35 +0200, Hannes Frederic Sowa wrote:
> > > > On Thu, Apr 2, 2015, at 02:27, Eric Dumazet wrote:
> > > > > orphaning skb just because they traverse a tunnel would be quite
> > > > > horrible.
> > > >
> > > > Agreed, but we have some bits in the skb->sk pointer left for signaling
> > > > we are only keeping it around for destructor and upper layer
> > > > notifications. Destructors should be the only ones having to deal with
> > > > skb->sk and they can mask the bit. That would touch a lot of NULL
> > > > checks, though.
> > >
> > > Have you checked net/sched/sch_fq.c per chance ?
> > >
> > > skb->sk is not an opaque value.
> >
> > Do you think that skb->sk access through skb->__sk & ~0x1ULL would slow
> > down the code too much?
>
> I was only replying to your claim "Destructors should be the only ones
> having to deal with skb->sk", which looked wrong to me.
You are correct, there might be even more places I need to use this.
> Adding bit masking would slow down the code, but we did this already for
> skb->dst
Exactly.
My plan is that I actually would propose this patch for -net and stable
as it fixes the problem that currently we oops when running dhclient on
a vxlan interface. As soon as net gets merged into net-next I I would
propose this change if it works out smoothly and looks maintainable.
Thanks,
Hannes
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists