This patch reverts the following CVS commit:

ieee80211_proto.c revision 1.97
date: 2020/05/29 07:34:19;  author: stsp;  state: Exp;  lines: +7 -1;
commitid: 8vKZsdvvkjTr5BG5;

This change was wrong because it was made under the assumption that
frames queued on the power-saving queue were already encrypted. This
is not the case! Rather, the frame will be encrypted in the driver's
transmit path after the frame is pulled from the power-saving queue.

So this change introduced a possibility that outgoing management or
multicast frames are discarded when the group key is changed, and it
didn't actually fix anything.

diff d5cea33885618bf7e096efc36fffbecc9b13ed21 
0cc5b904b4fd02e989e83cfc8a743c3e63ac7c01
blob - bf7abf058b86c4b0ad402a22c2e3f3c35e81788e
blob + 385f7063300d434ffe9ace5b42e52d9f8e1f7803
--- sys/net80211/ieee80211_proto.c
+++ sys/net80211/ieee80211_proto.c
@@ -471,12 +471,6 @@ ieee80211_setkeysdone(struct ieee80211com *ic)
 {
        u_int8_t kid;
 
-       /*
-        * Discard frames buffered for power-saving which were encrypted with
-        * the old group key. Clients are no longer able to decrypt them.
-        */
-       mq_purge(&ic->ic_bss->ni_savedq);
-
        /* install GTK */
        kid = (ic->ic_def_txkey == 1) ? 2 : 1;
        switch ((*ic->ic_set_key)(ic, ic->ic_bss, &ic->ic_nw_keys[kid])) {


Reply via email to