/external/wpa_supplicant_8/src/common/ |
D | dpp_crypto.c | 103 if (curve->hash_len == 32) in dpp_hash_vector() 105 if (curve->hash_len == 48) in dpp_hash_vector() 107 if (curve->hash_len == 64) in dpp_hash_vector() 113 int dpp_hkdf_expand(size_t hash_len, const u8 *secret, size_t secret_len, in dpp_hkdf_expand() argument 116 if (hash_len == 32) in dpp_hkdf_expand() 120 if (hash_len == 48) in dpp_hkdf_expand() 124 if (hash_len == 64) in dpp_hkdf_expand() 132 int dpp_hmac_vector(size_t hash_len, const u8 *key, size_t key_len, in dpp_hmac_vector() argument 136 if (hash_len == 32) in dpp_hmac_vector() 139 if (hash_len == 48) in dpp_hmac_vector() [all …]
|
D | sae.c | 533 static int hkdf_extract(size_t hash_len, const u8 *salt, size_t salt_len, in hkdf_extract() argument 537 if (hash_len == 32) in hkdf_extract() 541 if (hash_len == 48) in hkdf_extract() 546 if (hash_len == 64) in hkdf_extract() 554 static int hkdf_expand(size_t hash_len, const u8 *prk, size_t prk_len, in hkdf_expand() argument 559 if (hash_len == 32) in hkdf_expand() 564 if (hash_len == 48) in hkdf_expand() 570 if (hash_len == 64) in hkdf_expand() 822 static int sae_pwd_seed(size_t hash_len, const u8 *ssid, size_t ssid_len, in sae_pwd_seed() argument 844 if (hkdf_extract(hash_len, ssid, ssid_len, num_elem, addr, len, in sae_pwd_seed() [all …]
|
D | sae_pk.c | 529 int sae_hash(size_t hash_len, const u8 *data, size_t len, u8 *hash) in sae_hash() argument 531 if (hash_len == 32) in sae_hash() 534 if (hash_len == 48) in sae_hash() 538 if (hash_len == 64) in sae_hash() 545 static int sae_pk_hash_sig_data(struct sae_data *sae, size_t hash_len, in sae_pk_hash_sig_data() argument 587 if (sae_hash(hash_len, wpabuf_head(sig_data), wpabuf_len(sig_data), in sae_pk_hash_sig_data() 591 hash, hash_len); in sae_pk_hash_sig_data() 609 size_t hash_len; in sae_write_confirm_pk() local 643 hash_len = sae_group_2_hash_len(pk->group); in sae_write_confirm_pk() 644 if (sae_pk_hash_sig_data(sae, hash_len, true, wpabuf_head(pk->m), in sae_write_confirm_pk() [all …]
|
D | dpp_backup.c | 215 size_t hash_len) in dpp_build_pbkdf2_alg_id() argument 234 if (hash_len == 32) in dpp_build_pbkdf2_alg_id() 236 else if (hash_len == 48) in dpp_build_pbkdf2_alg_id() 238 else if (hash_len == 64) in dpp_build_pbkdf2_alg_id() 250 asn1_put_integer(params, hash_len); /* keyLength */ in dpp_build_pbkdf2_alg_id() 264 dpp_build_pw_recipient_info(struct dpp_authentication *auth, size_t hash_len, in dpp_build_pw_recipient_info() argument 279 key_len = auth->curve->hash_len; in dpp_build_pw_recipient_info() 287 if (dpp_pbkdf2(hash_len, key, key_len, wpabuf_head(salt), 64, 1000, in dpp_build_pw_recipient_info() 288 kek, hash_len)) { in dpp_build_pw_recipient_info() 293 kek, hash_len); in dpp_build_pw_recipient_info() [all …]
|
D | dpp_pkex.c | 554 Kx, Kx_len, pkex->z, curve->hash_len); in dpp_pkex_rx_exchange_req() 593 clear_len = 4 + 2 * curve->prime_len + 4 + curve->hash_len; in dpp_pkex_build_commit_reveal_req() 633 wpabuf_put_le16(clear, curve->hash_len); in dpp_pkex_build_commit_reveal_req() 634 wpabuf_put_data(clear, u, curve->hash_len - 1); in dpp_pkex_build_commit_reveal_req() 635 wpabuf_put_u8(clear, u[curve->hash_len - 1] ^ 0x01); in dpp_pkex_build_commit_reveal_req() 642 wpabuf_put_le16(clear, curve->hash_len); in dpp_pkex_build_commit_reveal_req() 643 wpabuf_put_data(clear, u, curve->hash_len); in dpp_pkex_build_commit_reveal_req() 666 if (aes_siv_encrypt(pkex->z, curve->hash_len, in dpp_pkex_build_commit_reveal_req() 854 if (dpp_hmac_vector(curve->hash_len, Jx, Jx_len, num_elem, addr, len, u) in dpp_pkex_rx_exchange_resp() 857 wpa_hexdump(MSG_DEBUG, "DPP: u", u, curve->hash_len); in dpp_pkex_rx_exchange_resp() [all …]
|
D | dpp_i.h | 84 int dpp_hkdf_expand(size_t hash_len, const u8 *secret, size_t secret_len, 86 int dpp_hmac_vector(size_t hash_len, const u8 *key, size_t key_len, 92 int dpp_pbkdf2(size_t hash_len, const u8 *password, size_t password_len, 103 int dpp_derive_k1(const u8 *Mx, size_t Mx_len, u8 *k1, unsigned int hash_len); 104 int dpp_derive_k2(const u8 *Nx, size_t Nx_len, u8 *k2, unsigned int hash_len); 110 int dpp_derive_pmk(const u8 *Nx, size_t Nx_len, u8 *pmk, unsigned int hash_len); 128 u8 *z, unsigned int hash_len);
|
D | dpp_auth.c | 205 if (aes_siv_encrypt(auth->k1, auth->curve->hash_len, clear, siv_len, in dpp_auth_build_req() 391 if (aes_siv_encrypt(siv_key, auth->curve->hash_len, clear, siv_len, in dpp_auth_build_resp() 492 auth->curve->hash_len) < 0) in dpp_auth_build_resp_ok() 506 WPA_PUT_LE16(&r_auth[2], auth->curve->hash_len); in dpp_auth_build_resp_ok() 512 r_auth[4 + auth->curve->hash_len / 2] ^= 0x01; in dpp_auth_build_resp_ok() 515 if (aes_siv_encrypt(auth->ke, auth->curve->hash_len, in dpp_auth_build_resp_ok() 516 r_auth, 4 + auth->curve->hash_len, in dpp_auth_build_resp_ok() 519 wrapped_r_auth_len = 4 + auth->curve->hash_len + AES_BLOCK_SIZE; in dpp_auth_build_resp_ok() 791 auth->curve->hash_len) < 0) in dpp_auth_req_rx() 806 if (aes_siv_decrypt(auth->k1, auth->curve->hash_len, in dpp_auth_req_rx() [all …]
|
/external/rust/crates/aho-corasick/src/packed/ |
D | rabinkarp.rs | 48 hash_len: usize, field 71 let hash_len = patterns.minimum_len(); in new() localVariable 72 assert!(hash_len >= 1); in new() 75 for _ in 1..hash_len { in new() 81 hash_len, in new() 86 let hash = rk.hash(&pat.bytes()[..rk.hash_len]); in new() 108 if at + self.hash_len > haystack.len() { in find_at() 111 let mut hash = self.hash(&haystack[at..at + self.hash_len]); in find_at() 121 if at + self.hash_len >= haystack.len() { in find_at() 127 haystack[at + self.hash_len], in find_at() [all …]
|
/external/scapy/scapy/layers/tls/crypto/ |
D | hash.py | 38 hash_len = 0 variable in Hash_NULL 45 hash_len = 16 variable in Hash_MD5 49 hash_len = 20 variable in Hash_SHA 53 hash_len = 28 variable in Hash_SHA224 57 hash_len = 32 variable in Hash_SHA256 61 hash_len = 48 variable in Hash_SHA384 65 hash_len = 64 variable in Hash_SHA512
|
D | prf.py | 39 hash_len = hm.hash_alg.hash_len 40 n = (req_len + hash_len - 1) // hash_len 73 rounds = (req_len + hash_md5.hash_len - 1) // hash_md5.hash_len 108 rounds = (req_len + hash_md5.hash_len - 1) // hash_md5.hash_len
|
D | hkdf.py | 50 hash_len = self.hash.digest_size 51 return self.expand_label(secret, label, hash_messages, hash_len) 54 hash_len = self.hash.digest_size 55 finished_key = self.expand_label(basekey, b"finished", b"", hash_len)
|
/external/avb/libavb/ |
D | avb_crypto.c | 330 {.padding = NULL, .padding_len = 0, .hash_len = 0}, 334 .hash_len = AVB_SHA256_DIGEST_SIZE}, 338 .hash_len = AVB_SHA256_DIGEST_SIZE}, 342 .hash_len = AVB_SHA256_DIGEST_SIZE}, 346 .hash_len = AVB_SHA512_DIGEST_SIZE}, 350 .hash_len = AVB_SHA512_DIGEST_SIZE}, 354 .hash_len = AVB_SHA512_DIGEST_SIZE},
|
/external/wpa_supplicant_8/hostapd/ |
D | sae_pk_gen.c | 33 size_t hash_len; in main() local 81 hash_len = 32; in main() 84 hash_len = 48; in main() 87 hash_len = 64; in main() 110 if (sae_hash(hash_len, data, data_len, hash) < 0) { in main() 129 wpa_snprintf_hex(hash_hex, sizeof(hash_hex), hash, hash_len) < 0) in main() 149 for (j = 0; j < 8 * (int) hash_len / 20; j++) { in main() 152 sae_pk_buf_shift_left_19(hash + sec, hash_len - sec); in main() 166 pw_base_bin, hash_len - sec) >= 0) in main() 177 for (j = 4; j <= ((int) hash_len * 8 + 5 - 8 * sec) / 19; j++) { in main()
|
/external/libsrtp2/crypto/test/ |
D | sha1_driver.c | 63 unsigned hash_len; /* number of octets output by hash */ member 75 unsigned hash_len) in hash_test_case_add() argument 93 hash_len * 2); in hash_test_case_add() 94 if (tmp_len != hash_len * 2) { in hash_test_case_add() 100 test_case->hash_len = hash_len; in hash_test_case_add() 117 if (test_case->hash_len != 20) in sha1_test_case_validate()
|
/external/wpa_supplicant_8/src/eap_common/ |
D | ikev2_common.c | 118 size_t hash_len; in ikev2_prf_plus() local 128 hash_len = prf->hash_len; in ikev2_prf_plus() 131 len[0] = hash_len; in ikev2_prf_plus() 150 clen = hash_len; in ikev2_prf_plus() 402 sign_len = wpabuf_len(sign_msg) + nonce_len + prf->hash_len; in ikev2_derive_auth_data() 411 os_memcpy(pos, hash, prf->hash_len); in ikev2_derive_auth_data() 416 ikev2_prf_hash(prf->id, hash, prf->hash_len, 1, in ikev2_derive_auth_data() 461 if (encrypted_len < iv_len + 1 + integ_alg->hash_len) { in ikev2_decrypt_payload() 470 integ = end - integ_alg->hash_len; in ikev2_decrypt_payload() 483 if (os_memcmp_const(integ, hash, integ_alg->hash_len) != 0) { in ikev2_decrypt_payload() [all …]
|
/external/rust/crates/quiche/deps/boringssl/src/ssl/ |
D | ssl_transcript.cc | 195 size_t hash_len; in UpdateForHelloRetryRequest() local 196 if (!GetHash(old_hash, &hash_len)) { in UpdateForHelloRetryRequest() 200 static_cast<uint8_t>(hash_len)}; in UpdateForHelloRetryRequest() 203 !Update(MakeConstSpan(old_hash, hash_len))) { in UpdateForHelloRetryRequest()
|
/external/boringssl/src/ssl/ |
D | ssl_transcript.cc | 189 size_t hash_len; in UpdateForHelloRetryRequest() local 190 if (!GetHash(old_hash, &hash_len)) { in UpdateForHelloRetryRequest() 194 static_cast<uint8_t>(hash_len)}; in UpdateForHelloRetryRequest() 197 !Update(MakeConstSpan(old_hash, hash_len))) { in UpdateForHelloRetryRequest()
|
/external/arm-trusted-firmware/drivers/nxp/crypto/caam/src/auth/ |
D | rsa.c | 90 static int construct_img_encoded_hash_second(uint8_t *hash, uint8_t hash_len, in construct_img_encoded_hash_second() argument 118 if (hash_len != SHA256_BYTES) { in construct_img_encoded_hash_second() 150 int rsa_verify_signature(void *hash_ptr, unsigned int hash_len, in rsa_verify_signature() argument 158 ret = construct_img_encoded_hash_second(hash_ptr, hash_len, in rsa_verify_signature()
|
/external/wpa_supplicant_8/src/tls/ |
D | tlsv1_client_ocsp.c | 124 unsigned int hash_len; in tls_process_ocsp_single_response() local 175 hash_len = ocsp_hash_data(&alg.oid, issuer->subject_dn, in tls_process_ocsp_single_response() 177 if (hash_len == 0 || name_hash_len != hash_len || in tls_process_ocsp_single_response() 178 os_memcmp(name_hash, hash, hash_len) != 0) { in tls_process_ocsp_single_response() 181 hash, hash_len); in tls_process_ocsp_single_response() 197 hash_len = ocsp_hash_data(&alg.oid, issuer->public_key, in tls_process_ocsp_single_response() 199 if (hash_len == 0 || key_hash_len != hash_len || in tls_process_ocsp_single_response() 200 os_memcmp(key_hash, hash, hash_len) != 0) { in tls_process_ocsp_single_response() 203 hash, hash_len); in tls_process_ocsp_single_response()
|
/external/arm-trusted-firmware/drivers/nxp/auth/csf_hdr_parser/ |
D | plat_img_parser.c | 30 uint32_t hash_len; variable 64 ZERO_AND_CLEAN(hash_len); in clear_temp_vars() 106 img_len - CSF_HDR_SZ, img_hash, &hash_len); in check_integrity()
|
/external/wpa_supplicant_8/src/eap_server/ |
D | eap_server.c | 710 size_t hash_len; in erp_send_finish_reauth() local 716 hash_len = 32; in erp_send_finish_reauth() 719 hash_len = 16; in erp_send_finish_reauth() 725 hash_len = 0; in erp_send_finish_reauth() 728 if (hash_len) in erp_send_finish_reauth() 729 plen += 1 + hash_len; in erp_send_finish_reauth() 749 wpabuf_put_data(msg, hash, hash_len); in erp_send_finish_reauth() 808 size_t hash_len; in SM_STATE() local 913 hash_len = 32; in SM_STATE() 921 hash_len = 16; in SM_STATE() [all …]
|
/external/tpm2-tss/src/tss2-esys/ |
D | esys_crypto_gcrypt.c | 33 size_t hash_len; member 106 int hash_len = gcry_md_get_algo_dlen(mycontext->hash.gcry_hash_alg); in iesys_cryptogcry_hash_start() local 107 if (hash_len <= 0) { in iesys_cryptogcry_hash_start() 112 mycontext->hash.hash_len = hash_len; in iesys_cryptogcry_hash_start() 208 if (*size < mycontext->hash.hash_len) { in iesys_cryptogcry_hash_finish() 217 LOGBLOB_TRACE(cpHash, mycontext->hash.hash_len, "read hash result"); in iesys_cryptogcry_hash_finish() 219 *size = mycontext->hash.hash_len; in iesys_cryptogcry_hash_finish()
|
D | esys_crypto.c | 401 size_t hash_len; in iesys_crypto_KDFe() local 415 r = iesys_crypto_hash_get_digest_size(hashAlg, &hash_len); in iesys_crypto_KDFe() 424 for (; byte_size > 0; stream = &stream[hash_len], byte_size = byte_size - hash_len) in iesys_crypto_KDFe() 457 r = iesys_crypto_hash_finish(&cryptoContext, (uint8_t *) stream, &hash_len); in iesys_crypto_KDFe()
|
/external/boringssl/src/crypto/evp/ |
D | p_rsa.c | 270 const size_t hash_len = EVP_MD_size(rctx->md); in pkey_rsa_verify_recover() local 277 kDummyHash, hash_len)) { in pkey_rsa_verify_recover() 287 CRYPTO_memcmp(rctx->tbuf, asn1_prefix, asn1_prefix_len - hash_len) != 0) { in pkey_rsa_verify_recover() 300 OPENSSL_memcpy(out, rctx->tbuf + rslen - hash_len, hash_len); in pkey_rsa_verify_recover() 302 *out_len = hash_len; in pkey_rsa_verify_recover()
|
/external/rust/crates/quiche/deps/boringssl/src/crypto/evp/ |
D | p_rsa.c | 270 const size_t hash_len = EVP_MD_size(rctx->md); in pkey_rsa_verify_recover() local 277 kDummyHash, hash_len)) { in pkey_rsa_verify_recover() 287 CRYPTO_memcmp(rctx->tbuf, asn1_prefix, asn1_prefix_len - hash_len) != 0) { in pkey_rsa_verify_recover() 300 OPENSSL_memcpy(out, rctx->tbuf + rslen - hash_len, hash_len); in pkey_rsa_verify_recover() 302 *out_len = hash_len; in pkey_rsa_verify_recover()
|