From patchwork Fri Dec 22 16:33:38 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jouni Malinen X-Patchwork-Id: 10130923 X-Patchwork-Delegate: johannes@sipsolutions.net Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 9FDCF6019C for ; Fri, 22 Dec 2017 16:34:27 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A1B4720950 for ; Fri, 22 Dec 2017 16:34:27 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 960B729DB3; Fri, 22 Dec 2017 16:34:27 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id EAEC020950 for ; Fri, 22 Dec 2017 16:34:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756037AbdLVQeZ (ORCPT ); Fri, 22 Dec 2017 11:34:25 -0500 Received: from alexa-out.qualcomm.com ([129.46.98.28]:28818 "EHLO alexa-out.qualcomm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752871AbdLVQeY (ORCPT ); Fri, 22 Dec 2017 11:34:24 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=qca.qualcomm.com; i=@qca.qualcomm.com; q=dns/txt; s=qcdkim; t=1513960464; x=1545496464; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version; bh=MSHvLyQrJ0qycLjedf1ct/EVmK1TYiO+pIAhtSRiebg=; b=wj+atXZDQ0KLma/H8fTTC5eyaXI/0NwOXhF2ymTdlkR4BpBLkLhnIUUy PXIHavxLmXGLfFbhaiwOeTj+pvntPdOKdscyb0mlHDI7kl+eqScSG4S1S sfs8jfpuxNSqapsScrq1Ldncsaewjr5KHQRPXjAXBqEk+JvVFQNK9lFJn o=; Received: from ironmsg02-r-new.qualcomm.com (HELO ironmsg02-R.qualcomm.com) ([10.53.140.106]) by alexa-out.qualcomm.com with ESMTP; 22 Dec 2017 08:34:24 -0800 X-IronPort-AV: E=McAfee;i="5900,7806,8753"; a="1092237016" X-MGA-submission: =?us-ascii?q?MDHQIgTkkIRo3ezLBk1ylHfFQrTUp8dvjH+JBB?= =?us-ascii?q?a/AnlwgZjGocZsg9TxQcSijLUH3gUNFwOeGgHopPOvH/b+UuS5h5dxV+?= =?us-ascii?q?9qgD/nWiXYN6S1R88yIyooFTjRjAOW9ALy2HX2dZcJf2xkU/JpMNggq/?= =?us-ascii?q?dt?= Received: from nasanexm03a.na.qualcomm.com ([10.85.0.103]) by ironmsg02-R.qualcomm.com with ESMTP/TLS/AES256-SHA; 22 Dec 2017 08:34:23 -0800 Received: from euamsexm01e.eu.qualcomm.com (10.251.127.42) by nasanexm03a.na.qualcomm.com (10.85.0.103) with Microsoft SMTP Server (TLS) id 15.0.1293.2; Fri, 22 Dec 2017 08:34:23 -0800 Received: from jouni.qca.qualcomm.com (10.80.80.8) by euamsexm01e.eu.qualcomm.com (10.251.127.42) with Microsoft SMTP Server (TLS) id 15.0.1293.2; Fri, 22 Dec 2017 17:34:17 +0100 From: Jouni Malinen To: Johannes Berg CC: , Srinivas Dasari , Jouni Malinen Subject: [PATCH v2 2/3] nl80211: Allow SAE Authentication for NL80211_CMD_CONNECT Date: Fri, 22 Dec 2017 18:33:38 +0200 Message-ID: <1513960419-24780-2-git-send-email-jouni@qca.qualcomm.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1513960419-24780-1-git-send-email-jouni@qca.qualcomm.com> References: <1513960419-24780-1-git-send-email-jouni@qca.qualcomm.com> MIME-Version: 1.0 X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: NASANEXM01C.na.qualcomm.com (10.85.0.83) To euamsexm01e.eu.qualcomm.com (10.251.127.42) Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Srinivas Dasari This commit allows SAE Authentication for NL80211_CMD_CONNECT interface, provided this is supported by the host driver. Signed-off-by: Srinivas Dasari Signed-off-by: Jouni Malinen --- net/wireless/nl80211.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) v2: - no changes; just rebased and included in the full patch series diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c index 41a0373..ea36514 100644 --- a/net/wireless/nl80211.c +++ b/net/wireless/nl80211.c @@ -3917,7 +3917,8 @@ static bool nl80211_valid_auth_type(struct cfg80211_registered_device *rdev, return true; case NL80211_CMD_CONNECT: /* SAE not supported yet */ - if (auth_type == NL80211_AUTHTYPE_SAE) + if (!(rdev->wiphy.features & NL80211_FEATURE_SAE) && + auth_type == NL80211_AUTHTYPE_SAE) return false; /* FILS with SK PFS or PK not supported yet */ if (auth_type == NL80211_AUTHTYPE_FILS_SK_PFS ||