Searched refs:prime_len (Results 1 – 9 of 9) sorted by relevance
/external/wpa_supplicant_8/src/common/ |
D | sae.c | 33 tmp->prime_len = crypto_ec_prime_len(tmp->ec); in sae_set_group() 43 tmp->prime_len = tmp->dh->prime_len; in sae_set_group() 44 if (tmp->prime_len > SAE_MAX_PRIME_LEN) { in sae_set_group() 50 tmp->prime_len); in sae_set_group() 173 get_rand_1_to_p_1(const u8 *prime, size_t prime_len, size_t prime_bits, in get_rand_1_to_p_1() argument 180 if (random_get_bytes(tmp, prime_len) < 0) in get_rand_1_to_p_1() 183 buf_shift_right(tmp, prime_len, 8 - prime_bits % 8); in get_rand_1_to_p_1() 184 if (os_memcmp(tmp, prime, prime_len) >= 0) in get_rand_1_to_p_1() 186 r = crypto_bignum_init_set(tmp, prime_len); in get_rand_1_to_p_1() 194 *r_odd = tmp[prime_len - 1] & 0x01; in get_rand_1_to_p_1() [all …]
|
D | sae.h | 35 int prime_len; member
|
/external/wpa_supplicant_8/src/crypto/ |
D | dh_groups.c | 1202 *priv = wpabuf_alloc(dh->prime_len); in dh_init() 1206 if (random_get_bytes(wpabuf_put(*priv, dh->prime_len), dh->prime_len)) in dh_init() 1213 if (os_memcmp(wpabuf_head(*priv), dh->prime, dh->prime_len) > 0) { in dh_init() 1219 pv_len = dh->prime_len; in dh_init() 1228 dh->prime, dh->prime_len, wpabuf_mhead(pv), in dh_init() 1260 shared_len = dh->prime_len; in dh_derive_shared() 1266 dh->prime, dh->prime_len, in dh_derive_shared()
|
D | dh_groups.h | 17 size_t prime_len; member
|
/external/wpa_supplicant_8/src/eap_common/ |
D | eap_eke_common.c | 173 if (random_get_bytes(ret_priv, dh->prime_len)) in eap_eke_dh_init() 175 if (os_memcmp(ret_priv, dh->prime, dh->prime_len) > 0) { in eap_eke_dh_init() 179 for (i = 0; i < dh->prime_len - 1; i++) { in eap_eke_dh_init() 183 if (i == dh->prime_len - 1 && (ret_priv[i] == 0 || ret_priv[i] == 1)) in eap_eke_dh_init() 186 ret_priv, dh->prime_len); in eap_eke_dh_init() 189 pub_len = dh->prime_len; in eap_eke_dh_init() 190 if (crypto_mod_exp(&gen, 1, ret_priv, dh->prime_len, in eap_eke_dh_init() 191 dh->prime, dh->prime_len, ret_pub, &pub_len) < 0) in eap_eke_dh_init() 193 if (pub_len < dh->prime_len) { in eap_eke_dh_init() 194 size_t pad = dh->prime_len - pub_len; in eap_eke_dh_init() [all …]
|
/external/wpa_supplicant_8/src/eap_peer/ |
D | ikev2.c | 78 pad_len = data->dh->prime_len - wpabuf_len(shared); in ikev2_derive_keys() 399 if (kei_len - 4 != data->dh->prime_len) { in ikev2_process_kei() 402 (long) (kei_len - 4), (long) data->dh->prime_len); in ikev2_process_kei() 925 wpabuf_put(msg, data->dh->prime_len - wpabuf_len(pv)); in ikev2_build_ker()
|
D | eap_pwd.c | 365 size_t prime_len, order_len; in eap_pwd_perform_commit_exchange() local 372 prime_len = BN_num_bytes(data->grp->prime); in eap_pwd_perform_commit_exchange() 375 if (payload_len != 2 * prime_len + order_len) { in eap_pwd_perform_commit_exchange() 379 (unsigned int) (2 * prime_len + order_len)); in eap_pwd_perform_commit_exchange()
|
/external/wpa_supplicant_8/src/eap_server/ |
D | ikev2.c | 83 pad_len = data->dh->prime_len - wpabuf_len(shared); in ikev2_derive_keys() 404 if (ker_len - 4 != data->dh->prime_len) { in ikev2_process_ker() 407 (long) (ker_len - 4), (long) data->dh->prime_len); in ikev2_process_ker() 991 wpabuf_put(msg, data->dh->prime_len - wpabuf_len(pv)); in ikev2_build_kei()
|
D | eap_server_pwd.c | 664 size_t prime_len, order_len; in eap_pwd_process_commit_resp() local 668 prime_len = BN_num_bytes(data->grp->prime); in eap_pwd_process_commit_resp() 671 if (payload_len != 2 * prime_len + order_len) { in eap_pwd_process_commit_resp() 675 (unsigned int) (2 * prime_len + order_len)); in eap_pwd_process_commit_resp()
|