Skip to main content

ERUCES::TECertAndPKey

#include <tecert_pkey.h>

The TECertAndPKey class is used for TLS mutual authentication.

The TECertAndPKey represents an authentication context used for TLS Mutual connection. This class is derived from TEAuthenticationContext class.

Private Attrib

TypeNameDescription
_TESTD string *_cert
_TESTD string *_pkey

Public Member Functions

MemberDescription
TECertAndPKey()The TECertAndPKey constructor is the default class constructor.
~TECertAndPKey()The TECertAndPKey constructor is the class destructor.
void loadFromFile(_TESTD string &pkcs7file, _TESTD string &pkcs8file, _TESTD string &passwd)
void loadFromX509File(const _TESTD string &x509file)The loadFromX509File method loads the certificate information from a X.509 file.
_TESTD string getCertificate()The getCertificate method retrieves a string representing the certficate.
_TESTD string getPrivateKey()The getPrivateKey method retrieves a string representing the private key.

Member Function Documentation

TECertAndPKey()

The TECertAndPKey constructor is the default class constructor.

~TECertAndPKey()

The TECertAndPKey constructor is the class destructor.

void loadFromFile(_TESTD string &pkcs7file, _TESTD string &pkcs8file, _TESTD string &passwd)

The loadFromFile method loads the certificate information from a file.

Parameters

ParameterDescription
pkcs7fileA PKCS 7 file to load
pkcs8fileA PKCS 8 file to load.
passwdThe password to unload the private key.

void loadFromX509File(const _TESTD string &x509file)

The loadFromX509File method loads the certificate information from a X.509 file.

Parameters

ParameterDescription
x509fileAn X.509 file to load.

_TESTD string getCertificate()

The getCertificate method retrieves a string representing the certficate.

_TESTD string getPrivateKey()

The getPrivateKey method retrieves a string representing the private key.