#include <asymmetrickeys.h>
| class CRSAKeyPair : public CBase |
| Protected Attributes | |
|---|---|
| CRSAPrivateKey * | iPrivate |
| CRSAPublicKey * | iPublic |
| Public Member Functions | |
|---|---|
| virtual | ~CRSAKeyPair(void) |
| IMPORT_C CRSAKeyPair * | NewL(TUint, TRSAPrivateKeyType) |
| IMPORT_C CRSAKeyPair * | NewLC(TUint, TRSAPrivateKeyType) |
| IMPORT_C const CRSAPrivateKey & | PrivateKey(void) |
| IMPORT_C const CRSAPublicKey & | PublicKey(void) |
| Protected Member Functions | |
|---|---|
| CRSAKeyPair(void) | |
This class is capable of generating an RSA public/private key pair.
By default, it generates 2 prime (standard) CRT private keys.
| IMPORT_C | ~CRSAKeyPair | ( | void | ) | [virtual] |
The destructor frees all resources owned by the object, prior to its destruction.
| IMPORT_C CRSAKeyPair * | NewL | ( | TUint | aModulusBits, |
| TRSAPrivateKeyType | aKeyType = EStandardCRT | |||
| ) | [static] | |||
Creates a new RSA key pair
| Parameter | Description |
|---|---|
| aModulusBits | The length of the modulus, n (in bits) |
| aKeyType | The type of the RSA key |
Returns: A pointer to a new CRSAKeyPair object
| IMPORT_C CRSAKeyPair * | NewLC | ( | TUint | aModulusBits, |
| TRSAPrivateKeyType | aKeyType = EStandardCRT | |||
| ) | [static] | |||
Creates a new RSA key pair
The returned pointer is put onto the cleanup stack.
| Parameter | Description |
|---|---|
| aModulusBits | The length of the modulus, n (in bits) |
| aKeyType | The type of the RSA key |
Returns: A pointer to a new CRSAKeyPair object
| IMPORT_C const CRSAPrivateKey & | PrivateKey | ( | void | ) | const |
Gets the RSA private key
Returns: A CRSAPrivateKey object
| IMPORT_C const CRSAPublicKey & | PublicKey | ( | void | ) | const |
Gets the RSA public key
Returns: A CRSAPublicKey object