]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
AP: Handle deauthentication frame from PASN station
authorIlan Peer <ilan.peer@intel.com>
Mon, 15 Mar 2021 12:57:10 +0000 (14:57 +0200)
committerJouni Malinen <j@w1.fi>
Tue, 16 Mar 2021 20:41:02 +0000 (22:41 +0200)
When a Deauthentication frame is received, clear the corresponding PTKSA
cache entry for the given station, to invalidate previous PTK
information.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
src/ap/ieee802_11.c

index 7c3e4c8bd496e813787e6289ad472150883d82c7..72d102f44e2120fde6ba5fda39eb990a5249c532 100644 (file)
@@ -5837,6 +5837,9 @@ static void handle_deauth(struct hostapd_data *hapd,
                " reason_code=%d",
                MAC2STR(mgmt->sa), le_to_host16(mgmt->u.deauth.reason_code));
 
+       /* Clear the PTKSA cache entries for PASN */
+       ptksa_cache_flush(hapd->ptksa, mgmt->sa, WPA_CIPHER_NONE);
+
        sta = ap_get_sta(hapd, mgmt->sa);
        if (sta == NULL) {
                wpa_msg(hapd->msg_ctx, MSG_DEBUG, "Station " MACSTR " trying "