|
PcapPlusPlus
Next
|
Class for single command text based protocol (FTP, SMTP) messages. More...
#include <SingleCommandTextProtocol.h>
Public Member Functions | |
| bool | isMultiLine () const |
Public Member Functions inherited from pcpp::Layer | |
| ~Layer () override | |
| Layer * | getNextLayer () const |
| Layer * | getPrevLayer () const |
| ProtocolType | getProtocol () const |
| bool | isMemberOfProtocolFamily (ProtocolTypeFamily protocolTypeFamily) const |
| uint8_t * | getData () const |
| size_t | getDataLen () const |
| uint8_t * | getLayerPayload () const |
| size_t | getLayerPayloadSize () const |
| bool | isAllocatedToPacket () const |
| void | copyData (uint8_t *toArr) const |
| uint8_t * | getDataPtr (size_t offset=0) const override |
| virtual void | parseNextLayer ()=0 |
| Each layer is responsible for parsing the next layer. | |
| virtual size_t | getHeaderLen () const =0 |
| virtual void | computeCalculateFields ()=0 |
| Each layer can compute field values automatically using this method. This is an abstract method. | |
| virtual std::string | toString () const =0 |
| virtual OsiModelLayer | getOsiModelLayer () const =0 |
Static Public Member Functions | |
| static bool | isDataValid (const uint8_t *data, size_t dataSize) |
Additional Inherited Members | |
Protected Member Functions inherited from pcpp::Layer | |
| template<typename T , typename... Args> | |
| Layer * | constructNextLayer (uint8_t *data, size_t dataLen, Packet *packet, Args &&... extraArgs) |
| template<typename T , typename TFallback , typename... Args> | |
| Layer * | tryConstructNextLayerWithFallback (uint8_t *data, size_t dataLen, Packet *packet, Args &&... extraArgs) |
Static Protected Member Functions inherited from pcpp::Layer | |
| template<typename T > | |
| static bool | canReinterpretAs (const uint8_t *data, size_t dataLen) |
| Check if the data is large enough to reinterpret as a type. More... | |
Class for single command text based protocol (FTP, SMTP) messages.
|
static |
A static method that takes a byte array and detects whether it is a single command text based message. All single command text based message terminated with single "\r\n".
| [in] | data | A byte array |
| [in] | dataSize | The byte array size (in bytes) |
| bool pcpp::SingleCommandTextProtocol::isMultiLine | ( | ) | const |
Checks if the current message is a multi-line reply. Multi-line messages are indicated with a Hyphen (-) immediately after reply code.