PcapPlusPlus  19.12
pcpp::SSLExtension Class Reference

#include <SSLHandshake.h>

Inheritance diagram for pcpp::SSLExtension:
pcpp::SSLServerNameIndicationExtension

Classes

struct  SSLExtensionStruct
 

Public Member Functions

 SSLExtension (uint8_t *data)
 
SSLExtensionType getType () const
 
uint16_t getTypeAsInt () const
 
uint16_t getLength () const
 
uint16_t getTotalLength () const
 
uint8_t * getData () const
 

Detailed Description

Represents a SSL/TLS extension. This is a base class that can represent any type of extension. Inherited classes may contain parsing logic for specific extensions. This class provides capabilities such as getting the extension type, length and viewing the extension data as raw (byte array)

Constructor & Destructor Documentation

◆ SSLExtension()

pcpp::SSLExtension::SSLExtension ( uint8_t *  data)

C'tor for this class

Parameters
[in]dataThe raw data for the extension

Member Function Documentation

◆ getData()

uint8_t* pcpp::SSLExtension::getData ( ) const
Returns
A pointer to the raw data of the extension

◆ getLength()

uint16_t pcpp::SSLExtension::getLength ( ) const
Returns
The length of the extension data in bytes (not including the type and length fields)

◆ getTotalLength()

uint16_t pcpp::SSLExtension::getTotalLength ( ) const
Returns
The total length of the extension, including type and length fields and the extension data field

◆ getType()

SSLExtensionType pcpp::SSLExtension::getType ( ) const
Returns
The type of the extension as enum

◆ getTypeAsInt()

uint16_t pcpp::SSLExtension::getTypeAsInt ( ) const
Returns
The type of the extension as a numeric value