iPXE
|
An EAPOL-Key packet. More...
#include <wpa.h>
Data Fields | |
u8 | type |
One of the EAPOL_KEY_TYPE_* defines. More... | |
u16 | info |
Bitfield of key characteristics, network byte order. More... | |
u16 | keysize |
Length of encryption key to be used, network byte order. More... | |
u64 | replay |
Monotonically increasing value for EAPOL-Key conversations. More... | |
u8 | nonce [32] |
Nonce value. More... | |
u8 | iv [16] |
Initialization vector. More... | |
u8 | rsc [8] |
Receive sequence counter for GTK. More... | |
u8 | _reserved [8] |
Reserved bytes. More... | |
u8 | mic [16] |
Message integrity code over the entire EAPOL frame. More... | |
u16 | datalen |
Length of the data field in bytes, network byte order. More... | |
u8 | data [0] |
Key data. More... | |
An EAPOL-Key packet.
These are used for the WPA 4-Way Handshake, whether or not prior authentication has been performed using EAP.
On LANs, an eapol_key_pkt is always encapsulated in the data field of an eapol_frame, with the frame's type code set to EAPOL_TYPE_KEY.
Unlike 802.11 frame headers, the fields in this structure are stored in big-endian!
u8 eapol_key_pkt::type |
One of the EAPOL_KEY_TYPE_* defines.
Definition at line 107 of file wpa.h.
Referenced by eapol_key_rx().
u16 eapol_key_pkt::info |
Bitfield of key characteristics, network byte order.
Definition at line 110 of file wpa.h.
Referenced by eapol_key_rx(), wpa_handle_1_of_2(), wpa_handle_3_of_4(), wpa_send_2_of_4(), wpa_send_eapol(), and wpa_send_final().
u16 eapol_key_pkt::keysize |
Length of encryption key to be used, network byte order.
This is 16 for CCMP, 32 for TKIP, and 5 or 13 for WEP.
Definition at line 116 of file wpa.h.
Referenced by eapol_key_rx(), wpa_handle_3_of_4(), wpa_send_2_of_4(), wpa_send_eapol(), and wpa_send_final().
u64 eapol_key_pkt::replay |
Monotonically increasing value for EAPOL-Key conversations.
In another classic demonstration of overengineering, this 8-byte value will rarely be anything above 1. It's stored in network byte order.
Definition at line 124 of file wpa.h.
Referenced by eapol_key_rx(), and wpa_send_eapol().
u8 eapol_key_pkt::nonce[32] |
Nonce value.
This is the authenticator's ANonce in frame 1, the peer's SNonce in frame 2, and 0 in frames 3 and 4.
Definition at line 131 of file wpa.h.
Referenced by wpa_handle_1_of_4(), wpa_handle_3_of_4(), wpa_send_2_of_4(), and wpa_send_final().
u8 eapol_key_pkt::iv[16] |
Initialization vector.
This contains the IV used with the Key Encryption Key, or 0 if the key is unencrypted or encrypted using an algorithm that does not require an IV.
Definition at line 139 of file wpa.h.
Referenced by eapol_key_rx(), wpa_handle_1_of_2(), and wpa_send_final().
u8 eapol_key_pkt::rsc[8] |
Receive sequence counter for GTK.
This is used to synchronize the client's replay counter for ordinary data packets. The first six bytes contain PN0 through PN5 for CCMP mode, or TSC0 through TSC5 for TKIP mode. The last two bytes are zero.
Definition at line 148 of file wpa.h.
Referenced by wpa_handle_1_of_2(), and wpa_handle_3_of_4().
u8 eapol_key_pkt::mic[16] |
Message integrity code over the entire EAPOL frame.
This is calculated using HMAC-MD5 when the key descriptor version field in info is 1, and HMAC-SHA1 ignoring the last 4 bytes of the hash when the version field in info is 2.
Definition at line 160 of file wpa.h.
Referenced by eapol_key_rx(), and wpa_send_eapol().
u16 eapol_key_pkt::datalen |
Length of the data field in bytes, network byte order.
Definition at line 163 of file wpa.h.
Referenced by eapol_key_rx(), wpa_handle_1_of_2(), wpa_handle_3_of_4(), wpa_send_2_of_4(), wpa_send_eapol(), and wpa_send_final().
u8 eapol_key_pkt::data[0] |
Key data.
This is formatted as a series of 802.11 information elements, with cryptographic data encapsulated using a "vendor-specific IE" code and an IEEE-specified OUI.
Definition at line 171 of file wpa.h.
Referenced by eapol_key_rx(), wpa_handle_1_of_2(), and wpa_handle_3_of_4().