PcapPlusPlus
21.05
|
#include <BgpLayer.h>
Classes | |
struct | bgp_route_refresh_message |
Public Member Functions | |
BgpRouteRefreshMessageLayer (uint8_t *data, size_t dataLen, Layer *prevLayer, Packet *packet) | |
BgpRouteRefreshMessageLayer (uint16_t afi, uint8_t safi) | |
bgp_route_refresh_message * | getRouteRefreshHeader () const |
BgpMessageType | getBgpMessageType () const |
Public Member Functions inherited from pcpp::BgpLayer | |
std::string | getMessageTypeAsString () const |
size_t | getHeaderLen () const |
void | parseNextLayer () |
std::string | toString () const |
OsiModelLayer | getOsiModelLayer () const |
void | computeCalculateFields () |
Public Member Functions inherited from pcpp::Layer | |
virtual | ~Layer () |
Layer * | getNextLayer () const |
Layer * | getPrevLayer () const |
ProtocolType | getProtocol () 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 |
Additional Inherited Members | |
Public Types inherited from pcpp::BgpLayer | |
enum | BgpMessageType { Open = 1, Update = 2, Notification = 3, Keepalive = 4, RouteRefresh = 5 } |
Static Public Member Functions inherited from pcpp::BgpLayer | |
static bool | isBgpPort (uint16_t portSrc, uint16_t portDst) |
static BgpLayer * | parseBgpLayer (uint8_t *data, size_t dataLen, Layer *prevLayer, Packet *packet) |
Represents a BGP v4 ROUTE-REFRESH message
|
inline |
A constructor that creates the layer from an existing packet raw data
[in] | data | A pointer to the raw data |
[in] | dataLen | Size of the data in bytes |
[in] | prevLayer | A pointer to the previous layer |
[in] | packet | A pointer to the Packet instance where layer will be stored in |
pcpp::BgpRouteRefreshMessageLayer::BgpRouteRefreshMessageLayer | ( | uint16_t | afi, |
uint8_t | safi | ||
) |
A c'tor that creates a new BGP ROUTE-REFRESH message
[in] | afi | The Address Family Identifier (AFI) value to set in the message |
[in] | safi | The Subsequent Address Family Identifier (SAFI) value to set in the message |
|
inlinevirtual |
Implements pcpp::BgpLayer.
|
inline |
Get a pointer to the ROUTE-REFRESH message data. Notice this points directly to the data, so any change will modify the actual packet data