netfilter: nft_range: validate operation netlink attribute
authorPablo Neira Ayuso <pablo@netfilter.org>
Thu, 13 Oct 2016 06:42:17 +0000 (08:42 +0200)
committerPablo Neira Ayuso <pablo@netfilter.org>
Mon, 17 Oct 2016 16:57:02 +0000 (18:57 +0200)
commitccca6607c545534e5b74ef04e0f2f6ba11344be4
tree5288ff52b3888084f4462615a842e76c0d2302b3
parent21a9e0f1568eaa0aad970c06e4cc8d77de8d9fa1
netfilter: nft_range: validate operation netlink attribute

Use nft_parse_u32_check() to make sure we don't get a value over the
unsigned 8-bit integer. Moreover, make sure this value doesn't go over
the two supported range comparison modes.

Fixes: 9286c2eb1fda ("netfilter: nft_range: validate operation netlink attribute")
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
net/netfilter/nft_range.c