Patch "mac80211: skip mpath lookup also for control port tx" has been added to the 5.4-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    mac80211: skip mpath lookup also for control port tx

to the 5.4-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     mac80211-skip-mpath-lookup-also-for-control-port-tx.patch
and it can be found in the queue-5.4 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit fc6e39263620e8a5f5cd8ac0c1d6c2eccf776bd4
Author: Markus Theil <markus.theil@xxxxxxxxxxxxx>
Date:   Wed Jun 17 10:26:36 2020 +0200

    mac80211: skip mpath lookup also for control port tx
    
    [ Upstream commit 5af7fef39d7952c0f5551afa7b821ee7b6c9dd3d ]
    
    When using 802.1X over mesh networks, at first an ordinary
    mesh peering is established, then the 802.1X EAPOL dialog
    happens, afterwards an authenticated mesh peering exchange
    (AMPE) happens, finally the peering is complete and we can
    set the STA authorized flag.
    
    As 802.1X is an intermediate step here and key material is
    not yet exchanged for stations we have to skip mesh path lookup
    for these EAPOL frames. Otherwise the already configure mesh
    group encryption key would be used to send a mesh path request
    which no one can decipher, because we didn't already establish
    key material on both peers, like with SAE and directly using AMPE.
    
    Signed-off-by: Markus Theil <markus.theil@xxxxxxxxxxxxx>
    Link: https://lore.kernel.org/r/20200617082637.22670-2-markus.theil@xxxxxxxxxxxxx
    [remove pointless braces, remove unnecessary local variable,
     the list can only process one such frame (or its fragments)]
    Signed-off-by: Johannes Berg <johannes.berg@xxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c
index 30201aeb426cf..f029e75ec815a 100644
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -3913,6 +3913,9 @@ void __ieee80211_subif_start_xmit(struct sk_buff *skb,
 		skb->prev = NULL;
 		skb->next = NULL;
 
+		if (skb->protocol == sdata->control_port_protocol)
+			ctrl_flags |= IEEE80211_TX_CTRL_SKIP_MPATH_LOOKUP;
+
 		skb = ieee80211_build_hdr(sdata, skb, info_flags,
 					  sta, ctrl_flags);
 		if (IS_ERR(skb))
@@ -5096,7 +5099,8 @@ int ieee80211_tx_control_port(struct wiphy *wiphy, struct net_device *dev,
 		return -EINVAL;
 
 	if (proto == sdata->control_port_protocol)
-		ctrl_flags |= IEEE80211_TX_CTRL_PORT_CTRL_PROTO;
+		ctrl_flags |= IEEE80211_TX_CTRL_PORT_CTRL_PROTO |
+			      IEEE80211_TX_CTRL_SKIP_MPATH_LOOKUP;
 
 	if (unencrypted)
 		flags = IEEE80211_TX_INTFL_DONT_ENCRYPT;



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux