Maciej Żenczykowski 2c16db6c92 net: fix nla_strcmp to handle more then one trailing null character
Android userspace has been using TCA_KIND with a char[IFNAMESIZ]
many-null-terminated buffer containing the string 'bpf'.

This works on 4.19 and ceases to work on 5.10.

I'm not entirely sure what fixes tag to use, but I think the issue
was likely introduced in the below mentioned 5.4 commit.

Reported-by: Nucca Chen <nuccachen@google.com>
Cc: Cong Wang <xiyou.wangcong@gmail.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: David S. Miller <davem@davemloft.net>
Cc: Jakub Kicinski <jakub.kicinski@netronome.com>
Cc: Jamal Hadi Salim <jhs@mojatatu.com>
Cc: Jiri Pirko <jiri@mellanox.com>
Cc: Jiri Pirko <jiri@resnulli.us>
Fixes: 62794fc4fbf5 ("net_sched: add max len check for TCA_KIND")
Change-Id: I66dc281f165a2858fc29a44869a270a2d698a82b
Signed-off-by: David S. Miller <davem@davemloft.net>
2021-05-05 12:48:46 -07:00
..
2020-08-09 14:10:26 -07:00
2021-04-29 11:28:08 -07:00
2020-10-30 17:34:45 +11:00
2021-04-14 16:30:30 +03:00
2020-05-24 20:48:11 +02:00
2018-08-16 12:14:42 -07:00
2021-02-08 12:24:26 +01:00
2021-01-21 14:06:00 -07:00
2021-01-03 20:05:18 -05:00
2020-10-20 14:39:37 -07:00
2021-04-14 16:30:30 +03:00
2021-04-29 11:28:08 -07:00
2021-02-26 09:41:02 -08:00
2021-02-26 09:41:05 -08:00
2021-04-14 16:30:30 +03:00
2018-10-16 13:45:44 +02:00
2021-02-03 19:10:42 +01:00
2020-06-15 18:22:43 -07:00
2019-07-11 15:17:41 -07:00
2020-12-15 22:46:16 -08:00
2018-10-15 16:31:29 -04:00
2020-12-15 22:46:16 -08:00
2021-04-28 10:01:40 -07:00
2021-02-26 09:41:05 -08:00
2021-02-26 09:41:05 -08:00
2021-04-28 10:01:40 -07:00