On reference counting keydata returned from keymgmt_load()

Selva Nair selva.nair at gmail.com
Tue Sep 14 05:22:36 UTC 2021


Hi,

Replying to self..

On Mon, Sep 13, 2021 at 10:08 PM Selva Nair <selva.nair at gmail.com> wrote:

> Hi,
>
> When an EVP_PKEY is created with some custom data, provider's
> keymgmt_load() gets called. I want to keep a reference count on the keydata
> returned from it. But there is no call to keymgmt_free() or anything
> similar when the EVP_PKEY is freed. How does one keep track of references
> to keydata? I have something like:
>

Please ignore the noise. OSSL_STORE_INFO_free(info) was missing and that
was holding the key. Indeed keymgmt_load() is paired with keymgmt_free().

Should have checked twice before posting.

Selva

>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mta.openssl.org/pipermail/openssl-users/attachments/20210914/97bd14a6/attachment.html>


More information about the openssl-users mailing list