Re: How to access different fields of typedef struct evp_pkey_st EVP_PKEY.

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

 





On 20/04/2021 11:45, Kumar Mishra, Sanjeev wrote:
Hi,
I am not getting different functions in OpenSSL 3.0 for accessing different fields of typedef struct evp_pkey_st EVP_PKEY. For Example - code is like this -
EVP_PKEY * privKey;
-----
-----
if ( BN_cmp(privKey->pkey.rsa->n, pubKey->pkey.rsa->n) != 0 )

BIGNUM *privn = NULL, *pubn = NULL;

/* Error handling omitted for brevity...*/
EVP_PKEY_get_bn_param(privKey, "n", &privn);
EVP_PKEY_get_bn_param(pubKey, "n", &pubKey);
if ( BN_cmp(privn, pubn) != 0)

...
BN_free(privn);
BN_free(pubn);

----
----
else if ((privKey->type == EVP_PKEY_EC) && (pubKey->type == EVP_PKEY_EC))


else if (EVP_PKEY_is_a(privKey, "EC") && (EVP_PKEY_is_a(pubKey, "EC"))



Matt



[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