From: Eric Dumazet <eric.dumazet@gmail.com>
To: Hannes Frederic Sowa <hannes@stressinduktion.org>
Cc: netdev@vger.kernel.org
Subject: Re: [PATCH] ipv6: check if dereference of ipv6 header is safe
Date: Fri, 18 Jan 2013 11:12:26 -0800 [thread overview]
Message-ID: <1358536346.11051.580.camel@edumazet-glaptop> (raw)
In-Reply-To: <20130118030819.GA20324@order.stressinduktion.org>
On Fri, 2013-01-18 at 04:08 +0100, Hannes Frederic Sowa wrote:
> Please correct me if I am wrong:
>
> The callstack as captured in ipip6_rcv:
> ipip6_rcv+0xcd/0x680 [sit]
> tunnel64_rcv+0x4a/0x174 [tunnel4]
> ip_local_deliver+0x152/0x470
> ? ip_local_deliver+0x75/0x470
> ip_rcv+0x36d/0x650
>
> ip_rcv does first check if the ipv4 header is complete (inclusive options) and
> passes control to ip_local_deliver which calls __skb_pull(skb,
> ip_hdrlen(skb)). So ->data is forwarded behind the ipv4 header. The next
> pskb_may_pull check would check if the necessary amount of data behind the
> ipv4 header is available hence I assume the check in tunnel64_rcv is enough:
Oh, yes, thats fine.
prev parent reply other threads:[~2013-01-18 19:12 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-17 3:56 [PATCH] ipv6: check if dereference of ipv6 header is safe Hannes Frederic Sowa
2013-01-18 2:06 ` Hannes Frederic Sowa
2013-01-18 2:08 ` David Miller
2013-01-18 2:21 ` Eric Dumazet
2013-01-18 3:08 ` Hannes Frederic Sowa
2013-01-18 19:12 ` Eric Dumazet [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1358536346.11051.580.camel@edumazet-glaptop \
--to=eric.dumazet@gmail.com \
--cc=hannes@stressinduktion.org \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox