Lines Matching refs:g

95 static int generate_unverifiable_g(BN_CTX *ctx, BN_MONT_CTX *mont, BIGNUM *g,  in generate_unverifiable_g()  argument
108 if (!BN_mod_exp_mont(g, hbn, e, p, ctx, mont)) in generate_unverifiable_g()
111 if (BN_cmp(g, BN_value_one()) > 0) in generate_unverifiable_g()
133 const EVP_MD *evpmd, BIGNUM *g, BIGNUM *tmp, in generate_canonical_g() argument
174 || !BN_mod_exp_mont(g, tmp, e, p, ctx, mont)) in generate_canonical_g()
181 if (BN_cmp(g, BN_value_one()) > 0) { in generate_canonical_g()
526 BIGNUM *g = NULL, *q = NULL, *p = NULL; in ossl_ffc_params_FIPS186_4_gen_verify() local
579 g = BN_CTX_get(ctx); in ossl_ffc_params_FIPS186_4_gen_verify()
610 if (params->g == NULL) { in ossl_ffc_params_FIPS186_4_gen_verify()
735 && !ossl_ffc_params_validate_unverifiable_g(ctx, mont, p, q, params->g, in ossl_ffc_params_FIPS186_4_gen_verify()
751 if (!generate_canonical_g(ctx, mont, md, g, tmp, p, e, in ossl_ffc_params_FIPS186_4_gen_verify()
757 if (verify && BN_cmp(g, params->g) != 0) { in ossl_ffc_params_FIPS186_4_gen_verify()
762 if (!generate_unverifiable_g(ctx, mont, g, tmp, p, e, pm1, &hret)) in ossl_ffc_params_FIPS186_4_gen_verify()
778 if (g != params->g) { in ossl_ffc_params_FIPS186_4_gen_verify()
779 BN_free(params->g); in ossl_ffc_params_FIPS186_4_gen_verify()
780 params->g = BN_dup(g); in ossl_ffc_params_FIPS186_4_gen_verify()
782 if (params->p == NULL || params->q == NULL || params->g == NULL) in ossl_ffc_params_FIPS186_4_gen_verify()
817 BIGNUM *r0, *test, *tmp, *g = NULL, *q = NULL, *p = NULL; in ossl_ffc_params_FIPS186_2_gen_verify() local
893 g = BN_CTX_get(ctx); in ossl_ffc_params_FIPS186_2_gen_verify()
920 if (params->g == NULL) { in ossl_ffc_params_FIPS186_2_gen_verify()
998 if (!generate_unverifiable_g(ctx, mont, g, tmp, p, r0, test, &hret)) in ossl_ffc_params_FIPS186_2_gen_verify()
1002 params->g, tmp, in ossl_ffc_params_FIPS186_2_gen_verify()
1019 if (g != params->g) { in ossl_ffc_params_FIPS186_2_gen_verify()
1020 BN_free(params->g); in ossl_ffc_params_FIPS186_2_gen_verify()
1021 params->g = BN_dup(g); in ossl_ffc_params_FIPS186_2_gen_verify()
1023 if (params->p == NULL || params->q == NULL || params->g == NULL) in ossl_ffc_params_FIPS186_2_gen_verify()