xorp

XrlOlsr4Target Class Reference

Concrete implementation of OLSRv1/IPv4 XRL target. More...

#include <xrl_target.hh>

Inheritance diagram for XrlOlsr4Target:
XrlOlsr4TargetBase

List of all members.

Public Member Functions

 XrlOlsr4Target (XrlRouter *r, Olsr &olsr, XrlIO &xrl_io)
 Constructor.
XrlCmdError common_0_1_get_target_name (string &name)
 Get name of Xrl Target.
XrlCmdError common_0_1_get_version (string &version)
 Get version string from Xrl Target.
XrlCmdError common_0_1_get_status (uint32_t &status, string &reason)
 Get status of Xrl Target.
XrlCmdError common_0_1_shutdown ()
 Request clean shutdown of Xrl Target.
XrlCmdError common_0_1_startup ()
 Pure-virtual function that needs to be implemented to:
XrlCmdError finder_event_observer_0_1_xrl_target_birth (const string &target_class, const string &target_instance)
 Announce target birth to observer.
XrlCmdError finder_event_observer_0_1_xrl_target_death (const string &target_class, const string &target_instance)
 Announce target death to observer.
XrlCmdError socket4_user_0_1_recv_event (const string &sockid, const string &if_name, const string &vif_name, const IPv4 &src_host, const uint32_t &src_port, const vector< uint8_t > &data)
 Method invoked by target implementing socket4/0.1 when a packet arrives from an IPv4 source.
XrlCmdError socket4_user_0_1_inbound_connect_event (const string &sockid, const IPv4 &src_host, const uint32_t &src_port, const string &new_sockid, bool &accept)
 Method invoked by target implementing socket4/0.1 when a connection request is received from an IPv4 source.
XrlCmdError socket4_user_0_1_outgoing_connect_event (const string &sockid)
 Method invoked by target implementing socket4/0.1 when an outgoing connection request originated by the local host is completed.
XrlCmdError socket4_user_0_1_error_event (const string &sockid, const string &error, const bool &fatal)
 Method invoked by target implementing socket4/0.1 when an error occurs.
XrlCmdError socket4_user_0_1_disconnect_event (const string &sockid)
 Method invoked by target implementing socket4/0.1 when the peer has closed the connection.
XrlCmdError policy_backend_0_1_configure (const uint32_t &filter, const string &conf)
 Configure a policy filter.
XrlCmdError policy_backend_0_1_reset (const uint32_t &filter)
 Reset a policy filter.
XrlCmdError policy_backend_0_1_push_routes ()
 Push all available routes through all filters for re-filtering.
XrlCmdError policy_redist4_0_1_add_route4 (const IPv4Net &network, const bool &unicast, const bool &multicast, const IPv4 &nexthop, const uint32_t &metric, const XrlAtomList &policytags)
 Start route redistribution for an IPv4 route.
XrlCmdError policy_redist4_0_1_delete_route4 (const IPv4Net &network, const bool &unicast, const bool &multicast)
 Terminate route redistribution for an IPv4 route.
XrlCmdError profile_0_1_enable (const string &pname)
 Enable profiling.
XrlCmdError profile_0_1_disable (const string &pname)
 Disable profiling.
XrlCmdError profile_0_1_get_entries (const string &pname, const string &instance_name)
 Get log entries.
XrlCmdError profile_0_1_clear (const string &pname)
 Clear the profiling entries.
XrlCmdError profile_0_1_list (string &info)
 List all the profiling variables registered with this target.
XrlCmdError olsr4_0_1_trace (const string &tvar, const bool &enable)
 Enable/Disable tracing.
XrlCmdError olsr4_0_1_clear_database ()
 Clear all OLSR protocol databases.
XrlCmdError olsr4_0_1_set_willingness (const uint32_t &willingness)
 Set the willingness-to-forward.
XrlCmdError olsr4_0_1_get_willingness (uint32_t &willingness)
 Get the willingness-to-forward.
XrlCmdError olsr4_0_1_set_mpr_coverage (const uint32_t &coverage)
 Set the MPR_COVERAGE.
XrlCmdError olsr4_0_1_get_mpr_coverage (uint32_t &coverage)
 Get the MPR_COVERAGE.
XrlCmdError olsr4_0_1_set_tc_redundancy (const string &redundancy)
 Set the TC_REDUNDANCY.
XrlCmdError olsr4_0_1_get_tc_redundancy (string &redundancy)
 Get the TC_REDUNDANCY.
XrlCmdError olsr4_0_1_set_tc_fisheye (const bool &enabled)
 Enable/disable TC fisheye mode.
XrlCmdError olsr4_0_1_get_tc_fisheye (bool &enabled)
 Get the current TC fisheye mode.
XrlCmdError olsr4_0_1_set_hna_base_cost (const uint32_t &metric)
 Set the current HNA base cost metric.
XrlCmdError olsr4_0_1_get_hna_base_cost (uint32_t &metric)
 Get the current HNA base cost metric.
XrlCmdError olsr4_0_1_set_hello_interval (const uint32_t &interval)
 Set the HELLO_INTERVAL.
XrlCmdError olsr4_0_1_get_hello_interval (uint32_t &interval)
 Get the HELLO_INTERVAL.
XrlCmdError olsr4_0_1_set_refresh_interval (const uint32_t &interval)
 Set the REFRESH_INTERVAL.
XrlCmdError olsr4_0_1_get_refresh_interval (uint32_t &interval)
 Get the REFRESH_INTERVAL.
XrlCmdError olsr4_0_1_set_tc_interval (const uint32_t &interval)
 Set the TC_INTERVAL.
XrlCmdError olsr4_0_1_get_tc_interval (uint32_t &interval)
 Get the TC_INTERVAL.
XrlCmdError olsr4_0_1_set_mid_interval (const uint32_t &interval)
 Set the MID_INTERVAL.
XrlCmdError olsr4_0_1_get_mid_interval (uint32_t &interval)
 Get the MID_INTERVAL.
XrlCmdError olsr4_0_1_set_hna_interval (const uint32_t &interval)
 Set the HNA_INTERVAL.
XrlCmdError olsr4_0_1_get_hna_interval (uint32_t &interval)
 Get the HNA_INTERVAL.
XrlCmdError olsr4_0_1_set_dup_hold_time (const uint32_t &dup_hold_time)
 Set the DUP_HOLD_TIME.
XrlCmdError olsr4_0_1_get_dup_hold_time (uint32_t &dup_hold_time)
 Get the DUP_HOLD_TIME.
XrlCmdError olsr4_0_1_set_main_address (const IPv4 &addr)
 Set the main address.
XrlCmdError olsr4_0_1_get_main_address (IPv4 &addr)
 Get the main address.
XrlCmdError olsr4_0_1_bind_address (const string &ifname, const string &vifname, const IPv4 &local_addr, const uint32_t &local_port, const IPv4 &all_nodes_addr, const uint32_t &all_nodes_port)
 Create an IPv4 address binding for OLSR.
XrlCmdError olsr4_0_1_unbind_address (const string &ifname, const string &vifname)
 Destroy an IPv4 address binding for OLSR.
XrlCmdError olsr4_0_1_set_binding_enabled (const string &ifname, const string &vifname, const bool &enabled)
 Set the enabled state of an IPv4 address binding for OLSR.
XrlCmdError olsr4_0_1_get_binding_enabled (const string &ifname, const string &vifname, bool &enabled)
 Get the state of an IPv4 address binding for OLSR.
XrlCmdError olsr4_0_1_change_local_addr_port (const string &ifname, const string &vifname, const IPv4 &local_addr, const uint32_t &local_port)
 Change the UDP address and port where OLSR listens for control traffic on this interface.
XrlCmdError olsr4_0_1_change_all_nodes_addr_port (const string &ifname, const string &vifname, const IPv4 &all_nodes_addr, const uint32_t &all_nodes_port)
 Change the address where OLSR sends control traffic on the given interface.
XrlCmdError olsr4_0_1_get_interface_list (XrlAtomList &interfaces)
 Get the list of interfaces currently configured for OLSR.
XrlCmdError olsr4_0_1_get_interface_info (const uint32_t &faceid, string &ifname, string &vifname, IPv4 &local_addr, uint32_t &local_port, IPv4 &all_nodes_addr, uint32_t &all_nodes_port)
 Get the per-interface information for the given interface.
XrlCmdError olsr4_0_1_set_interface_cost (const string &ifname, const string &vifname, const uint32_t &cost)
 Set the edge cost of an interface/vif.
XrlCmdError olsr4_0_1_get_interface_stats (const string &ifname, const string &vifname, uint32_t &bad_packets, uint32_t &bad_messages, uint32_t &messages_from_self, uint32_t &unknown_messages, uint32_t &duplicates, uint32_t &forwarded)
 Get the per-interface statistics for the given interface.
XrlCmdError olsr4_0_1_get_link_list (XrlAtomList &links)
 Get the list of one-hop links.
XrlCmdError olsr4_0_1_get_link_info (const uint32_t &linkid, IPv4 &local_addr, IPv4 &remote_addr, IPv4 &main_addr, uint32_t &link_type, uint32_t &sym_time, uint32_t &asym_time, uint32_t &hold_time)
 Get the information for a one-hop link.
XrlCmdError olsr4_0_1_get_neighbor_list (XrlAtomList &neighbors)
 Get the list of one-hop neighbors.
XrlCmdError olsr4_0_1_get_neighbor_info (const uint32_t &nid, IPv4 &main_addr, uint32_t &willingness, uint32_t &degree, uint32_t &link_count, uint32_t &twohop_link_count, bool &is_advertised, bool &is_sym, bool &is_mpr, bool &is_mpr_selector)
 Get the information for a one-hop neighbor.
XrlCmdError olsr4_0_1_get_twohop_link_list (XrlAtomList &twohop_links)
 Get the list of two-hop links.
XrlCmdError olsr4_0_1_get_twohop_link_info (const uint32_t &tlid, uint32_t &last_face_id, IPv4 &nexthop_addr, IPv4 &dest_addr, uint32_t &hold_time)
 Get the information for a two-hop link.
XrlCmdError olsr4_0_1_get_twohop_neighbor_list (XrlAtomList &twohop_neighbors)
 Get the list of two-hop neighbors.
XrlCmdError olsr4_0_1_get_twohop_neighbor_info (const uint32_t &tnid, IPv4 &main_addr, bool &is_strict, uint32_t &link_count, uint32_t &reachability, uint32_t &coverage)
 Get the information for a two-hop neighbor.
XrlCmdError olsr4_0_1_get_mid_entry_list (XrlAtomList &mid_entries)
 Get the list of learned Multiple Interface Declaration (MID) entries.
XrlCmdError olsr4_0_1_get_mid_entry (const uint32_t &midid, IPv4 &main_addr, IPv4 &iface_addr, uint32_t &distance, uint32_t &hold_time)
 Get the information contained in a MID entry.
XrlCmdError olsr4_0_1_get_tc_entry_list (XrlAtomList &tc_entries)
 Get the list of learned Topology Control (TC) entries.
XrlCmdError olsr4_0_1_get_tc_entry (const uint32_t &tcid, IPv4 &destination, IPv4 &lasthop, uint32_t &distance, uint32_t &seqno, uint32_t &hold_time)
 Get the information contained in a TC entry.
XrlCmdError olsr4_0_1_get_hna_entry_list (XrlAtomList &hna_entries)
 Get the list of learned external route (HNA) entries.
XrlCmdError olsr4_0_1_get_hna_entry (const uint32_t &hnaid, IPv4Net &destination, IPv4 &lasthop, uint32_t &distance, uint32_t &hold_time)
 Get the information contained in a HNA entry.

Private Attributes

Olsr_olsr
XrlIO_xrl_io

Detailed Description

Concrete implementation of OLSRv1/IPv4 XRL target.


Member Function Documentation

XrlCmdError XrlOlsr4Target::common_0_1_startup ( ) [inline, virtual]

Pure-virtual function that needs to be implemented to:

Request a startup of Xrl Target

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::finder_event_observer_0_1_xrl_target_birth ( const string &  target_class,
const string &  target_instance 
) [virtual]

Announce target birth to observer.

Parameters:
target_classthe target class name.
target_instancethe target instance name.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::finder_event_observer_0_1_xrl_target_death ( const string &  target_class,
const string &  target_instance 
) [virtual]

Announce target death to observer.

Parameters:
target_classthe target class name.
target_instancethe target instance name.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_bind_address ( const string &  ifname,
const string &  vifname,
const IPv4 local_addr,
const uint32_t &  local_port,
const IPv4 all_nodes_addr,
const uint32_t &  all_nodes_port 
) [virtual]

Create an IPv4 address binding for OLSR.

OLSR must be bound to a given protocol address on each interface, which means interface bindings in OLSRv1 must be keyed by interface name as well as protocol address.

Only a single IPv4 address may be thus bound, and the address must be supplied when the binding is created. This is to workaround the lack of RFC 3927 link-scoped IPv4 capability in most IPv4 implementations.

The addition of

Parameters:
local_addris not instantaneous. OLSR has to instantiate state in the FEA to send and receive packets. Once instantiated, the address must be explicitly enabled with the set_binding_enabled XRL.
ifnamethe interface that owns vif that has local_addr
vifnameinterface owning local_addr
local_addrthe address to be added.
local_portthe port to listen for control traffic on.
all_nodes_addrthe address to use for transmission.
all_nodes_portthe port to use for transmission.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_change_all_nodes_addr_port ( const string &  ifname,
const string &  vifname,
const IPv4 all_nodes_addr,
const uint32_t &  all_nodes_port 
) [virtual]

Change the address where OLSR sends control traffic on the given interface.

By default OLSR will attempt to use the all-ones broadcast address. Currently multicast addresses are NOT supported.

Parameters:
ifnamethe name of the interface.
vifnamethe name of the vif.
all_nodes_addrthe address to use.
all_nodes_portthe port to use.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_change_local_addr_port ( const string &  ifname,
const string &  vifname,
const IPv4 local_addr,
const uint32_t &  local_port 
) [virtual]

Change the UDP address and port where OLSR listens for control traffic on this interface.

In order to do this the process must tell the FEA to tear down and re-bind the control traffic socket.

Parameters:
ifnamethe name of the interface.
vifnamethe name of the vif.
local_addrthe new local IPv4 address.
local_portthe new local port number.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_binding_enabled ( const string &  ifname,
const string &  vifname,
bool &  enabled 
) [virtual]

Get the state of an IPv4 address binding for OLSR.

Parameters:
ifnamethe interface to query.
vifnamethe vif to qurery
enabledtrue if OLSR is configured administratively up on the given interface.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_hna_entry ( const uint32_t &  hnaid,
IPv4Net destination,
IPv4 lasthop,
uint32_t &  distance,
uint32_t &  hold_time 
) [virtual]

Get the information contained in a HNA entry.

Parameters:
hnaidHNA entry ID returned by get_hna_entry_list.
destinationthe main address of the advertised destination.
lasthopthe main address of the node advertising this entry.
distancethe distance measured between this node and the origin of the TC packet containing this entry.
hold_timethe time in seconds until this entry expires.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_hna_entry_list ( XrlAtomList hna_entries) [virtual]

Get the list of learned external route (HNA) entries.

Return a list of u32 type values. Each value is an internal ID that can be used with the get_hna_entry XRL.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_interface_info ( const uint32_t &  faceid,
string &  ifname,
string &  vifname,
IPv4 local_addr,
uint32_t &  local_port,
IPv4 all_nodes_addr,
uint32_t &  all_nodes_port 
) [virtual]

Get the per-interface information for the given interface.

Parameters:
faceidinterface ID returned by get_interface_list.
ifnamethe name of the interface.
vifnamethe name of the vif.
local_addrthe IPv4 address where OLSR is listening.
local_portthe UDP port where OLSR is listening.
all_nodes_addrthe IPv4 address where OLSR sends packets.
all_nodes_portthe UDP port where OLSR sends packets.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_interface_list ( XrlAtomList interfaces) [virtual]

Get the list of interfaces currently configured for OLSR.

Return a list of u32 type values. Each value is an internal ID that can be used with the get_interface_info XRL.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_interface_stats ( const string &  ifname,
const string &  vifname,
uint32_t &  bad_packets,
uint32_t &  bad_messages,
uint32_t &  messages_from_self,
uint32_t &  unknown_messages,
uint32_t &  duplicates,
uint32_t &  forwarded 
) [virtual]

Get the per-interface statistics for the given interface.

Parameters:
ifnamethe interface to query.
vifnamethe vif to qurery
bad_packetsthe number of bad packets received.
bad_messagesthe number of bad messages received.
messages_from_selfthe number of messages which appeared to be from our own main address.
unknown_messagesthe number of messages which could not be decoded.
duplicatesthe number of messages which appeared to be duplicates, according to histogram based duplicate detection.
forwardedthe number of messages which have been forwarded to the rest of the OLSR topology on this interface.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_link_info ( const uint32_t &  linkid,
IPv4 local_addr,
IPv4 remote_addr,
IPv4 main_addr,
uint32_t &  link_type,
uint32_t &  sym_time,
uint32_t &  asym_time,
uint32_t &  hold_time 
) [virtual]

Get the information for a one-hop link.

Parameters:
linkidLink entry ID returned by get_link_list.
local_addrthe interface address of the local end of this link.
remote_addrthe interface address of the remote end of this link.
main_addrthe main address of the neighbor at the remote end of this link.
link_typethe type of this link.
sym_timethe time in seconds for which this link will be considered symmetric.
asym_timethe time in seconds for which this link will be considered asymmetric.
hold_timethe time in seconds until this link expires.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_link_list ( XrlAtomList links) [virtual]

Get the list of one-hop links.

Return a list of u32 type values. Each value is an internal ID that can be used with the get_link_info XRL.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_mid_entry ( const uint32_t &  midid,
IPv4 main_addr,
IPv4 iface_addr,
uint32_t &  distance,
uint32_t &  hold_time 
) [virtual]

Get the information contained in a MID entry.

Parameters:
mididMID entry ID returned by get_mid_entry_list.
main_addrthe main address of the OLSR node
iface_addrthe interface address being advertised.
distancethe distance measured between this node and the origin of the MID packet containing this entry.
hold_timethe time in seconds until this entry expires.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_mid_entry_list ( XrlAtomList mid_entries) [virtual]

Get the list of learned Multiple Interface Declaration (MID) entries.

Return a list of u32 type values. Each value is an internal ID that can be used with the get_mid_entry XRL.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_neighbor_info ( const uint32_t &  nid,
IPv4 main_addr,
uint32_t &  willingness,
uint32_t &  degree,
uint32_t &  link_count,
uint32_t &  twohop_link_count,
bool &  is_advertised,
bool &  is_sym,
bool &  is_mpr,
bool &  is_mpr_selector 
) [virtual]

Get the information for a one-hop neighbor.

Parameters:
nidNeighbor entry ID returned by get_neighbor_list.
main_addrthe main address of this neighbor.
willingnessthe willingness of this neighbor to forward.
degreethe number of symmetric strict neighbors of this neighbor, excluding one-hop neighbors and this node.
link_countthe number of links to this neighbor.
twohop_link_countthe number of two-hop links which transit this neighbor as next-hop.
is_advertisedtrue if this neighbor is in the Advertised Neighbor Set of this node.
is_symtrue if this neighbor is symmetric.
is_mprtrue if this neighbor is selected as an MPR by this node.
is_mpr_selectortrue if this neighbor chooses this node as an MPR.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_neighbor_list ( XrlAtomList neighbors) [virtual]

Get the list of one-hop neighbors.

Return a list of u32 type values. Each value is an internal ID that can be used with the get_neighbor_info XRL.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_tc_entry ( const uint32_t &  tcid,
IPv4 destination,
IPv4 lasthop,
uint32_t &  distance,
uint32_t &  seqno,
uint32_t &  hold_time 
) [virtual]

Get the information contained in a TC entry.

Parameters:
tcidTC entry ID returned by get_tc_entry_list.
destinationthe main address of the advertised destination.
lasthopthe main address of the node advertising this entry.
distancethe distance measured between this node and the origin of the TC packet containing this entry.
seqnothe advertised sequence number of this entry.
hold_timethe time in seconds until this entry expires.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_tc_entry_list ( XrlAtomList tc_entries) [virtual]

Get the list of learned Topology Control (TC) entries.

Return a list of u32 type values. Each value is an internal ID that can be used with the get_tc_entry XRL.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_twohop_link_info ( const uint32_t &  tlid,
uint32_t &  last_face_id,
IPv4 nexthop_addr,
IPv4 dest_addr,
uint32_t &  hold_time 
) [virtual]

Get the information for a two-hop link.

Parameters:
tlidtwo-hop link ID returned by get_twohop_link_list.
last_face_idthe internal interface ID where advertisement of this two-hop link was last seen.
nexthop_addrthe main address of the one-hop neighbor where this two-hop link exists.
dest_addrthe main address of the two-hop neighbor at the remote end of this link.
hold_timethe time in seconds until this two-hop link expires.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_twohop_link_list ( XrlAtomList twohop_links) [virtual]

Get the list of two-hop links.

Return a list of u32 type values. Each value is an internal ID that can be used with the get_twohop_link_info XRL.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_twohop_neighbor_info ( const uint32_t &  tnid,
IPv4 main_addr,
bool &  is_strict,
uint32_t &  link_count,
uint32_t &  reachability,
uint32_t &  coverage 
) [virtual]

Get the information for a two-hop neighbor.

Parameters:
tnidtwo-hop neighbor ID returned by get_twohop_neighbor_list.
main_addrthe main address of this two-hop neighbor.
is_stricttrue if this two-hop neighbor is not also a two-hop neighbor.
link_countthe number of two-hop links that exist to this two-hop neighbor.
reachabilitythe number of MPR candidates which cover this two-hop neighbor.
coveragethe number of selected MPRs which cover this two-hop neighbor.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_get_twohop_neighbor_list ( XrlAtomList twohop_neighbors) [virtual]

Get the list of two-hop neighbors.

Return a list of u32 type values. Each value is an internal ID that can be used with the get_twohop_neighbor_info XRL.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_set_binding_enabled ( const string &  ifname,
const string &  vifname,
const bool &  enabled 
) [virtual]

Set the enabled state of an IPv4 address binding for OLSR.

Parameters:
ifnamethe interface to set enabled state for.
vifnamethe vif to set enabled state for.
enabledtrue if OLSR is to be configured administratively up on the interface, false if it is to be configured down.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_set_dup_hold_time ( const uint32_t &  dup_hold_time) [virtual]

Set the DUP_HOLD_TIME.

Parameters:
dup_hold_timethe new DUP_HOLD_TIME.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_set_hello_interval ( const uint32_t &  interval) [virtual]

Set the HELLO_INTERVAL.

Parameters:
intervalthe new HELLO_INTERVAL.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_set_hna_interval ( const uint32_t &  interval) [virtual]

Set the HNA_INTERVAL.

Parameters:
intervalthe new HNA_INTERVAL.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_set_interface_cost ( const string &  ifname,
const string &  vifname,
const uint32_t &  cost 
) [virtual]

Set the edge cost of an interface/vif.

Parameters:
ifnamethe name of the interface.
vifnamethe name of the vif.
costthe new edge cost of the interface.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_set_main_address ( const IPv4 addr) [virtual]

Set the main address.

Parameters:
addrOur main IPv4 address which OLSR uses as a router ID.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_set_mid_interval ( const uint32_t &  interval) [virtual]

Set the MID_INTERVAL.

Parameters:
intervalthe new MID_INTERVAL.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_set_mpr_coverage ( const uint32_t &  coverage) [virtual]

Set the MPR_COVERAGE.

Parameters:
coveragethe new MPR_COVERAGE value.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_set_refresh_interval ( const uint32_t &  interval) [virtual]

Set the REFRESH_INTERVAL.

Parameters:
intervalthe new REFRESH_INTERVAL.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_set_tc_fisheye ( const bool &  enabled) [virtual]

Enable/disable TC fisheye mode.

Parameters:
enabledtrue to enable fisheye, false to disable it.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_set_tc_interval ( const uint32_t &  interval) [virtual]

Set the TC_INTERVAL.

Parameters:
intervalthe new TC_INTERVAL.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_set_willingness ( const uint32_t &  willingness) [virtual]

Set the willingness-to-forward.

Parameters:
willingnessthe new willingness-to-forward.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_trace ( const string &  tvar,
const bool &  enable 
) [virtual]

Enable/Disable tracing.

Parameters:
tvartrace variable.
enableset to true to enable, false to disable.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::olsr4_0_1_unbind_address ( const string &  ifname,
const string &  vifname 
) [virtual]

Destroy an IPv4 address binding for OLSR.

Parameters:
ifnamethe interface to unbind.
vifnamethe vif to unbind.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::policy_backend_0_1_configure ( const uint32_t &  filter,
const string &  conf 
) [virtual]

Configure a policy filter.

Parameters:
filterthe identifier of the filter to configure.
confthe configuration of the filter.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::policy_backend_0_1_reset ( const uint32_t &  filter) [virtual]

Reset a policy filter.

Parameters:
filterthe identifier of the filter to reset.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::policy_redist4_0_1_add_route4 ( const IPv4Net network,
const bool &  unicast,
const bool &  multicast,
const IPv4 nexthop,
const uint32_t &  metric,
const XrlAtomList policytags 
) [virtual]

Start route redistribution for an IPv4 route.

Parameters:
networkthe route to advertise.
unicastwhether the route is unicast.
multicastwhether the route is multicast.
nexthopthe nexthop of the route.
metricthe metric of the route.
policytagsthe set of policy-tags associated with the route.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::policy_redist4_0_1_delete_route4 ( const IPv4Net network,
const bool &  unicast,
const bool &  multicast 
) [virtual]

Terminate route redistribution for an IPv4 route.

Parameters:
networkthe route for which advertisements should cease.
unicastwhether the route is unicast.
multicastwhether the route is multicast.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::profile_0_1_clear ( const string &  pname) [virtual]

Clear the profiling entries.

Parameters:
pnameprofile variable

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::profile_0_1_disable ( const string &  pname) [virtual]

Disable profiling.

Parameters:
pnameprofile variable

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::profile_0_1_enable ( const string &  pname) [virtual]

Enable profiling.

Parameters:
pnameprofile variable

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::profile_0_1_get_entries ( const string &  pname,
const string &  instance_name 
) [virtual]

Get log entries.

Parameters:
pnameprofile variable
instance_nameto send the profiling info to.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::socket4_user_0_1_disconnect_event ( const string &  sockid) [virtual]

Method invoked by target implementing socket4/0.1 when the peer has closed the connection.

It applies only to TCP sockets. Note that the socket itself is left open and must be explicitly closed.

Parameters:
sockidthe identifier associated with socket where the event occurred.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::socket4_user_0_1_error_event ( const string &  sockid,
const string &  error,
const bool &  fatal 
) [virtual]

Method invoked by target implementing socket4/0.1 when an error occurs.

Parameters:
sockidthe identifier associated with socket where the event occurred.
errora textual description of the error.
fatalindication of whether socket is shutdown because of error.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::socket4_user_0_1_inbound_connect_event ( const string &  sockid,
const IPv4 src_host,
const uint32_t &  src_port,
const string &  new_sockid,
bool &  accept 
) [virtual]

Method invoked by target implementing socket4/0.1 when a connection request is received from an IPv4 source.

It applies only to TCP sockets.

Parameters:
sockidthe identifier associated with socket where the event occurred.
src_hostthe connecting host.
src_portthe connecting IP port.
new_sockidthe identifier associated with the new socket that has been created to handle the new connection.
acceptif true, the connection request has been accepted, otherwise it has been rejected.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::socket4_user_0_1_outgoing_connect_event ( const string &  sockid) [virtual]

Method invoked by target implementing socket4/0.1 when an outgoing connection request originated by the local host is completed.

It applies only to TCP sockets. Note that if the connection failed, the error_event will be dispatched instead.

Parameters:
sockidthe identifier associated with socket where the event occurred.

Implements XrlOlsr4TargetBase.

XrlCmdError XrlOlsr4Target::socket4_user_0_1_recv_event ( const string &  sockid,
const string &  if_name,
const string &  vif_name,
const IPv4 src_host,
const uint32_t &  src_port,
const vector< uint8_t > &  data 
) [virtual]

Method invoked by target implementing socket4/0.1 when a packet arrives from an IPv4 source.

Parameters:
sockidthe identifier associated with socket where the event occurred.
if_namethe interface name the packet arrived on, if known. If unknown, then it is an empty string.
vif_namethe vif name the packet arrived on, if known. If unknown, then it is an empty string.
src_hostthe originating host.
src_portthe originating IP port.
datathe data received.

Implements XrlOlsr4TargetBase.


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