Lines Matching defs:pmk
47 const u8 *pmk, unsigned int pmk_len,
449 wpa_printf(MSG_ERROR, "FT PMK cache initialization failed.");
830 const u8 *pmk = NULL;
835 pmk = wpa_auth_get_psk(sm->wpa_auth, sm->addr,
836 sm->p2p_dev_addr, pmk);
837 if (pmk == NULL)
841 pmk = sm->PMK;
845 wpa_derive_ptk(sm, sm->alt_SNonce, pmk, pmk_len, &PTK);
1911 wpa_printf(MSG_DEBUG, "WPA: PMK from PMKSA cache");
1912 os_memcpy(sm->PMK, sm->pmksa->pmk, sm->pmksa->pmk_len);
1921 wpa_printf(MSG_DEBUG, "WPA: PMK from EAPOL state machine "
1922 "(MSK len=%lu PMK len=%u)", (unsigned long) len,
1926 "WPA: MSK not long enough (%u) to create PMK (%u)",
1931 os_memcpy(sm->PMK, msk, pmk_len);
1940 wpa_printf(MSG_DEBUG, "WPA: Could not get PMK, get_msk: %p",
1952 * state and takes PMK from the previously used AAA Key. This will
1953 * eventually fail in 4-Way Handshake because Supplicant uses PMK
1966 os_memcpy(sm->PMK, psk, PMK_LEN);
2019 rsn_pmkid(sm->PMK, sm->pmk_len, sm->wpa_auth->addr,
2031 const u8 *pmk, unsigned int pmk_len,
2036 return wpa_auth_derive_ptk_ft(sm, pmk, ptk);
2039 return wpa_pmk_to_ptk(pmk, pmk_len, "Pairwise key expansion",
2049 const u8 *pmk = NULL;
2056 /* WPA with IEEE 802.1X: use the derived PMK from EAP
2061 pmk = wpa_auth_get_psk(sm->wpa_auth, sm->addr,
2062 sm->p2p_dev_addr, pmk);
2063 if (pmk == NULL)
2068 pmk = sm->PMK;
2072 wpa_derive_ptk(sm, sm->SNonce, pmk, pmk_len, &PTK);
2121 os_memcpy(sm->PMK, pmk, PMK_LEN);
3286 int wpa_auth_pmksa_add(struct wpa_state_machine *sm, const u8 *pmk,
3301 if (pmksa_cache_auth_add(sm->wpa_auth->pmksa, pmk, pmk_len, NULL,
3312 const u8 *pmk, size_t len, const u8 *sta_addr,
3319 if (pmksa_cache_auth_add(wpa_auth->pmksa, pmk, len, NULL,
3331 const u8 *pmk, const u8 *pmkid)
3336 if (pmksa_cache_auth_add(wpa_auth->pmksa, pmk, PMK_LEN, pmkid,
3390 u8 *pmkid, u8 *pmk)
3396 os_memcpy(pmk, pmksa->pmk, PMK_LEN);