Received: by 2002:a17:90a:1609:0:0:0:0 with SMTP id n9csp841113pja; Wed, 1 Apr 2020 09:39:49 -0700 (PDT) X-Google-Smtp-Source: APiQypLSb9r2lqpQbJMCp9Xd/DnmQDJgoSFlGdmQyU2C3FkJumO7efEpamMnc77HSir3A05dcuzp X-Received: by 2002:a4a:3bd7:: with SMTP id s206mr2770690oos.89.1585759189468; Wed, 01 Apr 2020 09:39:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1585759189; cv=none; d=google.com; s=arc-20160816; b=1KFmDJNSe3BnWBynOlhj5N5Y/UM09CbgTP4CCax0QkUKm6kJeh4UcJGVR5yuyxntp6 hrU/w5zYlTxyRwkOjhE6m0UvzpqOky9NDbdbANSJSMK213kpi7FV/sKFmwElsQD+GHjW XciRR9TlRCPHNfaII8Sob2Phv2F0tNOSsE61BmbAVDT50hjs8WS4nIpUwhTrnOqq0XT8 35j+xdcdYKueDPRpsx1uwTM9FgSoj+NySZoVosI3j82cPbfIDEv0S1K5JkbowtY1jsJR 2c7rZhnmrqtzvSeNL2XCUjCEXaArTgd9Fq3Xnl6m52r0B9k8qi8DKLl5HqNbtzLGoBQy C+2A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=VslIUZLby7Z6TPPkFI+9/MLieCRIBLbuFfJSvayIsWc=; b=05aihFrF1qZokw3+gHm54QUoyl7lwT/RBaezlbNU2eKj1B4kDc6N9NW8iw7O/IRGf1 QVMCjY+hlvP65lugxzXiMq/ec04AGQ4f0o6yaItzSn4PwkxlSqJROCS24qrvCV+SIxFw +2OV6hbIOorharqSinUfKtdvWnsRFD7iuTEKUHEUBvU+4MNvtvYnfJ6HeOQ3pyOo67QO OUFFWkHB8/5uGnbp73XIG64ls+FAzqznm3LBcvEjPQjBjKcvUW1xfE2MxAvwhAWARkx3 BnexZjIRs6C3lGMIhgr/wWr7STnwICbd6cwejANMVhDSaA7qoFctR+FEO2gQthHJpm48 I23A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Kwi8cwoL; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j9si1030625oif.164.2020.04.01.09.39.36; Wed, 01 Apr 2020 09:39:49 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Kwi8cwoL; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1733291AbgDAQjH (ORCPT + 99 others); Wed, 1 Apr 2020 12:39:07 -0400 Received: from mail.kernel.org ([198.145.29.99]:38948 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2389153AbgDAQjE (ORCPT ); Wed, 1 Apr 2020 12:39:04 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id E615620BED; Wed, 1 Apr 2020 16:39:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1585759143; bh=ECMTapZiEAO5V+zel/kh53056N1oVlmBEd7f5TKCtXU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Kwi8cwoL9mYliM9PuWHpwnjbhQWbcr0W9Ha+81PcPfzZtAzfweajnxGUIZKG0kxdX 2rGcZprA/Y1cfJTPcJE35qAVlDvYW0QnIGgGRU4PTRfUtNCB57gurCMikch4n4aJ5z 6s8OiA9+MEPPuiy3OKz8FNRhbWBcSrnEi+am4eX8= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Johannes Berg , "David S. Miller" , Woody Suwalski Subject: [PATCH 4.9 091/102] mac80211: fix authentication with iwlwifi/mvm Date: Wed, 1 Apr 2020 18:18:34 +0200 Message-Id: <20200401161547.475362513@linuxfoundation.org> X-Mailer: git-send-email 2.26.0 In-Reply-To: <20200401161530.451355388@linuxfoundation.org> References: <20200401161530.451355388@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Johannes Berg commit be8c827f50a0bcd56361b31ada11dc0a3c2fd240 upstream. The original patch didn't copy the ieee80211_is_data() condition because on most drivers the management frames don't go through this path. However, they do on iwlwifi/mvm, so we do need to keep the condition here. Cc: stable@vger.kernel.org Fixes: ce2e1ca70307 ("mac80211: Check port authorization in the ieee80211_tx_dequeue() case") Signed-off-by: Johannes Berg Signed-off-by: David S. Miller Cc: Woody Suwalski Signed-off-by: Greg Kroah-Hartman --- net/mac80211/tx.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) --- a/net/mac80211/tx.c +++ b/net/mac80211/tx.c @@ -3418,7 +3418,8 @@ begin: * Drop unicast frames to unauthorised stations unless they are * EAPOL frames from the local station. */ - if (unlikely(!ieee80211_vif_is_mesh(&tx.sdata->vif) && + if (unlikely(ieee80211_is_data(hdr->frame_control) && + !ieee80211_vif_is_mesh(&tx.sdata->vif) && tx.sdata->vif.type != NL80211_IFTYPE_OCB && !is_multicast_ether_addr(hdr->addr1) && !test_sta_flag(tx.sta, WLAN_STA_AUTHORIZED) &&