linux_dsm_epyc7002/net/ethtool
Michal Kubecek 62162b3223 ethtool: fix string set id check
[ Upstream commit efb796f5571f030743e1d9c662cdebdad724f8c5 ]

Syzbot reported a shift of a u32 by more than 31 in strset_parse_request()
which is undefined behavior. This is caused by range check of string set id
using variable ret (which is always 0 at this point) instead of id (string
set id from request).

Fixes: 71921690f9 ("ethtool: provide string sets with STRSET_GET request")
Reported-by: syzbot+96523fb438937cd01220@syzkaller.appspotmail.com
Signed-off-by: Michal Kubecek <mkubecek@suse.cz>
Link: https://lore.kernel.org/r/b54ed5c5fd972a59afea3e1badfb36d86df68799.1607952208.git.mkubecek@suse.cz
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-01-06 14:56:48 +01:00
..
bitset.c ethtool: fix stack overflow in ethnl_parse_bitset() 2020-12-09 15:50:38 -08:00
bitset.h
cabletest.c
channels.c ethtool: fix error paths in ethnl_set_channels() 2021-01-06 14:56:48 +01:00
coalesce.c
common.c
common.h
debug.c
eee.c
features.c ethtool: netlink: add missing netdev_features_change() call 2020-11-09 17:15:34 -08:00
ioctl.c
linkinfo.c
linkmodes.c
linkstate.c
Makefile
netlink.c ethtool: correct policy for ETHTOOL_MSG_CHANNELS_SET 2020-10-08 16:06:01 -07:00
netlink.h ethtool: strset: allow ETHTOOL_A_STRSET_COUNTS_ONLY attr 2020-10-08 16:06:01 -07:00
pause.c
privflags.c
rings.c
strset.c ethtool: fix string set id check 2021-01-06 14:56:48 +01:00
tsinfo.c
tunnels.c
wol.c