Latest update.

This commit is contained in:
2020-04-15 18:45:34 +09:00
parent be29e7bcc6
commit 2015c00c43
573 changed files with 22943 additions and 6714 deletions
+10 -10
View File
@@ -19,27 +19,27 @@
int EC_GROUP_check_named_curve(const EC_GROUP *group, int nist_only,
BN_CTX *ctx)
{
int nid = NID_undef;
#ifndef FIPS_MODE
int nid;
BN_CTX *new_ctx = NULL;
if (group == NULL) {
ECerr(0, ERR_R_PASSED_NULL_PARAMETER);
return NID_undef;
}
if (ctx == NULL) {
ctx = new_ctx = BN_CTX_new();
ctx = new_ctx = BN_CTX_new_ex(NULL);
if (ctx == NULL) {
ECerr(EC_F_EC_GROUP_CHECK_NAMED_CURVE, ERR_R_MALLOC_FAILURE);
goto err;
ECerr(0, ERR_R_MALLOC_FAILURE);
return NID_undef;
}
}
#endif
nid = ec_curve_nid_from_params(group, ctx);
if (nid > 0 && nist_only && EC_curve_nid2nist(nid) == NULL)
nid = NID_undef;
#ifndef FIPS_MODE
err:
BN_CTX_free(ctx);
#endif
BN_CTX_free(new_ctx);
return nid;
}