Netdev List
 help / color / mirror / Atom feed
From: David Ahern <dsahern@gmail.com>
To: Ido Schimmel <idosch@mellanox.com>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>
Cc: "davem@davemloft.net" <davem@davemloft.net>,
	Vlad Yasevich <vyasevich@gmail.com>
Subject: Re: [PATCH net v2] rtnetlink: Disallow FDB configuration for non-Ethernet device
Date: Mon, 29 Oct 2018 14:39:24 -0600	[thread overview]
Message-ID: <425b5b88-c68f-b9a6-dc3e-2e7d5462b820@gmail.com> (raw)
In-Reply-To: <20181029203622.20608-1-idosch@mellanox.com>

On 10/29/18 2:36 PM, Ido Schimmel wrote:
> When an FDB entry is configured, the address is validated to have the
> length of an Ethernet address, but the device for which the address is
> configured can be of any type.
> 
> The above can result in the use of uninitialized memory when the address
> is later compared against existing addresses since 'dev->addr_len' is
> used and it may be greater than ETH_ALEN, as with ip6tnl devices.
> 
> Fix this by making sure that FDB entries are only configured for
> Ethernet devices.

...

> 
> Fixes: 090096bf3db1 ("net: generic fdb support for drivers without ndo_fdb_<op>")
> Signed-off-by: Ido Schimmel <idosch@mellanox.com>
> Reported-and-tested-by: syzbot+3a288d5f5530b901310e@syzkaller.appspotmail.com
> Reported-and-tested-by: syzbot+d53ab4e92a1db04110ff@syzkaller.appspotmail.com
> Cc: Vlad Yasevich <vyasevich@gmail.com>
> Cc: David Ahern <dsahern@gmail.com>
> ---
>  net/core/rtnetlink.c | 10 ++++++++++
>  1 file changed, 10 insertions(+)

Reviewed-by: David Ahern <dsahern@gmail.com>

  reply	other threads:[~2018-10-30  5:29 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-29 20:36 [PATCH net v2] rtnetlink: Disallow FDB configuration for non-Ethernet device Ido Schimmel
2018-10-29 20:39 ` David Ahern [this message]
2018-10-30  3:53 ` David Miller

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=425b5b88-c68f-b9a6-dc3e-2e7d5462b820@gmail.com \
    --to=dsahern@gmail.com \
    --cc=davem@davemloft.net \
    --cc=idosch@mellanox.com \
    --cc=netdev@vger.kernel.org \
    --cc=vyasevich@gmail.com \
    /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