Re: [PATCH v2 net-next 11/23] rtnetlink: Update rtnl_stats_dump for strict data checking

2018-10-08 Thread David Miller
From: David Ahern Date: Mon, 8 Oct 2018 07:25:34 -0600 > On 10/8/18 4:17 AM, Christian Brauner wrote: >>> @@ -4696,13 +4697,32 @@ static int rtnl_stats_dump(struct sk_buff *skb, >>> struct netlink_callback *cb) >>> >>> cb->seq = net->dev_base_seq; >>> >>> - if (nlmsg_len(cb->nlh) <

Re: [PATCH v2 net-next 11/23] rtnetlink: Update rtnl_stats_dump for strict data checking

2018-10-08 Thread David Ahern
On 10/8/18 4:17 AM, Christian Brauner wrote: >> @@ -4696,13 +4697,32 @@ static int rtnl_stats_dump(struct sk_buff *skb, >> struct netlink_callback *cb) >> >> cb->seq = net->dev_base_seq; >> >> -if (nlmsg_len(cb->nlh) < sizeof(*ifsm)) >> +if (nlmsg_len(cb->nlh) < sizeof(*ifsm)) {

Re: [PATCH v2 net-next 11/23] rtnetlink: Update rtnl_stats_dump for strict data checking

2018-10-08 Thread Christian Brauner
On Sun, Oct 07, 2018 at 08:16:32PM -0700, David Ahern wrote: > From: David Ahern > > Update rtnl_stats_dump for strict data checking. If the flag is set, > the dump request is expected to have an if_stats_msg struct as the header. > All elements of the struct are expected to be 0 except

[PATCH v2 net-next 11/23] rtnetlink: Update rtnl_stats_dump for strict data checking

2018-10-07 Thread David Ahern
From: David Ahern Update rtnl_stats_dump for strict data checking. If the flag is set, the dump request is expected to have an if_stats_msg struct as the header. All elements of the struct are expected to be 0 except filter_mask which must be non-0 (legacy behavior). No attributes are supported.