linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: linux-wireless@vger.kernel.org
Cc: j@w1.fi, Larry.Finger@lwfinger.net,
	Johannes Berg <johannes.berg@intel.com>
Subject: [PATCH] cfg80211: fix station change if TDLS isn't supported
Date: Mon, 18 Feb 2013 15:02:29 +0100	[thread overview]
Message-ID: <1361196149-10731-1-git-send-email-johannes@sipsolutions.net> (raw)
In-Reply-To: <51207925.5040702@lwfinger.net>

From: Johannes Berg <johannes.berg@intel.com>

Larry noticed (and bisected) that commit df881293c6ba9a12868491a717b25
"cfg80211: Pass TDLS peer's QoS/HT/VHT information during set_station"
broke secure connections. This is is the case only for drivers that
don't support TDLS, where any kind of change, even just the change of
authorized flag that is required for normal operation, was rejected
now. To fix this, remove the checks. I have some patches that will add
proper verification for all the different cases later.

Cc: Jouni Malinen <j@w1.fi>
Bisected-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
---
 net/wireless/nl80211.c | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index 580ffea..d86af75 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -3423,14 +3423,6 @@ static int nl80211_set_station_tdls(struct genl_info *info,
 	struct nlattr *nla;
 	int err;
 
-	/* Can only set if TDLS ... */
-	if (!(rdev->wiphy.flags & WIPHY_FLAG_SUPPORTS_TDLS))
-		return -EOPNOTSUPP;
-
-	/* ... with external setup is supported */
-	if (!(rdev->wiphy.flags & WIPHY_FLAG_TDLS_EXTERNAL_SETUP))
-		return -EOPNOTSUPP;
-
 	/* Dummy STA entry gets updated once the peer capabilities are known */
 	if (info->attrs[NL80211_ATTR_HT_CAPABILITY])
 		params->ht_capa =
-- 
1.8.0


  parent reply	other threads:[~2013-02-18 14:02 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-02-17  6:31 Regression caused by commit df88129 Larry Finger
2013-02-17  8:32 ` Malinen, Jouni
2013-02-17 14:41 ` Malinen, Jouni
2013-02-17 21:21   ` Larry Finger
2013-02-18 14:01 ` Johannes Berg
2013-02-18 14:02 ` Johannes Berg [this message]
2013-02-18 17:24   ` [PATCH] cfg80211: fix station change if TDLS isn't supported Larry Finger
2013-02-18 17:25     ` Johannes Berg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1361196149-10731-1-git-send-email-johannes@sipsolutions.net \
    --to=johannes@sipsolutions.net \
    --cc=Larry.Finger@lwfinger.net \
    --cc=j@w1.fi \
    --cc=johannes.berg@intel.com \
    --cc=linux-wireless@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).