Skip to content

Commit c2813d1

Browse files
jmberg-intelSasha Levin
authored andcommitted
mac80211: drop multicast fragments
[ Upstream commit a979954 ] These are not permitted by the spec, just drop them. Link: https://lore.kernel.org/r/20210609161305.23def022b750.Ibd6dd3cdce573dae262fcdc47f8ac52b883a9c50@changeid Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent fedc4d4 commit c2813d1

1 file changed

Lines changed: 3 additions & 6 deletions

File tree

‎net/mac80211/rx.c‎

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2250,17 +2250,15 @@ ieee80211_rx_h_defragment(struct ieee80211_rx_data *rx)
22502250
sc = le16_to_cpu(hdr->seq_ctrl);
22512251
frag = sc & IEEE80211_SCTL_FRAG;
22522252

2253-
if (is_multicast_ether_addr(hdr->addr1)) {
2254-
I802_DEBUG_INC(rx->local->dot11MulticastReceivedFrameCount);
2255-
goto out_no_led;
2256-
}
2257-
22582253
if (rx->sta)
22592254
cache = &rx->sta->frags;
22602255

22612256
if (likely(!ieee80211_has_morefrags(fc) && frag == 0))
22622257
goto out;
22632258

2259+
if (is_multicast_ether_addr(hdr->addr1))
2260+
return RX_DROP_MONITOR;
2261+
22642262
I802_DEBUG_INC(rx->local->rx_handlers_fragments);
22652263

22662264
if (skb_linearize(rx->skb))
@@ -2386,7 +2384,6 @@ ieee80211_rx_h_defragment(struct ieee80211_rx_data *rx)
23862384

23872385
out:
23882386
ieee80211_led_rx(rx->local);
2389-
out_no_led:
23902387
if (rx->sta)
23912388
rx->sta->rx_stats.packets++;
23922389
return RX_CONTINUE;

0 commit comments

Comments
 (0)