Home
last modified time | relevance | path

Searched refs:G (Results 1 – 25 of 40) sorted by relevance

12

/mbedtls-3.5.0/library/
Decjpake.c238 const mbedtls_ecp_point *G, in ecjpake_hash() argument
252 MBEDTLS_MPI_CHK(ecjpake_write_len_point(&p, end, grp, pf, G)); in ecjpake_hash()
289 const mbedtls_ecp_point *G, in ecjpake_zkp_read() argument
335 MBEDTLS_MPI_CHK(ecjpake_hash(md_type, grp, pf, G, &V, X, id, &h)); in ecjpake_zkp_read()
337 &VV, &h, X, &r, G)); in ecjpake_zkp_read()
359 const mbedtls_ecp_point *G, in ecjpake_zkp_write() argument
384 G, &v, &V, f_rng, p_rng)); in ecjpake_zkp_write()
385 MBEDTLS_MPI_CHK(ecjpake_hash(md_type, grp, pf, G, &V, X, id, &h)); in ecjpake_zkp_write()
420 const mbedtls_ecp_point *G, in ecjpake_kkp_read() argument
444 MBEDTLS_MPI_CHK(ecjpake_zkp_read(md_type, grp, pf, G, X, id, p, end)); in ecjpake_kkp_read()
[all …]
Ddhm.c135 src = &ctx->G; in mbedtls_dhm_get_value()
165 (ret = dhm_read_bignum(&ctx->G, p, end)) != 0 || in mbedtls_dhm_read_params()
221 MBEDTLS_MPI_CHK(mbedtls_mpi_exp_mod(&ctx->GX, &ctx->G, &ctx->X, in dhm_make_common()
264 n2 = mbedtls_mpi_size(&ctx->G); in mbedtls_dhm_make_params()
269 DHM_MPI_EXPORT(&ctx->G, n2); in mbedtls_dhm_make_params()
286 const mbedtls_mpi *G) in mbedtls_dhm_set_group() argument
291 (ret = mbedtls_mpi_copy(&ctx->G, G)) != 0) { in mbedtls_dhm_set_group()
484 mbedtls_mpi_free(&ctx->G); in mbedtls_dhm_free()
548 (ret = mbedtls_asn1_get_mpi(&p, end, &dhm->G)) != 0) { in mbedtls_dhm_parse_dhm()
Dpkparse.c336 if ((ret = mbedtls_ecp_point_read_binary(grp, &grp->G, in pk_group_from_specified()
345 mbedtls_mpi_read_binary(&grp->G.X, p + 1, len - 1) != 0 || in pk_group_from_specified()
346 mbedtls_mpi_lset(&grp->G.Y, p[0] - 2) != 0 || in pk_group_from_specified()
347 mbedtls_mpi_lset(&grp->G.Z, 1) != 0) { in pk_group_from_specified()
393 mbedtls_mpi_cmp_mpi(&grp->G.X, &ref.G.X) == 0 && in pk_group_id_from_group()
394 mbedtls_mpi_cmp_mpi(&grp->G.Z, &ref.G.Z) == 0 && in pk_group_id_from_group()
396 mbedtls_mpi_get_bit(&grp->G.Y, 0) == mbedtls_mpi_get_bit(&ref.G.Y, 0)) { in pk_group_id_from_group()
443 mbedtls_ecp_point_free(&grp.G); in pk_group_id_from_specified()
979 (ret = mbedtls_ecp_mul(&eck->grp, &eck->Q, &eck->d, &eck->grp.G, in pk_parse_key_sec1_der()
Decp_curves.c4550 ecp_mpi_load(&grp->G.X, gx, gxlen); in ecp_group_load()
4551 ecp_mpi_load(&grp->G.Y, gy, gylen); in ecp_group_load()
4552 ecp_mpi_set1(&grp->G.Z); in ecp_group_load()
4618 #define LOAD_GROUP_A(G) ecp_group_load(grp, \ argument
4619 G ## _p, sizeof(G ## _p), \
4620 G ## _a, sizeof(G ## _a), \
4621 G ## _b, sizeof(G ## _b), \
4622 G ## _gx, sizeof(G ## _gx), \
4623 G ## _gy, sizeof(G ## _gy), \
4624 G ## _n, sizeof(G ## _n), \
[all …]
Decp.c493 if (grp->G.X.p == NULL) { in mbedtls_ecp_get_type()
497 if (grp->G.Y.p == NULL) { in mbedtls_ecp_get_type()
523 mbedtls_ecp_point_init(&grp->G); in mbedtls_ecp_group_init()
587 mbedtls_ecp_point_free(&grp->G); in mbedtls_ecp_group_free()
2313 p_eq_g = (MPI_ECP_CMP(&P->Y, &grp->G.Y) == 0 && in ecp_mul_comb()
2314 MPI_ECP_CMP(&P->X, &grp->G.X) == 0); in ecp_mul_comb()
3166 const mbedtls_ecp_point *G, in mbedtls_ecp_gen_keypair_base() argument
3173 MBEDTLS_MPI_CHK(mbedtls_ecp_mul(grp, Q, d, G, f_rng, p_rng)); in mbedtls_ecp_gen_keypair_base()
3187 return mbedtls_ecp_gen_keypair_base(grp, &grp->G, d, Q, f_rng, p_rng); in mbedtls_ecp_gen_keypair()
3345 MBEDTLS_MPI_CHK(mbedtls_ecp_mul(&grp, &Q, &prv->d, &prv->grp.G, f_rng, p_rng)); in mbedtls_ecp_check_pub_priv()
[all …]
Dbignum.c1951 int mbedtls_mpi_gcd(mbedtls_mpi *G, const mbedtls_mpi *A, const mbedtls_mpi *B) in mbedtls_mpi_gcd() argument
1957 MPI_VALIDATE_RET(G != NULL); in mbedtls_mpi_gcd()
1974 ret = mbedtls_mpi_copy(G, A); in mbedtls_mpi_gcd()
2049 MBEDTLS_MPI_CHK(mbedtls_mpi_copy(G, &TB)); in mbedtls_mpi_gcd()
2116 mbedtls_mpi G, TA, TU, U1, U2, TB, TV, V1, V2; in mbedtls_mpi_inv_mod() local
2126 mbedtls_mpi_init(&G); mbedtls_mpi_init(&TB); mbedtls_mpi_init(&TV); in mbedtls_mpi_inv_mod()
2129 MBEDTLS_MPI_CHK(mbedtls_mpi_gcd(&G, A, N)); in mbedtls_mpi_inv_mod()
2131 if (mbedtls_mpi_cmp_int(&G, 1) != 0) { in mbedtls_mpi_inv_mod()
2195 mbedtls_mpi_free(&G); mbedtls_mpi_free(&TB); mbedtls_mpi_free(&TV); in mbedtls_mpi_inv_mod()
/mbedtls-3.5.0/tests/suites/
Dtest_suite_dhm.function68 /* Check ske: it must contain P, G and G^X, each prefixed with a
73 if (!check_dhm_param_output(&ctx->G, ske, ske_len, &offset)) {
123 TEST_ASSERT(mbedtls_test_read_mpi(&ctx_srv.G, input_G) == 0);
126 TEST_ASSERT(check_get_value(&ctx_srv, MBEDTLS_DHM_PARAM_G, &ctx_srv.G));
147 TEST_ASSERT(check_get_value(&ctx_cli, MBEDTLS_DHM_PARAM_G, &ctx_srv.G));
235 mbedtls_mpi P, G;
240 mbedtls_mpi_init(&G);
247 TEST_ASSERT(mbedtls_test_read_mpi(&G, input_G) == 0);
249 TEST_ASSERT(mbedtls_dhm_set_group(&ctx, &P, &G) == 0);
257 mbedtls_mpi_free(&G);
[all …]
Dtest_suite_dhm.data79 Diffie-Hellman with G=0
82 Diffie-Hellman with G=1
85 Diffie-Hellman with G=-1
88 Diffie-Hellman with G=P-1
91 Diffie-Hellman with G=P-2
94 Diffie-Hellman with G=P
97 Diffie-Hellman with G=P+1
100 Diffie-Hellman with G=P+2
Dtest_suite_ecp.function38 if (mbedtls_ecp_point_cmp(&grp1->G, &grp2->G) != 0) {
211 ret = mbedtls_ecp_mul_restartable(&grp, &R, &dA, &grp.G,
262 * Compute R = u1 * G + u2 * Q
298 &u1, &grp.G, &u2, &Q, &ctx);
312 &u1, &grp.G, &u2, &Q, &ctx);
343 TEST_ASSERT(mbedtls_ecp_check_pubkey(&grp, &grp.G) == 0);
354 TEST_ASSERT(mbedtls_ecp_mul(&grp, &R, &dA, &grp.G,
365 TEST_ASSERT(mbedtls_ecp_mul(&grp, &R, &dB, &grp.G,
400 TEST_ASSERT(mbedtls_ecp_check_pubkey(&grp, &grp.G) == 0);
408 TEST_ASSERT(mbedtls_ecp_mul(&grp, &R, &dA, &grp.G,
[all …]
/mbedtls-3.5.0/programs/pkey/
Ddh_genprime.c61 mbedtls_mpi G, P, Q; in main() local
70 mbedtls_mpi_init(&G); mbedtls_mpi_init(&P); mbedtls_mpi_init(&Q); in main()
97 if ((ret = mbedtls_mpi_read_string(&G, 10, GENERATOR)) != 0) { in main()
153 ((ret = mbedtls_mpi_write_file("G = ", &G, 16, fout)) != 0)) { in main()
166 mbedtls_mpi_free(&G); mbedtls_mpi_free(&P); mbedtls_mpi_free(&Q); in main()
Ddh_prime.txt2 G = 02
/mbedtls-3.5.0/include/mbedtls/
Ddhm.h115 mbedtls_mpi MBEDTLS_PRIVATE(G); /*!< The generator. */
218 const mbedtls_mpi *G);
Decp.h239 mbedtls_ecp_point G; /*!< The generator of the subgroup used. */ member
1189 const mbedtls_ecp_point *G,
/mbedtls-3.5.0/tests/include/alt-dummy/
Decp_alt.h27 const mbedtls_ecp_point G; member
/mbedtls-3.5.0/tests/data_files/dir4/
Dcert23.crt7 FiFrrUL0MNgiGxjkTthWgsfV4C/i3vRDTCW+2UMFdd6+z7hwFf+ldTsCP9Qp+93G
Dcert42.crt15 1lO/MiwxhTTluHPGkl/nBG+uxySInuQMDvdyQDXp2e17qxops+G+1UnRJinqLtsd
Dcert52.crt15 1lO/MiwxhTTluHPGkl/nBG+uxySInuQMDvdyQDXp2e17qxops+G+1UnRJinqLtsd
/mbedtls-3.5.0/tests/data_files/
Drsa_pkcs1_1024_aes192.pem15 Tk/G/dS0t41QJuaW1sv9DkJJcl1696PSI4ysDJx9Y8LtV1+DzvdlxSyJdg3mJHEL
Dserver2.key8 ++AtOg6eENxD+xVs0f1IeGz57Tjo3QnXX7VBZNdj+p1ECvhCE/G7XnkgU5hLZX+G
Dserver7_all_space.crt4 ZWRpYXRlIENBMB4XDTEzMDkyNDE2MTIyNFoXDTIzMDkyMjE2MTIyNFowNDELMAk G
Dserver7_pem_space.crt4 ZWRpYXRlIENBMB4XDTEzMDkyNDE2MTIyNFoXDTIzMDkyMjE2MTIyNFowNDELMAk G
Drsa_pkcs1_2048_3des.pem11 8FGAP9ft1m5DMBbAYBUhZHlSFZ/9G/gWa/VskSmjniq83+RO24fXoTxYUx716z4S
Drsa_pkcs8_pbes2_pbkdf2_4096_des_sha384.pem4 G+i8Eem50G7EdQNLsIkCG8Qgu/IplVx7MyGLd3FUmPpSVnEsxvfk3rRJb8NDnm9m
Drsa_pkcs8_pbes2_pbkdf2_4096_3des.pem7 GRexE5rzhI+jSctBnGL1t8IhUbceBnLjAIDRyNrQFnDypzAMrV/Wqtvf3H8o7m/G
Drsa_pkcs1_4096_aes256.pem53 B5e3w69NVD9d8cKHz/M7ld5O9B0o+G+/yrDkAokJuGACHjqhEzhBfpDO1orNb7Sj

12