I am using openssl 0.9.8 (and currently cant change to a higher version). i am using the openssl evp api (evp - high-level cryptographic functions ) to encrypt so data with aes and the key with rsa.
a call of:
EVP_PKEY_CTX *ctx = EVP_PKEY_CTX_new_id(EVP_PKEY_RSA, NULL);
results in an compiling error:
error: 'EVP_PKEY_CTX' was not declared in this scope
according to this link
VP_PKEY_CTX is only in 1.0.0 and later.
But evp allready existed in 0.9.8. so what type should i use instead of EVP_PKEY_CTX for my pointer variable *ctx?
But evp allready existed in 0.9.8. so what type should i use instead of EVP_PKEY_CTX for my pointer variable *ctx?
EVP_PKEY
and friends may be available in OpenSSL 0.9.8. For example:
$ grep -R EVP_PKEY_new *
apps/req.c: if ((pkey=EVP_PKEY_new()) == NULL) goto end;
apps/apps.c: pkey = EVP_PKEY_new();
crypto/evp/p_lib.c:EVP_PKEY *EVP_PKEY_new(void)
...
But I don't see where EVP_PKEY_CTX_new_id
and EVP_PKEY_CTX
are available in OpenSSL 0.9.8. This is consistent with what the docs are telling you.
$ grep -R EVP_PKEY_CTX_new_id *
$
$ grep -R EVP_PKEY_CTX *
crypto/cms/cms_sd.c: if (EVP_PKEY_CTX_ctrl(pctx, -1, EVP_PKEY_OP_SIGN,
crypto/cms/cms_sd.c: if (EVP_PKEY_CTX_ctrl(pctx, -1, EVP_PKEY_OP_SIGN,
$
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.