Skip to content

Commit

Permalink
mac80211: fix fast-rx encryption check
Browse files Browse the repository at this point in the history
When using WEP, the default unicast key needs to be selected, instead of
the STA PTK.

Signed-off-by: Felix Fietkau <nbd@nbd.name>
Link: https://lore.kernel.org/r/20201218184718.93650-5-nbd@nbd.name
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
  • Loading branch information
Felix Fietkau authored and Johannes Berg committed Jan 14, 2021
1 parent 6020d53 commit 622d3b4
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions net/mac80211/rx.c
Original file line number Diff line number Diff line change
@@ -4176,6 +4176,8 @@ void ieee80211_check_fast_rx(struct sta_info *sta)

rcu_read_lock();
key = rcu_dereference(sta->ptk[sta->ptk_idx]);
if (!key)
key = rcu_dereference(sdata->default_unicast_key);
if (key) {
switch (key->conf.cipher) {
case WLAN_CIPHER_SUITE_TKIP:

0 comments on commit 622d3b4

Please sign in to comment.