]> git.baikalelectronics.ru Git - kernel.git/commit
net: netlink: Update attr validation to require exact length for some types
authorDavid Ahern <dsahern@gmail.com>
Wed, 8 Nov 2017 05:59:40 +0000 (21:59 -0800)
committerDavid S. Miller <davem@davemloft.net>
Sat, 11 Nov 2017 06:14:38 +0000 (15:14 +0900)
commitea2779ad949364e72eacc65b2413695a7d1335d2
tree28b50e6aced09e14ff02b907745ec511d2ee8790
parent3c3fab8b24e177d39c52dd625a84ff375be4b9ef
net: netlink: Update attr validation to require exact length for some types

Attributes using NLA_U* and NLA_S* (where * is 8, 16,32 and 64) are
expected to be an exact length. Split these data types from
nla_attr_minlen into nla_attr_len and update validate_nla to require
the attribute to have exact length for them.

Signed-off-by: David Ahern <dsahern@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
lib/nlattr.c