lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240716194826.GA85916@francesco-nb>
Date: Tue, 16 Jul 2024 21:48:26 +0200
From: Francesco Dolcini <francesco@...cini.it>
To: Sascha Hauer <s.hauer@...gutronix.de>
Cc: Brian Norris <briannorris@...omium.org>,
	Francesco Dolcini <francesco@...cini.it>,
	Kalle Valo <kvalo@...nel.org>, linux-wireless@...r.kernel.org,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/2] wifi: mwifiex: simplify WPA flags setting

Hello Sasha,
thanks for your patch.

On Tue, Jul 16, 2024 at 01:33:27PM +0200, Sascha Hauer wrote:
> The WPA flags setting only depends on the wpa_versions bitfield and not
> on the AKM suite, so move it out of the switch/case to simplify the code
> a bit. No functional change intended.
> 
> Signed-off-by: Sascha Hauer <s.hauer@...gutronix.de>

Reviewed-by: Francesco Dolcini <francesco.dolcini@...adex.com>

> ---
>  drivers/net/wireless/marvell/mwifiex/uap_cmd.c | 27 +++++++-------------------
>  1 file changed, 7 insertions(+), 20 deletions(-)
> 
> diff --git a/drivers/net/wireless/marvell/mwifiex/uap_cmd.c b/drivers/net/wireless/marvell/mwifiex/uap_cmd.c
> index 491e366119096..8d0cd84d27698 100644
> --- a/drivers/net/wireless/marvell/mwifiex/uap_cmd.c
> +++ b/drivers/net/wireless/marvell/mwifiex/uap_cmd.c
> @@ -46,31 +46,18 @@ int mwifiex_set_secure_params(struct mwifiex_private *priv,
>  
>  	bss_config->key_mgmt_operation |= KEY_MGMT_ON_HOST;
>  
> +	if (params->crypto.wpa_versions & NL80211_WPA_VERSION_1)
> +		bss_config->protocol = PROTOCOL_WPA;
> +	if (params->crypto.wpa_versions & NL80211_WPA_VERSION_2)
> +		bss_config->protocol |= PROTOCOL_WPA2;
> +

I am wondering what happens if NL80211_WPA_VERSION_1 is not set, no idea
what's the content of bss_config->protocol ...

in any case this is not something that you introduced, but maybe worth
having a look?

Francesco


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ