|
@@ -452,8 +452,7 @@ static int ieee80211_use_mfp(__le16 fc, struct sta_info *sta,
|
|
if (sta == NULL || !test_sta_flag(sta, WLAN_STA_MFP))
|
|
if (sta == NULL || !test_sta_flag(sta, WLAN_STA_MFP))
|
|
return 0;
|
|
return 0;
|
|
|
|
|
|
- if (!ieee80211_is_robust_mgmt_frame((struct ieee80211_hdr *)
|
|
|
|
- skb->data))
|
|
|
|
|
|
+ if (!ieee80211_is_robust_mgmt_frame(skb))
|
|
return 0;
|
|
return 0;
|
|
|
|
|
|
return 1;
|
|
return 1;
|
|
@@ -567,7 +566,7 @@ ieee80211_tx_h_select_key(struct ieee80211_tx_data *tx)
|
|
tx->key = key;
|
|
tx->key = key;
|
|
else if (ieee80211_is_mgmt(hdr->frame_control) &&
|
|
else if (ieee80211_is_mgmt(hdr->frame_control) &&
|
|
is_multicast_ether_addr(hdr->addr1) &&
|
|
is_multicast_ether_addr(hdr->addr1) &&
|
|
- ieee80211_is_robust_mgmt_frame(hdr) &&
|
|
|
|
|
|
+ ieee80211_is_robust_mgmt_frame(tx->skb) &&
|
|
(key = rcu_dereference(tx->sdata->default_mgmt_key)))
|
|
(key = rcu_dereference(tx->sdata->default_mgmt_key)))
|
|
tx->key = key;
|
|
tx->key = key;
|
|
else if (is_multicast_ether_addr(hdr->addr1) &&
|
|
else if (is_multicast_ether_addr(hdr->addr1) &&
|
|
@@ -582,12 +581,12 @@ ieee80211_tx_h_select_key(struct ieee80211_tx_data *tx)
|
|
tx->key = NULL;
|
|
tx->key = NULL;
|
|
else if (tx->skb->protocol == tx->sdata->control_port_protocol)
|
|
else if (tx->skb->protocol == tx->sdata->control_port_protocol)
|
|
tx->key = NULL;
|
|
tx->key = NULL;
|
|
- else if (ieee80211_is_robust_mgmt_frame(hdr) &&
|
|
|
|
|
|
+ else if (ieee80211_is_robust_mgmt_frame(tx->skb) &&
|
|
!(ieee80211_is_action(hdr->frame_control) &&
|
|
!(ieee80211_is_action(hdr->frame_control) &&
|
|
tx->sta && test_sta_flag(tx->sta, WLAN_STA_MFP)))
|
|
tx->sta && test_sta_flag(tx->sta, WLAN_STA_MFP)))
|
|
tx->key = NULL;
|
|
tx->key = NULL;
|
|
else if (ieee80211_is_mgmt(hdr->frame_control) &&
|
|
else if (ieee80211_is_mgmt(hdr->frame_control) &&
|
|
- !ieee80211_is_robust_mgmt_frame(hdr))
|
|
|
|
|
|
+ !ieee80211_is_robust_mgmt_frame(tx->skb))
|
|
tx->key = NULL;
|
|
tx->key = NULL;
|
|
else {
|
|
else {
|
|
I802_DEBUG_INC(tx->local->tx_handlers_drop_unencrypted);
|
|
I802_DEBUG_INC(tx->local->tx_handlers_drop_unencrypted);
|