summaryrefslogtreecommitdiff
path: root/net/ipv6
diff options
context:
space:
mode:
authorDaniel Borkmann <daniel@iogearbox.net>2015-02-05 18:44:04 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-03-18 14:10:48 +0100
commit4f630d422d9a18523c75be7fa81d413210904a44 (patch)
tree5a8f5108ce3e99559101b9b4915e4c08343da159 /net/ipv6
parent18bb5d3023fbf4331128c67df627cd88ab47911b (diff)
rtnetlink: ifla_vf_policy: fix misuses of NLA_BINARY
[ Upstream commit 364d5716a7adb91b731a35765d369602d68d2881 ] ifla_vf_policy[] is wrong in advertising its individual member types as NLA_BINARY since .type = NLA_BINARY in combination with .len declares the len member as *max* attribute length [0, len]. The issue is that when do_setvfinfo() is being called to set up a VF through ndo handler, we could set corrupted data if the attribute length is less than the size of the related structure itself. The intent is exactly the opposite, namely to make sure to pass at least data of minimum size of len. Fixes: ebc08a6f47ee ("rtnetlink: Add VF config code to rtnetlink") Cc: Mitch Williams <mitch.a.williams@intel.com> Cc: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Thomas Graf <tgraf@suug.ch> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net/ipv6')
0 files changed, 0 insertions, 0 deletions