1 #ifndef PACKETPP_SSL_LAYER 2 #define PACKETPP_SSL_LAYER 196 static bool IsSSLMessage(uint16_t srcPort, uint16_t dstPort, uint8_t* data,
size_t dataLen);
255 SSLLayer(uint8_t* data,
size_t dataLen,
Layer* prevLayer,
Packet* packet) :
Layer(data, dataLen, prevLayer, packet) { m_Protocol =
SSL; }
337 template<
class THandshakeMessage>
349 template<
class THandshakeMessage>
383 :
SSLLayer(data, dataLen, prevLayer, packet) {}
415 :
SSLLayer(data, dataLen, prevLayer, packet) {}
457 :
SSLLayer(data, dataLen, prevLayer, packet) {}
482 template<
class THandshakeMessage>
485 size_t vecSize = m_MessageList.size();
486 for (
size_t i = 0; i < vecSize; i++)
489 if (dynamic_cast<THandshakeMessage*>(curElem) != NULL)
490 return (THandshakeMessage*)curElem;
497 template<
class THandshakeMessage>
500 size_t vecSize = m_MessageList.size();
504 for (afterIndex = 0; afterIndex < vecSize; afterIndex++)
507 if (curElem == after)
512 if (afterIndex == vecSize)
515 for (
size_t i = afterIndex+1; i < vecSize; i++)
518 if (dynamic_cast<THandshakeMessage*>(curElem) != NULL)
519 return (THandshakeMessage*)curElem;
void computeCalculateFields()
Definition: SSLLayer.h:436
SSLApplicationDataLayer(uint8_t *data, size_t dataLen, Layer *prevLayer, Packet *packet)
Definition: SSLLayer.h:456
SSLRecordType
Definition: SSLCommon.h:97
static bool IsSSLMessage(uint16_t srcPort, uint16_t dstPort, uint8_t *data, size_t dataLen)
SSLVersion getRecordVersion()
SSLAlertLayer(uint8_t *data, size_t dataLen, Layer *prevLayer, Packet *packet)
Definition: SSLLayer.h:414
Definition: SSLLayer.h:403
Definition: SSLLayer.h:173
OsiModelLayer getOsiModelLayer()
Definition: SSLLayer.h:252
The main namespace for the PcapPlusPlus lib.
THandshakeMessage * getNextHandshakeMessageOfType(SSLHandshakeMessage *after)
Definition: SSLLayer.h:498
size_t getHandshakeMessagesCount()
Definition: SSLLayer.h:371
Definition: ProtocolType.h:131
Definition: SSLCommon.h:22
THandshakeMessage * getHandshakeMessageOfType()
Definition: SSLLayer.h:483
SSLAlertLevel getAlertLevel()
OsiModelLayer
Definition: ProtocolType.h:208
SSLAlertDescription
Definition: SSLCommon.h:173
Definition: PointerVector.h:24
static SSLLayer * createSSLMessage(uint8_t *data, size_t dataLen, Layer *prevLayer, Packet *packet)
Definition: SSLLayer.h:445
void computeCalculateFields()
Definition: SSLLayer.h:479
SSLHandshakeLayer(uint8_t *data, size_t dataLen, Layer *prevLayer, Packet *packet)
Definition: SSLHandshake.h:243
ssl_tls_record_layer * getRecordLayer()
Definition: SSLLayer.h:227
static const std::map< uint16_t, bool > * getSSLPortMap()
static std::string sslVersionToString(SSLVersion ver)
void computeCalculateFields()
Definition: SSLLayer.h:394
Definition: ProtocolType.h:221
void computeCalculateFields()
Definition: SSLLayer.h:359
SSLRecordType getRecordType()
SSLAlertDescription getAlertDescription()
SSLHandshakeMessage * getHandshakeMessageAt(int index)
SSLVersion
Definition: SSLCommon.h:112
SSLChangeCipherSpecLayer(uint8_t *data, size_t dataLen, Layer *prevLayer, Packet *packet)
Definition: SSLLayer.h:382
Definition: SSLLayer.h:306
SSLAlertLevel
Definition: SSLCommon.h:160
size_t getEncrpytedDataLen()
uint8_t * getEncrpytedData()