Do not disassociate not-associated STA on timeout
If the ap_handle_timer() timeout is reached for a not-associated STA, do not default to disassociating that STA first since Disassociation frame is not really appropriate to send to a STA that is not in associated state. Instead, skip directly to deauthentication and STA entry removal. Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
This commit is contained in:
parent
91205c8eb4
commit
f3a841bbff
1 changed files with 7 additions and 0 deletions
|
@ -501,6 +501,13 @@ skip_poll:
|
|||
} else if (sta->timeout_next != STA_REMOVE) {
|
||||
int deauth = sta->timeout_next == STA_DEAUTH;
|
||||
|
||||
if (!deauth && !(sta->flags & WLAN_STA_ASSOC)) {
|
||||
/* Cannot disassociate not-associated STA, so move
|
||||
* directly to deauthentication. */
|
||||
sta->timeout_next = STA_DEAUTH;
|
||||
deauth = 1;
|
||||
}
|
||||
|
||||
wpa_dbg(hapd->msg_ctx, MSG_DEBUG,
|
||||
"Timeout, sending %s info to STA " MACSTR,
|
||||
deauth ? "deauthentication" : "disassociation",
|
||||
|
|
Loading…
Reference in a new issue