ipv6: add RTA_TABLE and RTA_PREFSRC to rtm_ipv6_policy
authorEric Dumazet <edumazet@google.com>
Mon, 23 Apr 2018 01:29:23 +0000 (18:29 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 29 Apr 2018 09:32:02 +0000 (11:32 +0200)
commite2956fc8356549c7072a6b420b500bb5fe32c4fb
treed5dd4d6cfe1e945cf001e415dce55a0a4180c424
parent55ca7b1d43a9d9958ce8544dee938e6c62c263ec
ipv6: add RTA_TABLE and RTA_PREFSRC to rtm_ipv6_policy

[ Upstream commit aa8f8778493c85fff480cdf8b349b1e1dcb5f243 ]

KMSAN reported use of uninit-value that I tracked to lack
of proper size check on RTA_TABLE attribute.

I also believe RTA_PREFSRC lacks a similar check.

Fixes: 86872cb57925 ("[IPv6] route: FIB6 configuration using struct fib6_config")
Fixes: c3968a857a6b ("ipv6: RTA_PREFSRC support for ipv6 route source address selection")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Reported-by: syzbot <syzkaller@googlegroups.com>
Acked-by: David Ahern <dsahern@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/ipv6/route.c