linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH AUTOSEL 5.4 56/73] nl80211: add missing attribute validation for critical protocol indication
       [not found] <20200318205337.16279-1-sashal@kernel.org>
@ 2020-03-18 20:53 ` Sasha Levin
  2020-03-18 20:53 ` [PATCH AUTOSEL 5.4 57/73] nl80211: add missing attribute validation for beacon report scanning Sasha Levin
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 4+ messages in thread
From: Sasha Levin @ 2020-03-18 20:53 UTC (permalink / raw)
  To: linux-kernel, stable
  Cc: Jakub Kicinski, Johannes Berg, Sasha Levin, linux-wireless,
	netdev

From: Jakub Kicinski <kuba@kernel.org>

[ Upstream commit 0e1a1d853ecedc99da9d27f9f5c376935547a0e2 ]

Add missing attribute validation for critical protocol fields
to the netlink policy.

Fixes: 5de17984898c ("cfg80211: introduce critical protocol indication from user-space")
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Link: https://lore.kernel.org/r/20200303051058.4089398-2-kuba@kernel.org
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
 net/wireless/nl80211.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index 17514744af9e0..9ca16ca0528ac 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -530,6 +530,8 @@ const struct nla_policy nl80211_policy[NUM_NL80211_ATTR] = {
 	[NL80211_ATTR_MDID] = { .type = NLA_U16 },
 	[NL80211_ATTR_IE_RIC] = { .type = NLA_BINARY,
 				  .len = IEEE80211_MAX_DATA_LEN },
+	[NL80211_ATTR_CRIT_PROT_ID] = { .type = NLA_U16 },
+	[NL80211_ATTR_MAX_CRIT_PROT_DURATION] = { .type = NLA_U16 },
 	[NL80211_ATTR_PEER_AID] =
 		NLA_POLICY_RANGE(NLA_U16, 1, IEEE80211_MAX_AID),
 	[NL80211_ATTR_CH_SWITCH_COUNT] = { .type = NLA_U32 },
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH AUTOSEL 5.4 57/73] nl80211: add missing attribute validation for beacon report scanning
       [not found] <20200318205337.16279-1-sashal@kernel.org>
  2020-03-18 20:53 ` [PATCH AUTOSEL 5.4 56/73] nl80211: add missing attribute validation for critical protocol indication Sasha Levin
@ 2020-03-18 20:53 ` Sasha Levin
  2020-03-18 20:53 ` [PATCH AUTOSEL 5.4 58/73] nl80211: add missing attribute validation for channel switch Sasha Levin
  2020-03-18 20:53 ` [PATCH AUTOSEL 5.4 59/73] mac80211: Do not send mesh HWMP PREQ if HWMP is disabled Sasha Levin
  3 siblings, 0 replies; 4+ messages in thread
From: Sasha Levin @ 2020-03-18 20:53 UTC (permalink / raw)
  To: linux-kernel, stable
  Cc: Jakub Kicinski, Johannes Berg, Sasha Levin, linux-wireless,
	netdev

From: Jakub Kicinski <kuba@kernel.org>

[ Upstream commit 056e9375e1f3c4bf2fd49b70258c7daf788ecd9d ]

Add missing attribute validation for beacon report scanning
to the netlink policy.

Fixes: 1d76250bd34a ("nl80211: support beacon report scanning")
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Link: https://lore.kernel.org/r/20200303051058.4089398-3-kuba@kernel.org
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
 net/wireless/nl80211.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index 9ca16ca0528ac..f0c6c522964c2 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -469,6 +469,8 @@ const struct nla_policy nl80211_policy[NUM_NL80211_ATTR] = {
 	[NL80211_ATTR_WOWLAN_TRIGGERS] = { .type = NLA_NESTED },
 	[NL80211_ATTR_STA_PLINK_STATE] =
 		NLA_POLICY_MAX(NLA_U8, NUM_NL80211_PLINK_STATES - 1),
+	[NL80211_ATTR_MEASUREMENT_DURATION] = { .type = NLA_U16 },
+	[NL80211_ATTR_MEASUREMENT_DURATION_MANDATORY] = { .type = NLA_FLAG },
 	[NL80211_ATTR_MESH_PEER_AID] =
 		NLA_POLICY_RANGE(NLA_U16, 1, IEEE80211_MAX_AID),
 	[NL80211_ATTR_SCHED_SCAN_INTERVAL] = { .type = NLA_U32 },
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH AUTOSEL 5.4 58/73] nl80211: add missing attribute validation for channel switch
       [not found] <20200318205337.16279-1-sashal@kernel.org>
  2020-03-18 20:53 ` [PATCH AUTOSEL 5.4 56/73] nl80211: add missing attribute validation for critical protocol indication Sasha Levin
  2020-03-18 20:53 ` [PATCH AUTOSEL 5.4 57/73] nl80211: add missing attribute validation for beacon report scanning Sasha Levin
@ 2020-03-18 20:53 ` Sasha Levin
  2020-03-18 20:53 ` [PATCH AUTOSEL 5.4 59/73] mac80211: Do not send mesh HWMP PREQ if HWMP is disabled Sasha Levin
  3 siblings, 0 replies; 4+ messages in thread
From: Sasha Levin @ 2020-03-18 20:53 UTC (permalink / raw)
  To: linux-kernel, stable
  Cc: Jakub Kicinski, Johannes Berg, Sasha Levin, linux-wireless,
	netdev

From: Jakub Kicinski <kuba@kernel.org>

[ Upstream commit 5cde05c61cbe13cbb3fa66d52b9ae84f7975e5e6 ]

Add missing attribute validation for NL80211_ATTR_OPER_CLASS
to the netlink policy.

Fixes: 1057d35ede5d ("cfg80211: introduce TDLS channel switch commands")
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Link: https://lore.kernel.org/r/20200303051058.4089398-4-kuba@kernel.org
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
 net/wireless/nl80211.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index f0c6c522964c2..321c132747ce7 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -564,6 +564,7 @@ const struct nla_policy nl80211_policy[NUM_NL80211_ATTR] = {
 		NLA_POLICY_MAX(NLA_U8, IEEE80211_NUM_UPS - 1),
 	[NL80211_ATTR_ADMITTED_TIME] = { .type = NLA_U16 },
 	[NL80211_ATTR_SMPS_MODE] = { .type = NLA_U8 },
+	[NL80211_ATTR_OPER_CLASS] = { .type = NLA_U8 },
 	[NL80211_ATTR_MAC_MASK] = {
 		.type = NLA_EXACT_LEN_WARN,
 		.len = ETH_ALEN
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH AUTOSEL 5.4 59/73] mac80211: Do not send mesh HWMP PREQ if HWMP is disabled
       [not found] <20200318205337.16279-1-sashal@kernel.org>
                   ` (2 preceding siblings ...)
  2020-03-18 20:53 ` [PATCH AUTOSEL 5.4 58/73] nl80211: add missing attribute validation for channel switch Sasha Levin
@ 2020-03-18 20:53 ` Sasha Levin
  3 siblings, 0 replies; 4+ messages in thread
From: Sasha Levin @ 2020-03-18 20:53 UTC (permalink / raw)
  To: linux-kernel, stable
  Cc: Nicolas Cavallari, Johannes Berg, Sasha Levin, linux-wireless,
	netdev

From: Nicolas Cavallari <nicolas.cavallari@green-communications.fr>

[ Upstream commit ba32679cac50c38fdf488296f96b1f3175532b8e ]

When trying to transmit to an unknown destination, the mesh code would
unconditionally transmit a HWMP PREQ even if HWMP is not the current
path selection algorithm.

Signed-off-by: Nicolas Cavallari <nicolas.cavallari@green-communications.fr>
Link: https://lore.kernel.org/r/20200305140409.12204-1-cavallar@lri.fr
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
 net/mac80211/mesh_hwmp.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/net/mac80211/mesh_hwmp.c b/net/mac80211/mesh_hwmp.c
index d699833703819..38a0383dfbcfa 100644
--- a/net/mac80211/mesh_hwmp.c
+++ b/net/mac80211/mesh_hwmp.c
@@ -1152,7 +1152,8 @@ int mesh_nexthop_resolve(struct ieee80211_sub_if_data *sdata,
 		}
 	}
 
-	if (!(mpath->flags & MESH_PATH_RESOLVING))
+	if (!(mpath->flags & MESH_PATH_RESOLVING) &&
+	    mesh_path_sel_is_hwmp(sdata))
 		mesh_queue_preq(mpath, PREQ_Q_F_START);
 
 	if (skb_queue_len(&mpath->frame_queue) >= MESH_FRAME_QUEUE_LEN)
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-03-18 21:05 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <20200318205337.16279-1-sashal@kernel.org>
2020-03-18 20:53 ` [PATCH AUTOSEL 5.4 56/73] nl80211: add missing attribute validation for critical protocol indication Sasha Levin
2020-03-18 20:53 ` [PATCH AUTOSEL 5.4 57/73] nl80211: add missing attribute validation for beacon report scanning Sasha Levin
2020-03-18 20:53 ` [PATCH AUTOSEL 5.4 58/73] nl80211: add missing attribute validation for channel switch Sasha Levin
2020-03-18 20:53 ` [PATCH AUTOSEL 5.4 59/73] mac80211: Do not send mesh HWMP PREQ if HWMP is disabled Sasha Levin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).