diff options
author | TreeHugger Robot <treehugger-gerrit@google.com> | 2022-12-02 10:42:47 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2022-12-02 10:42:47 +0000 |
commit | 5943559fcb50a77e746d64ed547147f4f22ca35a (patch) | |
tree | a610d47b81e5b29a7c950d9ab18c9a170912f01b /hostapd | |
parent | 198d0e8c625d09acfaefa8de14608768690f82a9 (diff) | |
parent | 1a360898757d3bd1a7c3714b1ee51d702057c9b9 (diff) | |
download | wpa_supplicant_8-5943559fcb50a77e746d64ed547147f4f22ca35a.tar.gz |
Merge "Add sanity check for mac address & WPS device type"
Diffstat (limited to 'hostapd')
-rw-r--r-- | hostapd/aidl/hostapd.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/hostapd/aidl/hostapd.cpp b/hostapd/aidl/hostapd.cpp index f2200d6b..35bfbe7c 100644 --- a/hostapd/aidl/hostapd.cpp +++ b/hostapd/aidl/hostapd.cpp @@ -702,6 +702,9 @@ bool forceStaDisconnection(struct hostapd_data* hapd, const std::vector<uint8_t>& client_address, const uint16_t reason_code) { struct sta_info *sta; + if (client_address.size() != ETH_ALEN) { + return false; + } for (sta = hapd->sta_list; sta; sta = sta->next) { int res; res = memcmp(sta->addr, client_address.data(), ETH_ALEN); |