From nobody Thu Jun 5 14:34:09 2025 X-Original-To: dev-commits-src-main@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 4bCn5G6065z5xvZK; Thu, 05 Jun 2025 14:34:10 +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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4bCn5G1MVsz3X8N; Thu, 05 Jun 2025 14:34:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1749134050; 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=cj9mqFtjmVUSw9hqweUy6HIkQ8+Ib46AN3DbepecaFk=; b=jOfpT98BEwooj5jZZmPUMeQDBbtjlRpP6hm1gnG9OZQQz4QEj9fb/A3ghWS9zOxZ2Dgfyn j+bMnn0J2zOc+5zg4gdzBdgjuZoWUOeIHibtQVDIdfns6xHX6yOM5Agwo8/4LB53K4oSOH os+Z2XkflG3WKRQ8Lpt5neXT+DACbhCoYegqA4dJH/MHzHCGZ6Q2C7ROps72dm/s9XQYYJ otrcV7oy1gB0emmrgToNPjC1rpmwFnlzK5EeVGG16uSg58SZbXEXR5ajMLjq4iQGBb55yy 70FCqWpiMeSKhz73NbfT8SzIPWu2nY3oqnJrX5nPUWQbPRRNSICPOH9BzNCAEg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1749134050; 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=cj9mqFtjmVUSw9hqweUy6HIkQ8+Ib46AN3DbepecaFk=; b=PdX/bzh8nOrDtkASYAnNptsbfnogKB4FPgFQuQgsjojglWEddsfVHe0kt0aga5p0bRYvH6 7SIDcmZ1pO4rn04B+5GS4wH761Q2HZLRQ0lFQFu1xXHqMzj8+2xOy6W/GRdcQYm+ym9mkH 3tVByeFlZTdb94/IN476zCim1eiwXvHetqktwOvwYrUun+i0mZ+cnVHOFIocvjiWSDdTMY ciF2+mwKTxWewMubCk+ORemzWArHh+WBUnNHkSlarwAeunp5fm/ZNP+bq78gL1WhstA+8w OqgXB/0ZFctZFm6hbiYAUF8NIue+8/TVsiMh/7VoAJwxukN8GYiK2xrlig42yQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1749134050; a=rsa-sha256; cv=none; b=tpcQdU1UmeRCZuubPRpcNWmgIfd5LVACXcLMR54tExYRBlem3FcKdxOFYWUEm2dq+KazNQ QzDfmdzr3MJO9RVJfA2+a/yFaeT2Tb3zjd4B3cKxIJF5L0C9THRMN8BJW4wR7qVXOSqKZu lo5DclqEW0xnuRuGWWBFbdSf6HUEqKes0ldX++6FmBtzoObJOX6A52ATp3iazRDlWabZMw exfiNsxz9+uX6e1fYT7VzRM4whR/We7Hn71TYctrxTVdjfMQPjfyQvSCoZoVmmm0zmgga7 rf3TIxLsa3QcrfJfLYtFobX9xaDl/vCYyuBGTGx/gcg3vJ63WKWLMDkB0KvPpQ== 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 4bCn5G0Wwzz1CBF; Thu, 05 Jun 2025 14:34:10 +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 555EY9C7056771; Thu, 5 Jun 2025 14:34:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 555EY9YT056768; Thu, 5 Jun 2025 14:34:09 GMT (envelope-from git) Date: Thu, 5 Jun 2025 14:34:09 GMT Message-Id: <202506051434.555EY9YT056768@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: aaee0ed3d163 - main - LinuxKPI: 802.11: WEP noise List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: bz X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: aaee0ed3d163a1d29ea74d7e4d2c3658a51cfb27 Auto-Submitted: auto-generated The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=aaee0ed3d163a1d29ea74d7e4d2c3658a51cfb27 commit aaee0ed3d163a1d29ea74d7e4d2c3658a51cfb27 Author: Bjoern A. Zeeb AuthorDate: 2025-06-05 11:11:49 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-06-05 11:32:27 +0000 LinuxKPI: 802.11: WEP noise While we decided that we will not provide WEP support for the LinuxKPI 802.11 compat code, some of it is in there already (also because drivers still support it). Put proper keylen checks in place as net80211 only knows about WEP while LinuxKPI has WEP40 and WEP104. Sponsored by: The FreeBSD Foundation MFC after: 3 days --- sys/compat/linuxkpi/common/src/linux_80211.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/sys/compat/linuxkpi/common/src/linux_80211.c b/sys/compat/linuxkpi/common/src/linux_80211.c index 2f9af39391f6..7520ed7331be 100644 --- a/sys/compat/linuxkpi/common/src/linux_80211.c +++ b/sys/compat/linuxkpi/common/src/linux_80211.c @@ -1064,10 +1064,15 @@ lkpi_net80211_to_l80211_cipher_suite(uint32_t cipher, uint8_t keylen) switch (cipher) { case IEEE80211_CIPHER_WEP: - if (keylen < 8) + if (keylen == (40/NBBY)) return (WLAN_CIPHER_SUITE_WEP40); - else + else if (keylen == (104/NBBY)) return (WLAN_CIPHER_SUITE_WEP104); + else { + printf("%s: WEP with unsupported keylen %d\n", + __func__, keylen * NBBY); + return (0); + } break; case IEEE80211_CIPHER_TKIP: return (WLAN_CIPHER_SUITE_TKIP);