summaryrefslogtreecommitdiffstats
path: root/providers/implementations/keymgmt/ec_kmgmt.c
diff options
context:
space:
mode:
Diffstat (limited to 'providers/implementations/keymgmt/ec_kmgmt.c')
-rw-r--r--providers/implementations/keymgmt/ec_kmgmt.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/providers/implementations/keymgmt/ec_kmgmt.c b/providers/implementations/keymgmt/ec_kmgmt.c
index f563d920c4..2673619ef4 100644
--- a/providers/implementations/keymgmt/ec_kmgmt.c
+++ b/providers/implementations/keymgmt/ec_kmgmt.c
@@ -1288,14 +1288,8 @@ static void *sm2_gen(void *genctx, OSSL_CALLBACK *osslcb, void *cbarg)
ret = ec_gen_assign_group(ec, gctx->gen_group);
/* Whether you want it or not, you get a keypair, not just one half */
- if ((gctx->selection & OSSL_KEYMGMT_SELECT_KEYPAIR) != 0) {
- /*
- * For SM2, we need a new flag to indicate the 'generate' function
- * to use a new range
- */
- EC_KEY_set_flags(ec, EC_FLAG_SM2_RANGE);
+ if ((gctx->selection & OSSL_KEYMGMT_SELECT_KEYPAIR) != 0)
ret = ret && EC_KEY_generate_key(ec);
- }
if (ret)
return ec;