aboutsummaryrefslogtreecommitdiffstats
path: root/src/common/wpa_common.h
diff options
context:
space:
mode:
authorJouni Malinen <jouni@qca.qualcomm.com>2015-09-02 19:55:03 (GMT)
committerJouni Malinen <j@w1.fi>2016-10-10 18:11:46 (GMT)
commit6d014ffc6e654e7e802263c55ce568df153a1e1c (patch)
tree4c73dfdd2e159d506420c43ec228a31a0ec656a8 /src/common/wpa_common.h
parent94f66e8a26df9144d5bc33fe49d29fa222f047ef (diff)
downloadhostap-6d014ffc6e654e7e802263c55ce568df153a1e1c.zip
hostap-6d014ffc6e654e7e802263c55ce568df153a1e1c.tar.gz
hostap-6d014ffc6e654e7e802263c55ce568df153a1e1c.tar.bz2
Make struct wpa_eapol_key easier to use with variable length MIC
Suite B 192-bit addition from IEEE Std 802.11ac-2013 replaced the previous fixed length Key MIC field with a variable length field. That change was addressed with an addition of a new struct defined for the second MIC length. This is not really scalable and with FILS coming up with a zero-length MIC case for AEAD, a more thorough change to support variable length MIC is needed. Remove the Key MIC and Key Data Length fields from the struct wpa_eapol_key and find their location based on the MIC length information (which is determined by the AKMP). This change allows the separate struct wpa_eapol_key_192 to be removed since struct wpa_eapol_key will now include only the fixed length fields that are shared with all EAPOL-Key cases in IEEE Std 802.11. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
Diffstat (limited to 'src/common/wpa_common.h')
-rw-r--r--src/common/wpa_common.h21
1 files changed, 3 insertions, 18 deletions
diff --git a/src/common/wpa_common.h b/src/common/wpa_common.h
index ea8f759..cff404f 100644
--- a/src/common/wpa_common.h
+++ b/src/common/wpa_common.h
@@ -183,24 +183,9 @@ struct wpa_eapol_key {
u8 key_iv[16];
u8 key_rsc[WPA_KEY_RSC_LEN];
u8 key_id[8]; /* Reserved in IEEE 802.11i/RSN */
- u8 key_mic[16];
- u8 key_data_length[2]; /* big endian */
- /* followed by key_data_length bytes of key_data */
-} STRUCT_PACKED;
-
-struct wpa_eapol_key_192 {
- u8 type;
- /* Note: key_info, key_length, and key_data_length are unaligned */
- u8 key_info[2]; /* big endian */
- u8 key_length[2]; /* big endian */
- u8 replay_counter[WPA_REPLAY_COUNTER_LEN];
- u8 key_nonce[WPA_NONCE_LEN];
- u8 key_iv[16];
- u8 key_rsc[WPA_KEY_RSC_LEN];
- u8 key_id[8]; /* Reserved in IEEE 802.11i/RSN */
- u8 key_mic[24];
- u8 key_data_length[2]; /* big endian */
- /* followed by key_data_length bytes of key_data */
+ /* variable length Key MIC field */
+ /* big endian 2-octet Key Data Length field */
+ /* followed by Key Data Length bytes of Key Data */
} STRUCT_PACKED;
#define WPA_EAPOL_KEY_MIC_MAX_LEN 24