mirror of
https://github.com/vanhoefm/fragattacks.git
synced 2024-11-29 02:38:22 -05:00
WPA: Add more info for EAPOL-Key Nonce/MIC debugging
This commit is contained in:
parent
6c9a98a20d
commit
bc8318acbc
@ -736,6 +736,11 @@ void wpa_receive(struct wpa_authenticator *wpa_auth,
|
||||
}
|
||||
}
|
||||
|
||||
wpa_hexdump(MSG_DEBUG, "WPA: Received Key Nonce", key->key_nonce,
|
||||
WPA_NONCE_LEN);
|
||||
wpa_hexdump(MSG_DEBUG, "WPA: Received Replay Counter",
|
||||
key->replay_counter, WPA_REPLAY_COUNTER_LEN);
|
||||
|
||||
/* FIX: verify that the EAPOL-Key frame was encrypted if pairwise keys
|
||||
* are set */
|
||||
|
||||
@ -1510,6 +1515,8 @@ SM_STATE(WPA_PTK, AUTHENTICATION2)
|
||||
}
|
||||
|
||||
os_memcpy(sm->ANonce, sm->group->Counter, WPA_NONCE_LEN);
|
||||
wpa_hexdump(MSG_DEBUG, "WPA: Assign ANonce", sm->ANonce,
|
||||
WPA_NONCE_LEN);
|
||||
inc_byte_array(sm->group->Counter, WPA_NONCE_LEN);
|
||||
sm->ReAuthenticationRequest = FALSE;
|
||||
/* IEEE 802.11i does not clear TimeoutCtr here, but this is more
|
||||
|
@ -126,6 +126,8 @@ void wpa_pmk_to_ptk(const u8 *pmk, size_t pmk_len, const char *label,
|
||||
|
||||
wpa_printf(MSG_DEBUG, "WPA: PTK derivation - A1=" MACSTR " A2=" MACSTR,
|
||||
MAC2STR(addr1), MAC2STR(addr2));
|
||||
wpa_hexdump(MSG_DEBUG, "WPA: Nonce1", nonce1, WPA_NONCE_LEN);
|
||||
wpa_hexdump(MSG_DEBUG, "WPA: Nonce2", nonce2, WPA_NONCE_LEN);
|
||||
wpa_hexdump_key(MSG_DEBUG, "WPA: PMK", pmk, pmk_len);
|
||||
wpa_hexdump_key(MSG_DEBUG, "WPA: PTK", ptk, ptk_len);
|
||||
}
|
||||
|
@ -65,6 +65,8 @@ void wpa_eapol_key_send(struct wpa_sm *sm, const u8 *kck,
|
||||
"version %d MIC", ver);
|
||||
goto out;
|
||||
}
|
||||
wpa_hexdump_key(MSG_DEBUG, "WPA: KCK", kck, 16);
|
||||
wpa_hexdump(MSG_DEBUG, "WPA: Derived Key MIC", key_mic, 16);
|
||||
wpa_hexdump(MSG_MSGDUMP, "WPA: TX EAPOL-Key", msg, msg_len);
|
||||
wpa_sm_ether_send(sm, dest, proto, msg, msg_len);
|
||||
eapol_sm_notify_tx_eapol_key(sm->eapol);
|
||||
@ -322,6 +324,8 @@ int wpa_supplicant_send_2_of_4(struct wpa_sm *sm, const unsigned char *dst,
|
||||
os_memcpy(reply->key_length, key->key_length, 2);
|
||||
os_memcpy(reply->replay_counter, key->replay_counter,
|
||||
WPA_REPLAY_COUNTER_LEN);
|
||||
wpa_hexdump(MSG_DEBUG, "WPA: Replay Counter", reply->replay_counter,
|
||||
WPA_REPLAY_COUNTER_LEN);
|
||||
|
||||
WPA_PUT_BE16(reply->key_data_length, wpa_ie_len);
|
||||
os_memcpy(reply + 1, wpa_ie, wpa_ie_len);
|
||||
|
Loading…
Reference in New Issue
Block a user