Message ID | 1456784940-32328-1-git-send-email-jouni@qca.qualcomm.com (mailing list archive) |
---|---|
State | Accepted |
Delegated to: | Johannes Berg |
Headers | show |
On Tue, Mar 1, 2016 at 12:29 AM, Jouni Malinen <jouni@qca.qualcomm.com> wrote: > Public Action frames use special rules for how the BSSID field (Address > 3) is set. A wildcard BSSID is used in cases where the transmitter and > recipient are not members of the same BSS. As such, we need to accept > Public Action frames with wildcard BSSID. > > Commit db8e17324553 ("mac80211: ignore frames between TDLS peers when > operating as AP") added a rule that drops Action frames to TDLS-peers > based on an Action frame having different DA (Address 1) and BSSID > (Address 3) values. This is not correct since it misses the possibility > of BSSID being a wildcard BSSID in which case the Address 1 would not > necessarily match. > > Fix this by allowing mac80211 to accept wildcard BSSID in an Action > frame when in AP mode. > > Fixes: db8e17324553 ("mac80211: ignore frames between TDLS peers when operating as AP") Fix looks good (I'm the author of the bug) :) Arik -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Tue, 2016-03-01 at 00:29 +0200, Jouni Malinen wrote: > Public Action frames use special rules for how the BSSID field > (Address > 3) is set. A wildcard BSSID is used in cases where the transmitter > and > recipient are not members of the same BSS. As such, we need to accept > Public Action frames with wildcard BSSID. > > Commit db8e17324553 ("mac80211: ignore frames between TDLS peers when > operating as AP") added a rule that drops Action frames to TDLS-peers > based on an Action frame having different DA (Address 1) and BSSID > (Address 3) values. This is not correct since it misses the > possibility > of BSSID being a wildcard BSSID in which case the Address 1 would not > necessarily match. > > Fix this by allowing mac80211 to accept wildcard BSSID in an Action > frame when in AP mode. > Applied, thanks. johannes -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c index 9127957..25803e7 100644 --- a/net/mac80211/rx.c +++ b/net/mac80211/rx.c @@ -3473,6 +3473,7 @@ static bool ieee80211_accept_frame(struct ieee80211_rx_data *rx) return false; /* ignore action frames to TDLS-peers */ if (ieee80211_is_action(hdr->frame_control) && + !is_broadcast_ether_addr(bssid) && !ether_addr_equal(bssid, hdr->addr1)) return false; }
Public Action frames use special rules for how the BSSID field (Address 3) is set. A wildcard BSSID is used in cases where the transmitter and recipient are not members of the same BSS. As such, we need to accept Public Action frames with wildcard BSSID. Commit db8e17324553 ("mac80211: ignore frames between TDLS peers when operating as AP") added a rule that drops Action frames to TDLS-peers based on an Action frame having different DA (Address 1) and BSSID (Address 3) values. This is not correct since it misses the possibility of BSSID being a wildcard BSSID in which case the Address 1 would not necessarily match. Fix this by allowing mac80211 to accept wildcard BSSID in an Action frame when in AP mode. Fixes: db8e17324553 ("mac80211: ignore frames between TDLS peers when operating as AP") Cc: stable@vger.kernel.org Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com> --- net/mac80211/rx.c | 1 + 1 file changed, 1 insertion(+)