class BGPMain


Definition#include <main.hh>
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

Public Methods


Detailed Description

 BGPMain ()

BGPMain

 ~BGPMain ()

~BGPMain

void  local_config (const uint32_t& as, const IPv4& id)

local_config

Set the local configuration.

Parameters:
asas number.
idrouter id.

void  attach_peer (BGPPeer *p)

attach_peer

attach peer to peerlist

Parameters:
pBGP peer.

void  detach_peer (BGPPeer *p)

detach_peer

detach peer from the peerlist.

Parameters:
pBGP peer.

BGPPeerfind_peer (const Iptuple& search)

find_peer

Find peer with this iptuple

Parameters:
searchiptuple.

Returns: A pointer to a peer if one is found NULL otherwise.

bool  create_peer (BGPPeerData *pd)

create_peer

create a new peer and attach it to the peerlist.

Parameters:
pdBGP peer data.

Returns: true on success

bool  delete_peer (const Iptuple& iptuple)

delete_peer

delete peer tear down connection and remove for peerlist.

XrlBgpTarget xbt(bgp.get_router(), bgp);

Parameters:
iptupleiptuple.

Returns: true on success

bool  enable_peer (const Iptuple& iptuple)

enable_peer

enable peer

Parameters:
iptupleiptuple.

Returns: true on success

bool  disable_peer (const Iptuple& iptuple)

disable_peer

disable peer

Parameters:
iptupleiptuple.

Returns: true on success

bool  next_hop_rewrite_filter (const Iptuple& iptuple, const IPv4& next_hop)

next_hop_rewrite_filter

bool  get_peer_list_start (uint32_t& token)

get_peer_list_start

bool  get_peer_list_next (const uint32_t& token, IPv4& local_ip, uint32_t& local_port, IPv4& peer_ip, uint32_t& peer_port)

get_peer_list_next

bool  get_peer_id (const Iptuple& iptuple, IPv4& peer_id)

get_peer_id

bool  get_peer_status (const Iptuple& iptuple, uint32_t& peer_state, uint32_t& admin_status)

get_peer_status

bool  get_peer_negotiated_version (const Iptuple& iptuple, int32_t& neg_version)

get_peer_negotiated_version

bool  get_peer_as (const Iptuple& iptuple, uint32_t& peer_as)

get_peer_as

bool  get_peer_msg_stats (const Iptuple& iptuple, uint32_t& in_updates, uint32_t& out_updates, uint32_t& in_msgs, uint32_t& out_msgs, uint16_t& last_error, uint32_t& in_update_elapsed)

get_peer_msg_stats

bool  get_peer_established_stats (const Iptuple& iptuple, uint32_t& transitions, uint32_t& established_time)

get_peer_established_stats

bool  get_peer_timer_config (const Iptuple& iptuple, uint32_t& retry_interval, uint32_t& hold_time, uint32_t& keep_alive, uint32_t& hold_time_configured, uint32_t& keep_alive_configured, uint32_t& min_as_origination_interval, uint32_t& min_route_adv_interval)

get_peer_timer_config

bool  register_ribname (const string& name)

register_ribname

void  main_loop ()

main_loop

void  terminate ()

terminate

int  create_listener (const Iptuple& iptuple)

create_listener

LocalDataget_local_data ()

get_local_data

void  start_server (const Iptuple& iptuple)

start_server

void  stop_server (const Iptuple& iptuple)

stop_server

void  stop_all_servers ()

stop_all_servers

Stop listening for incoming connections.

bool  add_route (const OriginType origin, const AsNum& as, const IPv4& next_hop, const IPv4Net& nlri)

add_route

add route

Typically called via XRL's to add static routes.

Parameters:
originthe origin of the path information.
asuman as number will eventually be a path.
next_hopthe border router that should be used as a detination for the nlri.
nlrinetwork level reachability information.
successreturns true if the route was sucessfully added.

bool  delete_route (const IPv4Net& nlri)

delete_route

delete route

Typically called via XRL's to delete static routes.

Parameters:
nlrinetwork level reachability information.
successreturns true if the route was sucessfully added.

bool  get_route_list_start4 (uint32_t& token)

get_route_list_start4

bool  get_route_list_start6 (uint32_t& token)

get_route_list_start6

bool  get_route_list_next4 ( const uint32_t& token, IPv4& peer_id, IPv4Net& net, uint32_t& origin, vector<uint8_t>& aspath, IPv4& nexthop, int32_t& med, int32_t& localpref, int32_t& atomic_agg, vector<uint8_t>& aggregator, int32_t& calc_localpref, vector<uint8_t>& attr_unknown, bool& best)

get_route_list_next4

bool  get_route_list_next6 ( const uint32_t& token, IPv4& peer_id, IPv6Net& net, uint32_t& origin, vector<uint8_t>& aspath, IPv6& nexthop, int32_t& med, int32_t& localpref, int32_t& atomic_agg, vector<uint8_t>& aggregator, int32_t& calc_localpref, vector<uint8_t>& attr_unknown, bool& best)

get_route_list_next6

bool  rib_client_route_info_changed4 ( const IPv4& addr, const uint32_t& prefix_len, const IPv4& nexthop, const uint32_t& metric)

rib_client_route_info_changed4

bool  rib_client_route_info_changed6 ( const IPv6& addr, const uint32_t& prefix_len, const IPv6& nexthop, const uint32_t& metric)

rib_client_route_info_changed6

bool  rib_client_route_info_invalid4 ( const IPv4& addr, const uint32_t& prefix_len)

rib_client_route_info_invalid4

bool  rib_client_route_info_invalid6 ( const IPv6& addr, const uint32_t& prefix_len)

rib_client_route_info_invalid6

bool  set_parameter ( const Iptuple& iptuple, const string& parameter)

set_parameter

set parameter

Typically called via XRL's to set which parameters we support per peer.

Parameters:
iptupleiptuple
parameterwe are setting for this peer.

BGPPlumbingplumbing ()

plumbing

[const]

Originally inserted for testing. However, now used by all the "rib_client_route_info_*" methods.

XrlStdRouterget_router ()

get_router

EventLoopget_eventloop ()

get_eventloop

XrlBgpTargetget_xrl_target ()

get_xrl_target


Generated by: pavlin on possum.icir.org on Mon Mar 10 19:34:59 2003, using kdoc 2.0a54+XORP.