Re: EVP_PKEY_fromdata_init returns unsupported.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Bill,

How are you creating the EVP_PKEY_CTX?

Kory


> On Feb 25, 2022, at 2:07 PM, William Roberts <bill.c.roberts@xxxxxxxxx> wrote:
> 
> Hello,
> 
> In openssl 3.0.1 the following code hits the ctx->keymgt is null check
> and thus returns -2
> in pmeth_gn.c:
> static int fromdata_init(EVP_PKEY_CTX *ctx, int operation)
> {
>    if (ctx == NULL || ctx->keytype == NULL)
>        goto not_supported;
> 
>    evp_pkey_ctx_free_old_ops(ctx);
>    if (ctx->keymgmt == NULL)
>        goto not_supported;
> 
> The callpath comes in from EVP_PKEY_fromdata_init:
> 
> libctx = OSSL_LIB_CTX_new()
> genctx = EVP_PKEY_CTX_new_from_name(libctx, "RSA", NULL);
> int rc = EVP_PKEY_fromdata_init(genctx);
> 
> I have no idea why it returns unsupported... any ideas?
> I also tried replacing EVP_PKEY_CTX_new_from_name  with
> EVP_PKEY_CTX_new_id, same error.
> 
> Thanks,
> Bill





[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux