|
| | IcmpLayer (uint8_t *data, size_t dataLen, Layer *prevLayer, Packet *packet) |
| |
| | IcmpLayer () |
| |
| icmphdr * | getIcmpHeader () const |
| |
| IcmpMessageType | getMessageType () const |
| |
| bool | isMessageOfType (IcmpMessageType type) const |
| |
| icmp_echo_request * | getEchoRequestData () |
| |
| icmp_echo_request * | setEchoRequestData (uint16_t id, uint16_t sequence, uint64_t timestamp, const uint8_t *data, size_t dataLen) |
| |
| icmp_echo_reply * | getEchoReplyData () |
| |
| icmp_echo_reply * | setEchoReplyData (uint16_t id, uint16_t sequence, uint64_t timestamp, const uint8_t *data, size_t dataLen) |
| |
| icmp_timestamp_request * | getTimestampRequestData () |
| |
| icmp_timestamp_request * | setTimestampRequestData (uint16_t id, uint16_t sequence, timeval originateTimestamp) |
| |
| icmp_timestamp_reply * | getTimestampReplyData () |
| |
| icmp_timestamp_reply * | setTimestampReplyData (uint16_t id, uint16_t sequence, timeval originateTimestamp, timeval receiveTimestamp, timeval transmitTimestamp) |
| |
| icmp_destination_unreachable * | getDestUnreachableData () |
| |
| icmp_destination_unreachable * | setDestUnreachableData (IcmpDestUnreachableCodes code, uint16_t nextHopMTU, IPv4Layer *ipHeader, Layer *l4Header) |
| |
| icmp_source_quench * | getSourceQuenchdata () |
| |
| icmp_source_quench * | setSourceQuenchdata (IPv4Layer *ipHeader, Layer *l4Header) |
| |
| icmp_redirect * | getRedirectData () |
| |
| icmp_redirect * | setRedirectData (uint8_t code, IPv4Address gatewayAddress, IPv4Layer *ipHeader, Layer *l4Header) |
| |
| icmp_router_advertisement * | getRouterAdvertisementData () const |
| |
| icmp_router_advertisement * | setRouterAdvertisementData (uint8_t code, uint16_t lifetimeInSeconds, const std::vector< icmp_router_address_structure > &routerAddresses) |
| |
| icmp_router_solicitation * | getRouterSolicitationData () |
| |
| icmp_router_solicitation * | setRouterSolicitationData () |
| |
| icmp_time_exceeded * | getTimeExceededData () |
| |
| icmp_time_exceeded * | setTimeExceededData (uint8_t code, IPv4Layer *ipHeader, Layer *l4Header) |
| |
| icmp_param_problem * | getParamProblemData () |
| |
| icmp_param_problem * | setParamProblemData (uint8_t code, uint8_t errorOctetPointer, IPv4Layer *ipHeader, Layer *l4Header) |
| |
| icmp_address_mask_request * | getAddressMaskRequestData () |
| |
| icmp_address_mask_request * | setAddressMaskRequestData (uint16_t id, uint16_t sequence, IPv4Address mask) |
| |
| icmp_address_mask_reply * | getAddressMaskReplyData () |
| |
| icmp_address_mask_reply * | setAddressMaskReplyData (uint16_t id, uint16_t sequence, IPv4Address mask) |
| |
| icmp_info_request * | getInfoRequestData () |
| |
| icmp_info_request * | setInfoRequestData (uint16_t id, uint16_t sequence) |
| |
| icmp_info_reply * | getInfoReplyData () |
| |
| icmp_info_reply * | setInfoReplyData (uint16_t id, uint16_t sequence) |
| |
| void | parseNextLayer () override |
| |
| size_t | getHeaderLen () const override |
| |
|
void | computeCalculateFields () override |
| | Calculate ICMP checksum field.
|
| |
| 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...
|
| |
| uint8_t * | getDataPtr (size_t offset=0) 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...
|
| |
| 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...
|
| |
Represents an ICMP protocol layer (for IPv4 only)