/hostap-latest/src/common/ |
D | dpp_crypto.c | 391 u8 salt[DPP_MAX_HASH_LEN], prk[DPP_MAX_HASH_LEN]; in dpp_derive_k1() local 399 if (dpp_hmac(hash_len, salt, hash_len, Mx, Mx_len, prk) < 0) in dpp_derive_k1() 402 prk, hash_len); in dpp_derive_k1() 405 res = dpp_hkdf_expand(hash_len, prk, hash_len, info, k1, hash_len); in dpp_derive_k1() 406 os_memset(prk, 0, hash_len); in dpp_derive_k1() 418 u8 salt[DPP_MAX_HASH_LEN], prk[DPP_MAX_HASH_LEN]; in dpp_derive_k2() local 426 res = dpp_hmac(hash_len, salt, hash_len, Nx, Nx_len, prk); in dpp_derive_k2() 430 prk, hash_len); in dpp_derive_k2() 433 res = dpp_hkdf_expand(hash_len, prk, hash_len, info, k2, hash_len); in dpp_derive_k2() 434 os_memset(prk, 0, hash_len); in dpp_derive_k2() [all …]
|
D | sae.c | 544 u8 *prk) in hkdf_extract() argument 548 prk); in hkdf_extract() 552 prk); in hkdf_extract() 557 prk); in hkdf_extract() 563 static int hkdf_expand(size_t hash_len, const u8 *prk, size_t prk_len, in hkdf_expand() argument 569 return hmac_sha256_kdf(prk, prk_len, NULL, in hkdf_expand() 574 return hmac_sha384_kdf(prk, prk_len, NULL, in hkdf_expand() 580 return hmac_sha512_kdf(prk, prk_len, NULL, in hkdf_expand()
|
/hostap-latest/src/crypto/ |
D | crypto_module_tests.c | 2066 u8 prk[SHA256_MAC_LEN]; in test_extract_expand_hkdf() local 2158 if (hmac_sha256(salt1, sizeof(salt1), ikm1, sizeof(ikm1), prk) < 0) in test_extract_expand_hkdf() 2160 if (os_memcmp(prk, prk1, SHA256_MAC_LEN) != 0) { in test_extract_expand_hkdf() 2173 if (hmac_sha256(salt2, sizeof(salt2), ikm2, sizeof(ikm2), prk) < 0) in test_extract_expand_hkdf() 2175 if (os_memcmp(prk, prk2, SHA256_MAC_LEN) != 0) { in test_extract_expand_hkdf()
|
D | crypto_openssl.c | 4753 const u8 *ikm, size_t ikm_len, u8 *prk) in hpke_labeled_extract() argument 4806 res = EVP_MAC_final(hctx, prk, &mlen, mdlen); in hpke_labeled_extract() 4827 res = HMAC_Final(hctx, prk, &mdlen); in hpke_labeled_extract() 4837 hpke_labeled_expand(struct hpke_context *ctx, bool kem, const u8 *prk, in hpke_labeled_expand() argument 4905 if (EVP_MAC_init(hctx, prk, mdlen, params) != 1) in hpke_labeled_expand() 4921 if (HMAC_Init_ex(hctx, prk, mdlen, in hpke_labeled_expand()
|
D | crypto_mbedtls_alt.c | 481 __attribute_noinline__ static int hmac_kdf_expand(const u8 *prk, in hmac_kdf_expand() argument 495 return mbedtls_hkdf_expand(md_info, prk, prk_len, info, info_len, okm, okm_len) ? -1 : 0; in hmac_kdf_expand() 509 mbedtls_md_hmac_starts(&ctx, prk, prk_len); in hmac_kdf_expand()
|
/hostap-latest/src/rsn_supp/ |
D | wpa.c | 6864 u8 prk[SHA512_MAC_LEN], pmkid[SHA512_MAC_LEN]; in owe_process_assoc_resp() local 6973 wpabuf_head(secret), wpabuf_len(secret), prk); in owe_process_assoc_resp() 6976 wpabuf_head(secret), wpabuf_len(secret), prk); in owe_process_assoc_resp() 6979 wpabuf_head(secret), wpabuf_len(secret), prk); in owe_process_assoc_resp() 6985 wpa_hexdump_key(MSG_DEBUG, "OWE: prk", prk, hash_len); in owe_process_assoc_resp() 6990 res = hmac_sha256_kdf(prk, hash_len, NULL, (const u8 *) info, in owe_process_assoc_resp() 6993 res = hmac_sha384_kdf(prk, hash_len, NULL, (const u8 *) info, in owe_process_assoc_resp() 6996 res = hmac_sha512_kdf(prk, hash_len, NULL, (const u8 *) info, in owe_process_assoc_resp() 6998 forced_memzero(prk, SHA512_MAC_LEN); in owe_process_assoc_resp()
|
/hostap-latest/src/ap/ |
D | ieee802_11.c | 3620 u8 prk[SHA512_MAC_LEN], pmkid[SHA512_MAC_LEN]; in owe_process_assoc_req() local 3721 wpabuf_head(secret), wpabuf_len(secret), prk); in owe_process_assoc_req() 3724 wpabuf_head(secret), wpabuf_len(secret), prk); in owe_process_assoc_req() 3727 wpabuf_head(secret), wpabuf_len(secret), prk); in owe_process_assoc_req() 3733 wpa_hexdump_key(MSG_DEBUG, "OWE: prk", prk, hash_len); in owe_process_assoc_req() 3740 os_memset(prk, 0, SHA512_MAC_LEN); in owe_process_assoc_req() 3745 res = hmac_sha256_kdf(prk, hash_len, NULL, (const u8 *) info, in owe_process_assoc_req() 3748 res = hmac_sha384_kdf(prk, hash_len, NULL, (const u8 *) info, in owe_process_assoc_req() 3751 res = hmac_sha512_kdf(prk, hash_len, NULL, (const u8 *) info, in owe_process_assoc_req() 3753 os_memset(prk, 0, SHA512_MAC_LEN); in owe_process_assoc_req()
|