diff options
author | Rafał Miłecki <rafal@milecki.pl> | 2018-06-17 22:46:35 +0200 |
---|---|---|
committer | Rafał Miłecki <rafal@milecki.pl> | 2018-06-23 14:29:39 +0200 |
commit | 72f6025d69ac0260b90192da481a52cd72f842fb (patch) | |
tree | e11858583b15e2dafe9eb76c52b548590b8675f6 /package/kernel/mac80211/patches/326-v4.17-0001-brcmfmac-reject-too-long-PSK.patch | |
parent | 8cfd43d1d65aa70dff06ef2f63186a4c4285bccc (diff) | |
download | upstream-72f6025d69ac0260b90192da481a52cd72f842fb.tar.gz upstream-72f6025d69ac0260b90192da481a52cd72f842fb.tar.bz2 upstream-72f6025d69ac0260b90192da481a52cd72f842fb.zip |
mac80211: backport brcmfmac data structure rework
It backports brcmfmac commits from kernel 4.17.
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
(cherry picked from commit 3c8bb92655c68a07abf5358ef23eb98422ed8d6d)
Diffstat (limited to 'package/kernel/mac80211/patches/326-v4.17-0001-brcmfmac-reject-too-long-PSK.patch')
-rw-r--r-- | package/kernel/mac80211/patches/326-v4.17-0001-brcmfmac-reject-too-long-PSK.patch | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/package/kernel/mac80211/patches/326-v4.17-0001-brcmfmac-reject-too-long-PSK.patch b/package/kernel/mac80211/patches/326-v4.17-0001-brcmfmac-reject-too-long-PSK.patch new file mode 100644 index 0000000000..b83f2fce8b --- /dev/null +++ b/package/kernel/mac80211/patches/326-v4.17-0001-brcmfmac-reject-too-long-PSK.patch @@ -0,0 +1,27 @@ +From 64d1519edc959f5b8f86a66a51c40971c215e4ec Mon Sep 17 00:00:00 2001 +From: Johannes Berg <johannes.berg@intel.com> +Date: Mon, 19 Feb 2018 13:30:45 +0100 +Subject: [PATCH] brcmfmac: reject too long PSK + +nl80211 already allows specifying 48 bytes, but brcmfmac +only supports 32. Reject keys that are too long. + +Signed-off-by: Johannes Berg <johannes.berg@intel.com> +Acked-by: Arend van Spriel <arend.vanspriel@broadcom.com> +Signed-off-by: Kalle Valo <kvalo@codeaurora.org> +--- + drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c | 3 +++ + 1 file changed, 3 insertions(+) + +--- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c ++++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c +@@ -5125,6 +5125,9 @@ static int brcmf_cfg80211_set_pmk(struct + if (WARN_ON(ifp->vif->profile.use_fwsup != BRCMF_PROFILE_FWSUP_1X)) + return -EINVAL; + ++ if (conf->pmk_len > BRCMF_WSEC_MAX_PSK_LEN) ++ return -ERANGE; ++ + return brcmf_set_pmk(ifp, conf->pmk, conf->pmk_len); + } + |