From: Jouni Malinen Date: Wed, 24 Jul 2019 09:48:44 +0000 (+0300) Subject: Add missed wpa_akm_to_suite() selectors X-Git-Tag: hostap_2_9~63 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=43aafef8df29d309f6d4f6eca48e7053fb2b0b32;p=thirdparty%2Fhostap.git Add missed wpa_akm_to_suite() selectors These SAE, OWE, DPP, and OSEN AKM suite selectors were covered in the reverse conversion in rsn_key_mgmt_to_bitfield(), but were missing from wpa_akm_to_suite(). Add them to make AKM suite selector reporting more accurate in RADIUS Accounting messages (and future users of this function). Signed-off-by: Jouni Malinen --- diff --git a/src/common/wpa_common.c b/src/common/wpa_common.c index ed2d1c2a0..64e5c5f4c 100644 --- a/src/common/wpa_common.c +++ b/src/common/wpa_common.c @@ -2075,6 +2075,16 @@ u32 wpa_akm_to_suite(int akm) return RSN_AUTH_KEY_MGMT_FT_FILS_SHA256; if (akm & WPA_KEY_MGMT_FT_FILS_SHA384) return RSN_AUTH_KEY_MGMT_FT_FILS_SHA384; + if (akm & WPA_KEY_MGMT_SAE) + return RSN_AUTH_KEY_MGMT_SAE; + if (akm & WPA_KEY_MGMT_FT_SAE) + return RSN_AUTH_KEY_MGMT_FT_SAE; + if (akm & WPA_KEY_MGMT_OWE) + return RSN_AUTH_KEY_MGMT_OWE; + if (akm & WPA_KEY_MGMT_DPP) + return RSN_AUTH_KEY_MGMT_DPP; + if (akm & WPA_KEY_MGMT_OSEN) + return RSN_AUTH_KEY_MGMT_OSEN; return 0; }