From patchwork Mon Oct 11 12:16:36 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Crispin X-Patchwork-Id: 1539293 X-Patchwork-Delegate: blogic@openwrt.org Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=pass (2048-bit key; secure) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=bunOGEyy; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.openwrt.org (client-ip=2607:7c80:54:e::133; helo=bombadil.infradead.org; envelope-from=openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org; receiver=) Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4HSdBM3lh4z9sPf for ; Mon, 11 Oct 2021 23:18:51 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:To :From:Reply-To:Cc:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=Sr4Ja9U6HgkRz7n6nDYDaV7lYRmcixmsVsDCPl9PyZg=; b=bunOGEyyxmfLkA /RBzyePFdipeDnrR07vOPe8Bv4V0xO+XdLNyuCQ2mPc2HhvAXVJkkiMk4VJV0u1ZrJQrKb6GHtCc0 R7YIf1k9s5tb0rUAqDfy3BGVwTmVbGxevSxmnn9uT0tCH6rw3maEweRoWKH9pdUQgBoKWgTipoohR 1bMRDg0Joq/NnKWAjgM6LYhfUiPsmSEuWsKtbIsWeydn5l7+h41SlCaCLrFy5bn3hAQvu3CsEPFDi Fn0vfSaZ7D27zkqV7jSCF90WEk5HstFY0CkqxPmMWltRK7V06qPfrqnwPFUD3fYIVntaNC1OVYISS TA+mDaq+E+FSIrsUQ22w==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mZuEe-009I44-Dz; Mon, 11 Oct 2021 12:16:52 +0000 Received: from nbd.name ([2a01:4f8:221:3d45::2]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mZuER-009I17-9V for openwrt-devel@lists.openwrt.org; Mon, 11 Oct 2021 12:16:40 +0000 Received: from [2a04:4540:1402:3600:2d8:61ff:fef0:a7c3] (helo=localhost.localdomain) by ds12 with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.89) (envelope-from ) id 1mZuEO-0003wK-OC for openwrt-devel@lists.openwrt.org; Mon, 11 Oct 2021 14:16:36 +0200 From: John Crispin To: openwrt-devel@lists.openwrt.org Subject: [PATCH] netifd: fix wpa enterprise mode Date: Mon, 11 Oct 2021 14:16:36 +0200 Message-Id: <20211011121636.1537798-1-john@phrozen.org> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211011_051639_517227_EB83D94D X-CRM114-Status: UNSURE ( 6.68 ) X-CRM114-Notice: Please train this message. X-Spam-Score: 0.0 (/) X-Spam-Report: Spam detection software, running on the system "bombadil.infradead.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: Currently netifd only knows 2 wpa3/eap modes, wpa3 and wpa3-mixed. Accoring to the spec there are however 3 mode, wpa3, wpa3-192 and wpa3-mixed. In addition the mode currently called "incorrectly" set [...] Content analysis details: (0.0 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "openwrt-devel" Errors-To: openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org Currently netifd only knows 2 wpa3/eap modes, wpa3 and wpa3-mixed. Accoring to the spec there are however 3 mode, wpa3, wpa3-192 and wpa3-mixed. In addition the mode currently called "incorrectly" setups up wpa3-192 and there is no wpa3(-only) mode. Fix the handler script s.T. hostap.sh can then properly setup wpa3/eap. Tested-on: iPhone 12, Samsung S10/S20 Signed-off-by: John Crispin --- scripts/netifd-wireless.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/scripts/netifd-wireless.sh b/scripts/netifd-wireless.sh index 80fbf75..0ee95d9 100644 --- a/scripts/netifd-wireless.sh +++ b/scripts/netifd-wireless.sh @@ -252,11 +252,14 @@ wireless_vif_parse_encryption() { auth_type=owe ;; wpa3-mixed*) - auth_type=eap-eap192 + auth_type=eap-eap256 ;; - wpa3*) + wpa3-192*) auth_type=eap192 ;; + wpa3*) + auth_type=eap256 + ;; psk3-mixed*|sae-mixed*) auth_type=psk-sae ;;