Changeset 38013


Ignore:
Timestamp:
2013-09-17T11:17:40+02:00 (4 years ago)
Author:
nbd
Message:

mac80211: drop spoofed packets in ad-hoc mode (fixes #12427)

Signed-off-by: Felix Fietkau <nbd@…>

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/package/kernel/mac80211/patches/300-pending_work.patch

    r37985 r38013  
    340340        case cpu_to_le16(IEEE80211_STYPE_ASSOC_RESP): 
    341341        case cpu_to_le16(IEEE80211_STYPE_REASSOC_RESP): 
    342 @@ -3059,10 +3067,16 @@ static int prepare_for_handlers(struct i 
     342@@ -3008,6 +3016,9 @@ static int prepare_for_handlers(struct i 
     343        case NL80211_IFTYPE_ADHOC: 
     344                if (!bssid) 
     345                        return 0; 
     346+               if (ether_addr_equal(sdata->vif.addr, hdr->addr2) || 
     347+                   ether_addr_equal(sdata->u.ibss.bssid, hdr->addr2)) 
     348+                       return 0; 
     349                if (ieee80211_is_beacon(hdr->frame_control)) { 
     350                        return 1; 
     351                } else if (!ieee80211_bssid_match(bssid, sdata->u.ibss.bssid)) { 
     352@@ -3059,10 +3070,16 @@ static int prepare_for_handlers(struct i 
    343353                } 
    344354                break; 
Note: See TracChangeset for help on using the changeset viewer.