From nobody Sun Nov 17 18:07:43 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4XrzHz522Gz5dDCP; Sun, 17 Nov 2024 18:07:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (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 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4XrzHz4Sqsz4l4C; Sun, 17 Nov 2024 18:07:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1731866863; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JFfvXcIw6ONOr5AcpbRCyI+54WLKmt5hWFGIUysOVIw=; b=h+vJdARjXuNVlZC7xjPRzcnyjxSLeMbg/8isIM6XLocR9fdgB6hveWR2a4WzFbKJVztbMp Zx7GP1BQKLC7OAlMrW3EFFxwYK6wckyGLqhVben/S0xIa+NuG2kZ/cvmtabXTg/pathlKn YsigTgYFwpuOl6MsTLSSAfcrnB2EoBV7c0EmqSZX/h/n1G6Nggjc0C59ozBntxRAlqBoVJ mqh/cWNU6z7BzVIFlT6qcV23GQd43rE0S419PgcfmIW3NluXPgz47Vc8jauNkJYK4Yfyil frB5l6/NqQpV421LIuWqgF3E98wcTsOeNVIulAzxwYMHeoi1cKQmBMIZA64kvA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1731866863; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=JFfvXcIw6ONOr5AcpbRCyI+54WLKmt5hWFGIUysOVIw=; b=LMBdiHAdEr4IYhCuSEx4akAeZIOhF+sTcptzqg5E4s0SocNV7Yni8RQE1hJh/q/oy2pAGL YWUo1KYcZt7jl2khLnJCCQf6zgCxYXEwj/x/nqUdV9fi9+KgI6V1BItAND2L/1L2cSLI1q OlD7BmN8Y52l7W0C1V13e0BGpXc8pfDJ4JKQFlOplThebCAzX4dFhoh9rTe31/9V13gTIr Ivy5WswSIN1pTb0tv+8HAoudlQYpmlVXblz1RNyxG13zEy04XMLiOWr/xon4yuzWH/jZRn yxl+NVxZcYKCO0/re0M1jADMbLzSydVOFMPZdZXNrwUsGZs66IkPwVKxifeAzA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1731866863; a=rsa-sha256; cv=none; b=iLA8oXhTJ1KW37vbUSPqQrdr/rLPkJEkv28wZ2/aVx/lnZeIYfj53hGelPy99zmz4s0CzB 06nXg4q2zAM/EiswQdZjr8UNVjyQMVbTZYghlBcxA31U9yjBNNLmD9wJ/XhYOSm6y5i0Vp vjXN7M6LXy0VNR7YJBAEqqkFmu9Phs2sR8o33vFpy2CXwDeO/zjFufFix5Sa/7312v3pHA 0ZXtoAd1qpK3XFKaeX7logeJOxyyRLbO8/BoLhvQLWKabNZdpuzjMBdDTfgvDFlZvpYzbJ b8zW/TNy+OsD7GKY2powLWZd/oYT/jaVe8OWHqr9XltIyXbhezdCkXWShgnXFQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (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) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4XrzHz42hXz12qB; Sun, 17 Nov 2024 18:07:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 4AHI7hYq079517; Sun, 17 Nov 2024 18:07:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4AHI7hIW079514; Sun, 17 Nov 2024 18:07:43 GMT (envelope-from git) Date: Sun, 17 Nov 2024 18:07:43 GMT Message-Id: <202411171807.4AHI7hIW079514@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Adrian Chadd Subject: git: 8b51df0d4fad - main - wpa: add support for GCMP-128 and BIP-128. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: adrian X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8b51df0d4fadd2cec40b88b43b7aa5aaf95c7510 Auto-Submitted: auto-generated The branch main has been updated by adrian: URL: https://cgit.FreeBSD.org/src/commit/?id=8b51df0d4fadd2cec40b88b43b7aa5aaf95c7510 commit 8b51df0d4fadd2cec40b88b43b7aa5aaf95c7510 Author: Adrian Chadd AuthorDate: 2024-08-31 16:43:22 +0000 Commit: Adrian Chadd CommitDate: 2024-11-17 18:04:58 +0000 wpa: add support for GCMP-128 and BIP-128. If net80211 announces support for GCMP and/or BIP then configure it appropriately. GCMP will be used by WPA3 in the future, and BIP is required for 802.11w/MFP (which is also required by WPA3.) Differential Revision: https://reviews.freebsd.org/D46499 --- contrib/wpa/src/drivers/driver_bsd.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/contrib/wpa/src/drivers/driver_bsd.c b/contrib/wpa/src/drivers/driver_bsd.c index 1d864e5ceb97..712446a62fe4 100644 --- a/contrib/wpa/src/drivers/driver_bsd.c +++ b/contrib/wpa/src/drivers/driver_bsd.c @@ -378,6 +378,12 @@ bsd_set_key(void *priv, struct wpa_driver_set_key_params *params) case WPA_ALG_CCMP: wk.ik_type = IEEE80211_CIPHER_AES_CCM; break; + case WPA_ALG_GCMP: + wk.ik_type = IEEE80211_CIPHER_AES_GCM_128; + break; + case WPA_ALG_BIP_CMAC_128: + wk.ik_type = IEEE80211_CIPHER_BIP_CMAC_128; + break; default: wpa_printf(MSG_ERROR, "%s: unknown alg=%d", __func__, alg); return -1; @@ -449,6 +455,12 @@ bsd_configure_wpa(void *priv, struct wpa_bss_params *params) case WPA_CIPHER_CCMP: v = IEEE80211_CIPHER_AES_CCM; break; + case WPA_CIPHER_GCMP: + v = IEEE80211_CIPHER_AES_GCM_128; + break; + case WPA_CIPHER_BIP_CMAC_128: + v = IEEE80211_CIPHER_BIP_CMAC_128; + break; case WPA_CIPHER_TKIP: v = IEEE80211_CIPHER_TKIP; break; @@ -485,6 +497,10 @@ bsd_configure_wpa(void *priv, struct wpa_bss_params *params) } v = 0; + if (params->wpa_pairwise & WPA_CIPHER_BIP_CMAC_128) + v |= 1<wpa_pairwise & WPA_CIPHER_GCMP) + v |= 1<wpa_pairwise & WPA_CIPHER_CCMP) v |= 1<wpa_pairwise & WPA_CIPHER_TKIP) @@ -1567,6 +1583,10 @@ static int wpa_driver_bsd_capa(struct bsd_driver_data *drv) drv->capa.enc |= WPA_DRIVER_CAPA_ENC_TKIP; if (devcaps.dc_cryptocaps & IEEE80211_CRYPTO_AES_CCM) drv->capa.enc |= WPA_DRIVER_CAPA_ENC_CCMP; + if (devcaps.dc_cryptocaps & IEEE80211_CRYPTO_AES_GCM_128) + drv->capa.enc |= WPA_DRIVER_CAPA_ENC_GCMP; + if (devcaps.dc_cryptocaps & IEEE80211_CRYPTO_BIP_CMAC_128) + drv->capa.enc |= WPA_DRIVER_CAPA_ENC_BIP; if (devcaps.dc_drivercaps & IEEE80211_C_HOSTAP) drv->capa.flags |= WPA_DRIVER_FLAGS_AP;