#include <certificatecontroller.h>
Inheritance diagram for openikev2::CertificateController:

Public Member Functions | |
| virtual auto_ptr< Certificate > | payloadToCertificate (const Payload_CERT &peer_certificate) const=0 |
| Generates a concrete Certificate object from a Payload_CERT payload. | |
| virtual auto_ptr< Payload_CERT_REQ > | getCertificateRequest () const=0 |
| Generates the adecuated Payload_CERT_REQ to be sent. | |
| virtual auto_ptr< Certificate > | getCertificate (const Payload_CERT_REQ *certificate_request, bool peer_supports_hash_url) const =0 |
| Obtains the adecuates Certificate from the CertificateController matching the received Payload_CERT_REQ. | |
| virtual auto_ptr< CertificateController > | clone () const=0 |
| Clones the complete CertificateController instance. | |
| virtual auto_ptr< Certificate > | getPeerCertificate (const ID &peer_id) const=0 |
| Finds a peer certificate based on its Payload_ID. | |
| virtual bool | verifyCertificate (const ID &peer_id, const Payload_CERT &payload_cert) const=0 |
| Verifies if the certificate is valid. | |
| virtual string | toStringTab (uint8_t tabs) const =0 |
| Construct a textual representation of the object, preceded of a num of tabs of size TAB_SIZE. | |
This class manages all the certificate related issues
| virtual auto_ptr<Certificate> openikev2::CertificateController::payloadToCertificate | ( | const Payload_CERT & | peer_certificate | ) | const [pure virtual] |
Generates a concrete Certificate object from a Payload_CERT payload.
The resultant certificate hasn't private key field, so it can't be used to sign. It only can be used to verify signatures.
| peer_certificate | Received Payload_CERT |
| virtual auto_ptr<Payload_CERT_REQ> openikev2::CertificateController::getCertificateRequest | ( | ) | const [pure virtual] |
Generates the adecuated Payload_CERT_REQ to be sent.
| virtual auto_ptr<Certificate> openikev2::CertificateController::getCertificate | ( | const Payload_CERT_REQ * | certificate_request, | |
| bool | peer_supports_hash_url | |||
| ) | const [pure virtual] |
Obtains the adecuates Certificate from the CertificateController matching the received Payload_CERT_REQ.
| certificate_request | Received Payload_CERT_REQ. This paramenter may be NULL if peer doesn't send any Payload_CERT_REQ. | |
| peer_supports_hash_url | Indicates if the peer supports HASH and URL |
| virtual auto_ptr<CertificateController> openikev2::CertificateController::clone | ( | ) | const [pure virtual] |
Clones the complete CertificateController instance.
| virtual auto_ptr<Certificate> openikev2::CertificateController::getPeerCertificate | ( | const ID & | peer_id | ) | const [pure virtual] |
Finds a peer certificate based on its Payload_ID.
This method is called when peer didn't send any Payload_CERT and one is needed to verify the Payload_AUTH data.
| peer_id | Peer ID. |
| virtual bool openikev2::CertificateController::verifyCertificate | ( | const ID & | peer_id, | |
| const Payload_CERT & | payload_cert | |||
| ) | const [pure virtual] |
Verifies if the certificate is valid.
| peer_id | Peer ID. | |
| payload_cert | Received Payload_CERT. |
| virtual string openikev2::CertificateController::toStringTab | ( | uint8_t | tabs | ) | const [pure virtual] |
Construct a textual representation of the object, preceded of a num of tabs of size TAB_SIZE.
| tabs | Num of tabs preceding the textual representation. |
Implements openikev2::Printable.
1.5.1