On Thu, 16 Jun 2016 16:19:38 +0200 Phil Sutter <p...@nwl.cc> wrote: > Due to minimal checking in kernel space, MAC address setting was > problematic in multiple ways: > > - Setting an overly long MAC address was accepted and the extra parts > simply ignored. > > - Setting an overly short MAC address for VFs was accepted and the > missing part filled with random garbage. > > While patch 1 makes sure that in the second case above missing parts are > padded with zero, patch 2 implements a real solution for both by > comparing new and old address lengths prior to accepting the input. For > VFs it is simply assumed that the length must match that of the PF's > address. > > Phil Sutter (2): > iplink: Add missing variable initialization > iplink: Check address length via netlink > > ip/iplink.c | 54 +++++++++++++++++++++++++++++++++++++++++++++++++++--- > 1 file changed, 51 insertions(+), 3 deletions(-) >
Sure. Applied