[openssl-users] overriding EVP_PKEY method callbacks for a specific key only

Selva Nair selva.nair at gmail.com
Mon Oct 15 20:12:43 UTC 2018


 Hi,

How to override the evp_pkey_sign method in EVP_PKEY_METHOD structure for a
specific key? This is to allow signing with PSS padding using Windows CNG
API.  Using rsa_priv_enc() we can only get pre-padded data when PSS is in
use, but CNG does not seem to handle padding = none.

Also see issue 7341 on github https://github.com/openssl/openssl/issues/7341

I can use EVP_PKEY_meth_add0() to add a new method struct and that works.
But that affect all keys. Is it possible to replace the evp_pkey_sign
method on a specific key instance like one can do for RSA or EC methods?

Thanks,

Selva
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mta.openssl.org/pipermail/openssl-users/attachments/20181015/d24af129/attachment.html>


More information about the openssl-users mailing list