[openssl-users] Const qualifier for EVP_PKEY parameters in pub_encode method
reinier.torenbeek at gmail.com
Wed Oct 28 20:42:45 UTC 2015
While implementing an engine, I run into the following prototype that I
need to implement:
int (*pub_encode)(X509_PUBKEY *pub, *const* EVP_PKEY *pk);
} /* EVP_PKEY_ASN1_METHOD */;
Inside this function, I want to assign pk to pub->pkey (and do the
necessary up and down reffing of the EVP_PKEYs involved). But that is
not allowed, because of the const qualifier on pk.
For now, I have just worked around the compiler complaints by casting to
a non-const, but I wonder whether this will bite me at some point?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the openssl-users