|
| | GeneveLayer (uint8_t *data, size_t dataLen, Layer *prevLayer, Packet *packet) |
| |
| | GeneveLayer (uint32_t vni=0, uint16_t protocolType=0x6558, bool oamFlag=false) |
| |
| uint32_t | getVNI () const |
| |
| void | setVNI (uint32_t vni) |
| |
| uint16_t | getProtocolType () const |
| |
| void | setProtocolType (uint16_t protocolType) |
| |
| bool | getOamFlag () const |
| |
| void | setOamFlag (bool value) |
| |
| bool | getCriticalFlag () const |
| |
| size_t | getOptionsLength () const |
| |
| size_t | getOptionCount () const |
| |
| GeneveOption | getFirstOption () const |
| |
| GeneveOption | getNextOption (const GeneveOption &option) const |
| |
| GeneveOption | getOption (uint16_t optionClass, uint8_t optionType) const |
| |
| bool | addOption (uint16_t optionClass, uint8_t optionType, const uint8_t *optionData, size_t optionDataLen, bool critical=false) |
| |
| bool | removeOption (uint16_t optionClass, uint8_t optionType) |
| |
| bool | removeAllOptions () |
| |
| void | parseNextLayer () override |
| |
| size_t | getHeaderLen () const override |
| |
|
void | computeCalculateFields () override |
| | Update the Protocol Type and Critical flag from the following layer and options.
|
| |
| std::string | toString () const override |
| |
| OsiModelLayer | getOsiModelLayer () const override |
| |
| | ~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 |
| | Copy the raw data of this layer to another array. More...
|
| |
| size_t | copyData (uint8_t *dest, size_t destSize) const |
| | Copy the raw data of this layer to another array, with a specified maximum size. More...
|
| |
| void | serialize (ISerializer &serializer) const |
| |
| uint8_t * | getDataPtr (size_t offset=0) const override |
| |
|
| void | serializeLayer (ObjectScope &serializer) const override |
| |
| Packet * | getAttachedPacket () |
| | Get a pointer to the Packet this layer is attached to (if any). More...
|
| |
| Packet const * | getAttachedPacket () const |
| | Get a pointer to the Packet this layer is attached to (if any). More...
|
| |
| void | allocData (size_t dataLen, bool zeroInit=true) |
| | Requests the layer to allocate a new data buffer of the specified length. More...
|
| |
| template<typename T , typename... Args> |
| Layer * | constructNextLayer (uint8_t *data, size_t dataLen, Args &&... extraArgs) |
| | Construct the next layer in the protocol stack. No validation is performed on the data. More...
|
| |
| template<typename T , typename... Args> |
| Layer * | constructNextLayer (uint8_t *data, size_t dataLen, Packet *packet, Args &&... extraArgs) |
| |
| template<typename TFactory , typename... Args> |
| Layer * | constructNextLayerFromFactory (TFactory factoryFn, uint8_t *data, size_t dataLen, Args &&... extraArgs) |
| | Construct the next layer in the protocol stack using a factory functor. More...
|
| |
| template<typename TFactory , typename... Args> |
| Layer * | constructNextLayerFromFactory (TFactory factoryFn, uint8_t *data, size_t dataLen, Packet *packet, Args &&... extraArgs) |
| | Construct the next layer in the protocol stack using a factory functor. More...
|
| |
| template<typename T , typename... Args> |
| Layer * | tryConstructNextLayer (uint8_t *data, size_t dataLen, Args &&... extraArgs) |
| |
| template<typename T , typename... Args> |
| Layer * | tryConstructNextLayer (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, Args &&... extraArgs) |
| | Try to construct the next layer in the protocol stack with a fallback option. More...
|
| |
| template<typename T , typename TFallback , typename... Args> |
| Layer * | tryConstructNextLayerWithFallback (uint8_t *data, size_t dataLen, Packet *packet, Args &&... extraArgs) |
| |
| template<typename TFallback , typename TFactory , typename... Args> |
| Layer * | tryConstructNextLayerFromFactoryWithFallback (TFactory factoryFn, uint8_t *data, size_t dataLen, Args &&... extraArgs) |
| | Try to construct the next layer in the protocol stack using a factory functor with a fallback option. More...
|
| |
| template<typename TFallback , typename TFactory , typename... Args> |
| Layer * | tryConstructNextLayerFromFactoryWithFallback (TFactory factoryFn, uint8_t *data, size_t dataLen, Packet *packet, Args &&... extraArgs) |
| | Try to construct the next layer in the protocol stack using a factory functor with a fallback option. More...
|
| |
Represents a GENEVE (Generic Network Virtualization Encapsulation) protocol layer. Layer methods assume that the fixed header and its declared options area are complete. Data passed to the raw-data constructor must first pass isDataValid(); crafted layers establish this layout internally. Callers modifying raw layer data must preserve this layout. Individual options may still be malformed and are checked during traversal.