[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20201113170153.6ce31890@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com>
Date: Fri, 13 Nov 2020 17:01:53 -0800
From: Jakub Kicinski <kuba@...nel.org>
To: Daniel Borkmann <daniel@...earbox.net>
Cc: Yi-Hung Wei <yihung.wei@...il.com>,
Pablo Neira Ayuso <pablo@...filter.org>, davem@...emloft.net,
kuznet@....inr.ac.ru, yoshfuji@...ux-ipv6.org,
pieter.jansenvanvuuren@...ronome.com, netdev@...r.kernel.org,
alexei.starovoitov@...il.com
Subject: Re: [PATCH] ip_tunnels: Set tunnel option flag when tunnel metadata
is present
On Sat, 14 Nov 2020 01:46:04 +0100 Daniel Borkmann wrote:
> On 11/14/20 1:13 AM, Jakub Kicinski wrote:
> > On Tue, 10 Nov 2020 16:16:40 -0800 Yi-Hung Wei wrote:
> >> Currently, we may set the tunnel option flag when the size of metadata
> >> is zero. For example, we set TUNNEL_GENEVE_OPT in the receive function
> >> no matter the geneve option is present or not. As this may result in
> >> issues on the tunnel flags consumers, this patch fixes the issue.
> >>
> >> Related discussion:
> >> * https://lore.kernel.org/netdev/1604448694-19351-1-git-send-email-yihung.wei@gmail.com/T/#u
> >>
> >> Fixes: 256c87c17c53 ("net: check tunnel option type in tunnel flags")
> >> Signed-off-by: Yi-Hung Wei <yihung.wei@...il.com>
> >
> > Seems fine to me, however BPF (and maybe Netfilter?) can set options
> > passed by user without checking if they are 0 length.
> >
> > Daniel, Pablo, are you okay with this change or should we limit it to
> > just fixing the GENEVE oddness?
>
> Verifier will guarantee that buffer passed into helper is > 0, so seems
> okay from BPF side.
Okay then, the potential change for netfilter is limited to GENEVE
so doesn't move the needle.
Applied, thanks!
Powered by blists - more mailing lists