class which represents a asymmetric key pair
More...
#include <KeyPair.hpp>
|
|
| KeyPair () |
| | Constructs an KeyPair
|
| |
|
| KeyPair (const KeyPair &arg)=delete |
| | Copy constructor.
|
| |
|
KeyPair & | operator= (const KeyPair &arg)=delete |
| | Assignment operator.
|
| |
|
virtual | ~KeyPair (void) |
| | Destructs this instance and frees all resources.
|
| |
| EVP_PKEY * | GetPkey () |
| | returns a pointer to the OpenSSL EVP_PKEY* structure initialized with this KeyPair More...
|
| |
| virtual void | LoadFromFile (const String &filename) |
| | Loads the KeyPair from a PEM encoded file filename More...
|
| |
| void | LoadFromMemory (const std::vector< byte > &data) |
| | Loads the KeyPair from memory (PEM encoded) More...
|
| |
| void | InitSslContext (SSL_CTX *pSslCtx) const |
| | Initializes a OpenSSL SSL_CTX structure ith this KeyPair More...
|
| |
| std::vector< byte > | GetPublicKey () |
| | Returns the public key portion of this key pair (PEM format) More...
|
| |
|
KeyPairType | GetKeyType () |
| | Returns the type of this key pair
|
| |
|
void | WriteToFile (const String &filename) |
| | saves this KeyPair to a file in PEM format (the private key is not encrypted!)
|
| |
| void | GenerateKeyPair (KeyPairType type) |
| | Generates a new key pair and replaced the current key pair with the generated More...
|
| |
class which represents a asymmetric key pair
◆ GenerateKeyPair()
| void Arp::System::Commons::Security::KeyPair::GenerateKeyPair |
( |
KeyPairType |
type | ) |
|
Generates a new key pair and replaced the current key pair with the generated
- Parameters
-
| type | type of key to generate |
◆ GetPkey()
| EVP_PKEY * Arp::System::Commons::Security::KeyPair::GetPkey |
( |
| ) |
|
returns a pointer to the OpenSSL EVP_PKEY* structure initialized with this KeyPair
Please Note: pointer is only valid when the KePair is not destroyed
◆ GetPublicKey()
| std::vector< byte > Arp::System::Commons::Security::KeyPair::GetPublicKey |
( |
void |
| ) |
|
Returns the public key portion of this key pair (PEM format)
- Returns
- byte vector with PEM encoded public key
◆ InitSslContext()
| void Arp::System::Commons::Security::KeyPair::InitSslContext |
( |
SSL_CTX * |
pSslCtx | ) |
const |
Initializes a OpenSSL SSL_CTX structure ith this KeyPair
- Parameters
-
| pSslCtx | Pointer to the OpenSSL SSL_CTX structure to initialize |
◆ LoadFromFile()
| void Arp::System::Commons::Security::KeyPair::LoadFromFile |
( |
const String & |
filename | ) |
|
|
virtual |
Loads the KeyPair from a PEM encoded file filename
- Parameters
-
| filename | file from which the KeyPair is loaded. Must be PEM encoded |
◆ LoadFromMemory()
| void Arp::System::Commons::Security::KeyPair::LoadFromMemory |
( |
const std::vector< byte > & |
data | ) |
|
Loads the KeyPair from memory (PEM encoded)
- Parameters
-
| data | byte vector with PEM encoded Key Pair |
The documentation for this class was generated from the following files:
- Arp/System/Commons/Security/KeyPair.hpp
- Arp/System/Commons/Security/KeyPair.cpp