WSL2-Linux-Kernel/net/netlink
Michal Kubecek 05d7f547be genetlink: do not validate dump requests if there is no policy
Unlike do requests, dump genetlink requests now perform strict validation
by default even if the genetlink family does not set policy and maxtype
because it does validation and parsing on its own (e.g. because it wants to
allow different message format for different commands). While the null
policy will be ignored, maxtype (which would be zero) is still checked so
that any attribute will fail validation.

The solution is to only call __nla_validate() from genl_family_rcv_msg()
if family->maxtype is set.

Fixes: ef6243acb4 ("genetlink: optionally validate strictly/dumps")
Signed-off-by: Michal Kubecek <mkubecek@suse.cz>
Reviewed-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
2019-05-04 01:27:10 -04:00
..
Kconfig
Makefile
af_netlink.c net: netlink: Check address length before reading groups field 2019-04-12 10:25:03 -07:00
af_netlink.h netlink: Add new socket option to enable strict checking on dumps 2018-10-08 10:39:04 -07:00
diag.c
genetlink.c genetlink: do not validate dump requests if there is no policy 2019-05-04 01:27:10 -04:00