xorp

IoIpReceiver Class Reference

A base class for I/O IP raw packets receiver. More...

#include <io_ip.hh>

Inheritance diagram for IoIpReceiver:
IoIpComm

List of all members.

Public Member Functions

 IoIpReceiver ()
 Default constructor.
virtual ~IoIpReceiver ()
 Virtual destructor.
virtual void recv_packet (const string &if_name, const string &vif_name, const IPvX &src_address, const IPvX &dst_address, int32_t ip_ttl, int32_t ip_tos, bool ip_router_alert, bool ip_internet_control, const vector< uint8_t > &ext_headers_type, const vector< vector< uint8_t > > &ext_headers_payload, const vector< uint8_t > &payload)=0
 Received a raw IP packet.
virtual void recv_system_multicast_upcall (const vector< uint8_t > &payload)=0
 Received a multicast forwarding related upcall from the system.

Detailed Description

A base class for I/O IP raw packets receiver.

The real receiver must inherit from this class and register with the corresponding IoIp entity to receive the raw IP packets.

See also:
IoIp.

Member Function Documentation

virtual void IoIpReceiver::recv_packet ( const string &  if_name,
const string &  vif_name,
const IPvX src_address,
const IPvX dst_address,
int32_t  ip_ttl,
int32_t  ip_tos,
bool  ip_router_alert,
bool  ip_internet_control,
const vector< uint8_t > &  ext_headers_type,
const vector< vector< uint8_t > > &  ext_headers_payload,
const vector< uint8_t > &  payload 
) [pure virtual]

Received a raw IP packet.

Parameters:
if_namethe interface name the packet arrived on.
vif_namethe vif name the packet arrived on.
src_addressthe IP source address.
dst_addressthe IP destination address.
ip_ttlthe IP TTL (hop-limit). If it has a negative value, then the received value is unknown.
ip_tosThe type of service (Diffserv/ECN bits for IPv4). If it has a negative value, then the received value is unknown.
ip_router_alertif true, the IP Router Alert option was included in the IP packet.
ip_internet_controlif true, then this is IP control traffic.
ext_headers_typea vector of integers with the types of the optional IPv6 extention headers.
ext_headers_payloada vector of payload data, one for each optional IPv6 extention header. The number of entries must match ext_headers_type.
packetthe payload, everything after the IP header and options.

Implemented in IoIpComm.

virtual void IoIpReceiver::recv_system_multicast_upcall ( const vector< uint8_t > &  payload) [pure virtual]

Received a multicast forwarding related upcall from the system.

Examples of such upcalls are: "nocache", "wrongiif", "wholepkt", "bw_upcall".

Parameters:
payloadthe payload data for the upcall.

Implemented in IoIpComm.


The documentation for this class was generated from the following file:
 All Classes Namespaces Functions Variables Typedefs Enumerations