]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
mesh: Fix AEK derivation to use AKM suite selector
authorJouni Malinen <j@w1.fi>
Sat, 18 Jun 2016 11:17:34 +0000 (14:17 +0300)
committerJouni Malinen <j@w1.fi>
Sat, 18 Jun 2016 12:53:22 +0000 (15:53 +0300)
mesh_rsn_derive_aek() was hardcoded to use GCMP (even though CCMP was
hardcoded elsewhere) cipher suite selector instead of the selected AKM
suite selector. This resulted in incorrect AEK getting derived. Fix this
by used the SAE AKM suite selector in the input to the KDF.

Signed-off-by: Jouni Malinen <j@w1.fi>
wpa_supplicant/mesh_rsn.c

index 4dadc4049c034350d17d53722f58daeda775b6e8..57e5b159d99e6824dbb927c405fece68100345d1 100644 (file)
@@ -366,8 +366,8 @@ mesh_rsn_derive_aek(struct mesh_rsn *rsn, struct sta_info *sta)
        u8 *addr1 = peer, *addr2 = myaddr;
        u8 context[AES_BLOCK_SIZE];
 
-       /* SAE */
-       RSN_SELECTOR_PUT(context, wpa_cipher_to_suite(0, WPA_CIPHER_GCMP));
+       /* Selected AKM Suite: SAE */
+       RSN_SELECTOR_PUT(context, RSN_AUTH_KEY_MGMT_SAE);
 
        if (os_memcmp(myaddr, peer, ETH_ALEN) < 0) {
                addr1 = myaddr;