PcapPlusPlus  20.08+
pcpp::SSLx509Certificate Class Reference

#include <SSLHandshake.h>

Public Member Functions

 SSLx509Certificate (uint8_t *data, size_t dataLen, bool allDataExists)
 
uint8_t * getData () const
 
size_t getDataLength () const
 
bool allDataExists () const
 

Detailed Description

Represents a x509v3 certificate. the SSLCertificateMessage class returns an instance of this class as the certificate. Currently this class doesn't do much as it doesn't parse the certificate. It only acts as container to the raw data and returns general info as data as raw, length, etc. In the future I may add full parsing of the certificate

Constructor & Destructor Documentation

◆ SSLx509Certificate()

pcpp::SSLx509Certificate::SSLx509Certificate ( uint8_t *  data,
size_t  dataLen,
bool  allDataExists 
)
inline

C'tor for this class

Parameters
[in]dataThe raw data of the certificate
[in]dataLenThe length in bytes of the raw data
[in]allDataExistsCertificate messages usually spread on more than 1 packet. So a certificate is likely to split between 2 packets or more. This field indicates whether the raw data contains all ceritificate data of just a part of it

Member Function Documentation

◆ allDataExists()

bool pcpp::SSLx509Certificate::allDataExists ( ) const
inline

Certificate messages usually spread on more than 1 packet. So a certificate is likely to split between 2 packets or more. This method provides an indication whether all certificate data exists or only part of it

Returns
True if this data contains all certificate data, false otherwise

◆ getData()

uint8_t* pcpp::SSLx509Certificate::getData ( ) const
inline
Returns
A pointer to the raw data

◆ getDataLength()

size_t pcpp::SSLx509Certificate::getDataLength ( ) const
inline
Returns
Raw data length