]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit
mac80211: treat some SAE auth steps as final
authorJohannes Berg <johannes.berg@intel.com>
Thu, 24 Feb 2022 09:39:34 +0000 (10:39 +0100)
committerPaolo Pisati <paolo.pisati@canonical.com>
Wed, 9 Mar 2022 14:17:53 +0000 (15:17 +0100)
commit116b4468e842226e8077949893a49db993dd2b84
tree9731289fbf6e3397d2b812980c325ea34d0229d8
parent7816f0f43c4f93849cc1c62cf78d2481492a48cc
mac80211: treat some SAE auth steps as final

BugLink: https://bugs.launchpad.net/bugs/1964361
commit 94d9864cc86f572f881db9b842a78e9d075493ae upstream.

When we get anti-clogging token required (added by the commit
mentioned below), or the other status codes added by the later
commit 4e56cde15f7d ("mac80211: Handle special status codes in
SAE commit") we currently just pretend (towards the internal
state machine of authentication) that we didn't receive anything.

This has the undesirable consequence of retransmitting the prior
frame, which is not expected, because the timer is still armed.

If we just disarm the timer at that point, it would result in
the undesirable side effect of being in this state indefinitely
if userspace crashes, or so.

So to fix this, reset the timer and set a new auth_data->waiting
in order to have no more retransmissions, but to have the data
destroyed when the timer actually fires, which will only happen
if userspace didn't continue (i.e. crashed or abandoned it.)

Fixes: a4055e74a2ff ("mac80211: Don't destroy auth data in case of anti-clogging")
Reported-by: Jouni Malinen <j@w1.fi>
Link: https://lore.kernel.org/r/20220224103932.75964e1d7932.Ia487f91556f29daae734bf61f8181404642e1eec@changeid
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Paolo Pisati <paolo.pisati@canonical.com>
net/mac80211/ieee80211_i.h
net/mac80211/mlme.c