26 static_assert(
sizeof(
ether_dot3_header) == 14,
"ether_dot3_header size is not 14 bytes");
Definition: EthDot3Layer.h:31
EthDot3Layer(uint8_t *data, size_t dataLen, Layer *prevLayer, Packet *packet)
Definition: EthDot3Layer.h:46
size_t getHeaderLen() const override
Definition: EthDot3Layer.h:100
void setDestMac(const MacAddress &destMac)
Definition: EthDot3Layer.h:89
MacAddress getSourceMac() const
Definition: EthDot3Layer.h:68
EthDot3Layer(uint8_t *data, size_t dataLen, Packet *packet)
Definition: EthDot3Layer.h:37
MacAddress getDestMac() const
Definition: EthDot3Layer.h:82
std::string toString() const override
OsiModelLayer getOsiModelLayer() const override
Definition: EthDot3Layer.h:111
static bool isDataValid(const uint8_t *data, size_t dataLen)
void computeCalculateFields() override
Does nothing for this layer.
Definition: EthDot3Layer.h:106
EthDot3Layer(const MacAddress &sourceMac, const MacAddress &destMac, uint16_t length)
void setSourceMac(const MacAddress &sourceMac)
Definition: EthDot3Layer.h:75
void parseNextLayer() override
Parses next layer.
ether_dot3_header * getEthHeader() const
Definition: EthDot3Layer.h:61
Definition: MacAddress.h:21
void copyTo(uint8_t **arr) const
Definition: MacAddress.h:130
The main namespace for the PcapPlusPlus lib.
OsiModelLayer
An enum representing OSI model layers.
Definition: ProtocolType.h:225
@ OsiModelDataLinkLayer
Data link layer (layer 2)
Definition: ProtocolType.h:229
const ProtocolType EthernetDot3
IEEE 802.3 Ethernet protocol.
Definition: ProtocolType.h:140