handshake: store PMK length

Non-802.11 AKMs can define their own key lengths. Currently only OWE does
this, and the MIC/KEK/KCK lengths will be determined by the PMK length so
we need to save it.
This commit is contained in:
James Prestwood 2019-01-14 12:54:17 -08:00 committed by Denis Kenzior
parent f87159964c
commit 8e7da821f9
2 changed files with 2 additions and 0 deletions

View File

@ -108,6 +108,7 @@ void handshake_state_set_pmk(struct handshake_state *s, const uint8_t *pmk,
size_t pmk_len)
{
memcpy(s->pmk, pmk, pmk_len);
s->pmk_len = pmk_len;
s->have_pmk = true;
}

View File

@ -87,6 +87,7 @@ struct handshake_state {
enum ie_rsn_cipher_suite group_management_cipher;
enum ie_rsn_akm_suite akm_suite;
uint8_t pmk[64];
size_t pmk_len;
uint8_t snonce[32];
uint8_t anonce[32];
uint8_t ptk[64];