CRYPTO_RSA_EncryptInit_PrivateKey

Syntax


#include <nitro/crypto.h>

s32 CRYPTO_RSA_EncryptInit_PrivateKey(CRYPTORSAContext *context, CRYPTORSAEncryptInitPKParam *param);
		

Arguments

context Address of the context structure for internal use.
param Address of the structure for specifying the required settings for RSA encryption.

Return Values

Returns one of the following process results.

0 Initialization succeeded
-1 Initialization failed

Description

Performs initialization for encryption using the RSA algorithm.

This function is different from CRYPTO_RSA_EncryptInit because it allows you to initialize using a private key.

The ASN.1 format private key used by the CRYPTO library uses specifications that include the content of the public key. It is therefore possible to encrypt using the public key included in private key data. This function encrypts data using a public key included in this private key.

See Also

CRYPTO_RSA_EncryptInit

Revision History

2008/11/17 Revised Description.
2008/04/17 Initial version.


CONFIDENTIAL