mirror of
https://github.com/outbackdingo/mt76.git
synced 2026-10-24 13:26:48 +00:00
wifi: mt76: mt7921: fix using incorrect group cipher after disconnection.
To avoid incorrect cipher after disconnection, we should
do the key deletion process in this case.
Fixes: e6db67fa871d ("wifi: mt76: ignore key disable commands")
Signed-off-by: Michael Lo <[email protected]>
Signed-off-by: Ming Yen Hsieh <[email protected]>
Tested-by: David Ruth <[email protected]>
Reviewed-by: David Ruth <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Felix Fietkau <[email protected]>
This commit is contained in:
committed by
Felix Fietkau
parent
61641da04c
commit
680bc70f16
+7
-1
@@ -531,7 +531,13 @@ static int mt7921_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd,
|
||||
} else {
|
||||
if (idx == *wcid_keyidx)
|
||||
*wcid_keyidx = -1;
|
||||
goto out;
|
||||
|
||||
/* For security issue we don't trigger the key deletion when
|
||||
* reassociating. But we should trigger the deletion process
|
||||
* to avoid using incorrect cipher after disconnection,
|
||||
*/
|
||||
if (vif->type != NL80211_IFTYPE_STATION || vif->cfg.assoc)
|
||||
goto out;
|
||||
}
|
||||
|
||||
mt76_wcid_key_setup(&dev->mt76, wcid, key);
|
||||
|
||||
Reference in New Issue
Block a user