diff options
author | Eric Biggers <ebiggers@google.com> | 2018-05-14 20:09:24 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2018-06-13 16:12:20 +0200 |
commit | 4ff12f87c37257ac68b5bfa676409c7b35529168 (patch) | |
tree | d1251c48556c5afa39057a2e92ef4b48751d2b35 /include | |
parent | b1ebe5e9a3744a00f9a3ffdc74b4d996c9deba28 (diff) | |
download | linux-stable-4ff12f87c37257ac68b5bfa676409c7b35529168.tar.gz linux-stable-4ff12f87c37257ac68b5bfa676409c7b35529168.tar.bz2 linux-stable-4ff12f87c37257ac68b5bfa676409c7b35529168.zip |
cfg80211: further limit wiphy names to 64 bytes
commit 814596495dd2b9d4aab92d8f89cf19060d25d2ea upstream.
wiphy names were recently limited to 128 bytes by commit a7cfebcb7594
("cfg80211: limit wiphy names to 128 bytes"). As it turns out though,
this isn't sufficient because dev_vprintk_emit() needs the syslog header
string "SUBSYSTEM=ieee80211\0DEVICE=+ieee80211:$devname" to fit into 128
bytes. This triggered the "device/subsystem name too long" WARN when
the device name was >= 90 bytes. As before, this was reproduced by
syzbot by sending an HWSIM_CMD_NEW_RADIO command to the MAC80211_HWSIM
generic netlink family.
Fix it by further limiting wiphy names to 64 bytes.
Reported-by: syzbot+e64565577af34b3768dc@syzkaller.appspotmail.com
Fixes: a7cfebcb7594 ("cfg80211: limit wiphy names to 128 bytes")
Signed-off-by: Eric Biggers <ebiggers@google.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/uapi/linux/nl80211.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h index 81e5bfd46743..35564527fd29 100644 --- a/include/uapi/linux/nl80211.h +++ b/include/uapi/linux/nl80211.h @@ -2026,7 +2026,7 @@ enum nl80211_attrs { #define NL80211_ATTR_KEYS NL80211_ATTR_KEYS #define NL80211_ATTR_FEATURE_FLAGS NL80211_ATTR_FEATURE_FLAGS -#define NL80211_WIPHY_NAME_MAXLEN 128 +#define NL80211_WIPHY_NAME_MAXLEN 64 #define NL80211_MAX_SUPP_RATES 32 #define NL80211_MAX_SUPP_HT_RATES 77 |