Skip to content

Commit

Permalink
fixup! fixup! cmp_{kemrsa.c, local.h}: add rsa kem and kdf2 implement…
Browse files Browse the repository at this point in the history
…ation
  • Loading branch information
rajeev-0 committed Jan 5, 2024
1 parent 405447d commit fc8c3d6
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions crypto/cmp/cmp_kemrsa.c
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ int ossl_cmp_kemrsa_decapsulation(OSSL_CMP_CTX *ctx, EVP_PKEY *pkey,
int ret = 0;
size_t sec_len;
unsigned char *sec;
EVP_PKEY_CTX *kem_decaps_ctx;

if (ctx == NULL || pkey == NULL
|| ct == NULL
Expand All @@ -87,9 +88,9 @@ int ossl_cmp_kemrsa_decapsulation(OSSL_CMP_CTX *ctx, EVP_PKEY *pkey,
if (EVP_PKEY_get_base_id(pkey) != EVP_PKEY_RSA)
return 0;

EVP_PKEY_CTX *kem_decaps_ctx = EVP_PKEY_CTX_new_from_pkey(ctx->libctx,
pkey,
ctx->propq);
kem_decaps_ctx = EVP_PKEY_CTX_new_from_pkey(ctx->libctx,
pkey,
ctx->propq);

if (kem_decaps_ctx == NULL
|| EVP_PKEY_decapsulate_init(kem_decaps_ctx, NULL) <= 0
Expand Down

0 comments on commit fc8c3d6

Please sign in to comment.