#include <pssl.h>
Inheritance diagram for PSSLPrivateKey:

Public Member Functions | |
| PSSLPrivateKey () | |
| PSSLPrivateKey (unsigned modulus, void(*callback)(int, int, void *)=NULL, void *cb_arg=NULL) | |
| PSSLPrivateKey (const PFilePath &keyFile, PSSLFileTypes fileType=PSSLFileTypeDEFAULT) | |
| PSSLPrivateKey (const BYTE *keyData, PINDEX keySize) | |
| PSSLPrivateKey (const PBYTEArray &keyData) | |
| PSSLPrivateKey (const PSSLPrivateKey &privKey) | |
| PSSLPrivateKey & | operator= (const PSSLPrivateKey &privKay) |
| ~PSSLPrivateKey () | |
| operator evp_pkey_st * () const | |
| PBoolean | Create (unsigned modulus, void(*callback)(int, int, void *)=NULL, void *cb_arg=NULL) |
| PBYTEArray | GetData () const |
| PString | AsString () const |
| PBoolean | Load (const PFilePath &keyFile, PSSLFileTypes fileType=PSSLFileTypeDEFAULT) |
| PBoolean | Save (const PFilePath &keyFile, PBoolean append=PFalse, PSSLFileTypes fileType=PSSLFileTypeDEFAULT) |
Protected Attributes | |
| evp_pkey_st * | key |
| PSSLPrivateKey::PSSLPrivateKey | ( | ) |
Create an empty private key.
| PSSLPrivateKey::PSSLPrivateKey | ( | unsigned | modulus, | |
| void(*)(int, int, void *) | callback = NULL, |
|||
| void * | cb_arg = NULL | |||
| ) |
Create a new RSA private key.
| modulus | Number of bits |
| callback | Progress callback function |
| cb_arg | Argument passed to callback |
| PSSLPrivateKey::PSSLPrivateKey | ( | const PFilePath & | keyFile, | |
| PSSLFileTypes | fileType = PSSLFileTypeDEFAULT | |||
| ) |
Create a new private key given the file. The type of the private key can be specified explicitly, or if PSSLFileTypeDEFAULT it will be determined from the file extension, ".pem" is a text file, anything else eg ".der" is a binary ASN1 file.
| keyFile | Private key file |
| fileType | Type of file to read |
| PSSLPrivateKey::PSSLPrivateKey | ( | const BYTE * | keyData, | |
| PINDEX | keySize | |||
| ) |
Create private key from the binary ASN1 DER encoded data specified.
| keyData | Private key data |
| keySize | Size of private key data |
| PSSLPrivateKey::PSSLPrivateKey | ( | const PBYTEArray & | keyData | ) |
Create private key from the binary ASN1 DER encoded data specified.
| keyData | Private key data |
| PSSLPrivateKey::PSSLPrivateKey | ( | const PSSLPrivateKey & | privKey | ) |
Create a copy of the private key.
| PSSLPrivateKey::~PSSLPrivateKey | ( | ) |
Destroy and release storage for private key.
| PSSLPrivateKey& PSSLPrivateKey::operator= | ( | const PSSLPrivateKey & | privKay | ) |
Create a copy of the private key.
| PSSLPrivateKey::operator evp_pkey_st * | ( | ) | const [inline] |
Get internal OpenSSL private key structure.
| PBoolean PSSLPrivateKey::Create | ( | unsigned | modulus, | |
| void(*)(int, int, void *) | callback = NULL, |
|||
| void * | cb_arg = NULL | |||
| ) |
Create a new private key.
| modulus | Number of bits |
| callback | Progress callback function |
| cb_arg | Argument passed to callback |
| PBYTEArray PSSLPrivateKey::GetData | ( | ) | const |
Get the certificate as binary ASN1 DER encoded data.
| PString PSSLPrivateKey::AsString | ( | ) | const |
Get the certificate as ASN1 DER base64 encoded data.
| PBoolean PSSLPrivateKey::Load | ( | const PFilePath & | keyFile, | |
| PSSLFileTypes | fileType = PSSLFileTypeDEFAULT | |||
| ) |
Load private key from file. The type of the private key can be specified explicitly, or if PSSLFileTypeDEFAULT it will be determined from the file extension, ".pem" is a text file, anything else eg ".der" is a binary ASN1 file.
| keyFile | Private key file |
| fileType | Type of file to read |
| PBoolean PSSLPrivateKey::Save | ( | const PFilePath & | keyFile, | |
| PBoolean | append = PFalse, |
|||
| PSSLFileTypes | fileType = PSSLFileTypeDEFAULT | |||
| ) |
Save private key to file. The type of the private key can be specified explicitly, or if PSSLFileTypeDEFAULT it will be determined from the file extension, ".pem" is a text file, anything else eg ".der" is a binary ASN1 file.
| keyFile | Private key file |
| append | Append to file |
| fileType | Type of file to write |
evp_pkey_st* PSSLPrivateKey::key [protected] |
1.5.1