class BGPMain

The password for TCP-MD5 authentication. More...

 
LOGO
 Annotated List  Files  Globals  Hierarchy  Index  Top

Public Types

Public Methods


Detailed Description

The password for TCP-MD5 authentication.

 BGPMain (EventLoop& eventloop)

BGPMain

 ~BGPMain ()

~BGPMain

ProcessStatus  status (string& reason)

status

Get the process status

Reimplemented from ServiceBase.

int  startup ()

startup

Startup operation.

Returns: XORP_OK on success, otherwise XORP_ERROR.

Reimplemented from ServiceBase.

int  shutdown ()

shutdown

Shutdown operation.

Returns: XORP_OK on success, otherwise XORP_ERROR.

Reimplemented from ServiceBase.

void  component_up (const string& component_name)

component_up

A method that should be called when an internal subsystem comes up.

Parameters:

component_namethe name of the component.
void  component_down (const string& component_name)

component_down

A method that should be called when an internal subsystem goes down.

Parameters:

component_namethe name of the component.
bool  is_interface_enabled (const string& interface)

is_interface_enabled

[const]

Test whether an interface is enabled.

Parameters:

interfacethe name of the interface to test.

Returns: true if it exists and is enabled, otherwise false.

bool  is_vif_enabled (const string& interface, const string& vif)

is_vif_enabled

[const]

Test whether an interface/vif is enabled.

Parameters:

interfacethe name of the interface to test.
vifthe name of the vif to test.

Returns: true if it exists and is enabled, otherwise false.

bool  is_address_enabled (const string& interface, const string& vif, const IPv4& address)

is_address_enabled

[const]

Test whether an IPv4 interface/vif/address is enabled.

Parameters:

interfacethe name of the interface to test.
vifthe name of the vif to test.
addressthe address to test.

Returns: true if it exists and is enabled, otherwise false.

bool  is_address_enabled (const string& interface, const string& vif, const IPv6& address)

is_address_enabled

[const]

Test whether an IPv6 interface/vif/address is enabled.

Parameters:

interfacethe name of the interface to test.
vifthe name of the vif to test.
addressthe address to test.

Returns: true if it exists and is enabled, otherwise false.

typedef XorpCallback2<void, const string&, bool>::RefPtr InterfaceStatusCb

InterfaceStatusCb

typedef XorpCallback3<void, const string&, const string&, bool>::RefPtr VifStatusCb

VifStatusCb

typedef XorpCallback5<void, const string&, const string&, const IPv4&, uint32_t, bool>::RefPtr AddressStatus4Cb

AddressStatus4Cb

typedef XorpCallback5<void, const string&, const string&, const IPv6&, uint32_t, bool>::RefPtr AddressStatus6Cb

AddressStatus6Cb

void  register_interface_status (InterfaceStatusCb cb)

register_interface_status

Add a callback for tracking the interface status.

The callback will be invoked whenever the status of the interface is changed from disabled to enabled or vice-versa.

Parameters:

cbthe callback to register.
void  register_vif_status (VifStatusCb cb)

register_vif_status

Add a callback for tracking the interface/vif status.

The callback will be invoked whenever the status of the interface/vif is changed from disabled to enabled or vice-versa.

Parameters:

cbthe callback to register.
void  register_address_status (AddressStatus4Cb cb)

register_address_status

Add a callback for tracking the IPv4 interface/vif/address status.

The callback will be invoked whenever the status of the tuple (interface, vif, address) is changed from disabled to enabled or vice-versa.

Parameters:

cbthe callback to register.
void  register_address_status (AddressStatus6Cb cb)

register_address_status

Add a callback for tracking the IPv6 interface/vif/address status.

The callback will be invoked whenever the status of the tuple (interface, vif, address) is changed from disabled to enabled or vice-versa.

Parameters:

cbthe callback to register.
uint32_t  get_prefix_length (const string& interface, const string& vif, const IPv4& address)

get_prefix_length

Obtain the subnet prefix length for an IPv4 interface/vif/address.

Parameters:

interfacethe name of the interface.
vifthe name of the vif.
addressthe address.

Returns: the subnet prefix length for the address.

uint32_t  get_prefix_length (const string& interface, const string& vif, const IPv6& address)

get_prefix_length

Obtain the subnet prefix length for an IPv6 interface/vif/address.

Parameters:

interfacethe name of the interface.
vifthe name of the vif.
addressthe address.

Returns: the subnet prefix length for the address.

uint32_t  get_mtu (const string& interface)

get_mtu

Obtain the MTU for an interface.

Parameters:

thename of the interface.

Returns: the mtu for the interface.

bool  interface_address4 (const IPv4& address)

interface_address4

[const]

Is the address one of this routers interface addresses?

bool  interface_address6 (const IPv6& address)

interface_address6

[const]

Is the address one of this routers interface addresses?

bool  interface_address_prefix_len4 (const IPv4& address, uint32_t& prefix_len)

interface_address_prefix_len4

[const]

Obtain the prefix length for a particular IPv4 address.

Parameters:

addressthe address to search for.
prefix_lenthe return-by-reference prefix length for address.

Returns: true if the address belongs to this router, otherwise false.

bool  interface_address_prefix_len6 (const IPv6& address, uint32_t& prefix_len)

interface_address_prefix_len6

[const]

Obtain the prefix length for a particular IPv6 address.

Parameters:

addressthe address to search for.
prefix_lenthe return-by-reference prefix length for address.

Returns: true if the address belongs to this router, otherwise false.

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

local_config

Set the local configuration.

Parameters:

asas number.
idrouter id.
use_4byte_asnumsindicates we should send 4 byte AS numbers to all peers that are 4byte capable.
void  set_confederation_identifier (const uint32_t& as, bool disable)

set_confederation_identifier

Set or disable the confederation identifier.

void  set_cluster_id (const IPv4& cluster_id, bool disable)

set_cluster_id

Set the cluster ID and enable or disable route reflection.

void  set_damping (uint32_t half_life,uint32_t max_suppress,uint32_t reuse, uint32_t suppress, bool disable)

set_damping

Set the route flap damping parameters.

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.
void  attach_deleted_peer (BGPPeer *p)

attach_deleted_peer

attach peer to deleted peerlist

Parameters:

pBGP peer.
void  detach_deleted_peer (BGPPeer *p)

detach_deleted_peer

detach peer from the deleted peerlist.

Parameters:

pBGP peer.
BGPPeerfind_peer (const Iptuple& search, list<BGPPeer *>& peers)

find_peer

Find peer with this iptuple from the list provided

Parameters:

searchiptuple.
peerslist to search.

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

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.

BGPPeerfind_deleted_peer (const Iptuple& search)

find_deleted_peer

Find peer with this iptuple on the deleted peer list.

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  bounce_peer (const Iptuple& iptuple)

bounce_peer

Drop this peering and if it was configured up allow it attempt a new peering.

Parameters:

iptupleiptuple.

Returns: true on success

void  local_ip_changed (string local_address)

local_ip_changed

One of the local IP addresses of this router has changed. Where a change can be an addition or removal or a change in the link status. If the provided address matches any of the local ip addresses of any of the peerings unconditionally bounce the peering. Unconditional bouncing of the peering is all that is required if a link has gone down the old session will be dropped and the new one will fail. If the link has just come up then a session will be made.

bool  change_tuple (const Iptuple& iptuple, const Iptuple& nptuple)

change_tuple

Change one of the tuple settings of this peering.

Parameters:

iptupleoriginal tuple.
iptuplenew tuple.

Returns: true on success

bool  find_tuple_179 (string peer_addr, Iptuple& otuple)

find_tuple_179

Find the tuple that has this peer address and both ports are 179. This is a hack as at the moment of writing the rtrmgr can't send both the old and new state of a variable.

Parameters:

peer_addrof tuple.
otuplethe tuple if one is found.

Returns: true if a tuple is matched.

bool  change_local_ip (const Iptuple& iptuple, const string& local_ip)

change_local_ip

Change the local IP address of this peering.

Parameters:

iptupleiptuple.
local_ipnew value.

Returns: true on success

bool  change_local_port (const Iptuple& iptuple, uint32_t local_port)

change_local_port

Change the local IP port of this peering.

Parameters:

iptupleiptuple.
local_portnew value.

Returns: true on success

bool  change_peer_port (const Iptuple& iptuple, uint32_t peer_port)

change_peer_port

Change the peer IP port of this peering.

Parameters:

iptupleiptuple.
peer_portnew value.

Returns: true on success

bool  set_peer_as (const Iptuple& iptuple, uint32_t peer_as)

set_peer_as

set peer as

Parameters:

iptupleiptuple.
peer_asnew value.

Returns: true on success

bool  set_holdtime (const Iptuple& iptuple, uint32_t holdtime)

set_holdtime

set holdtime

Parameters:

iptupleiptuple.
holdtimenew value.

Returns: true on success

bool  set_delay_open_time (const Iptuple& iptuple, uint32_t delay_open_time)

set_delay_open_time

set delay open time

Parameters:

iptupleiptuple.
delay_open_timenew value.

Returns: true on success

bool  set_route_reflector_client (const Iptuple& iptuple, bool rr)

set_route_reflector_client

set route reflector client

Parameters:

iptupleiptuple.
rrtrue if this peer is a route reflector client.

Returns: true on success

bool  set_confederation_member (const Iptuple& iptuple, bool conf)

set_confederation_member

set route confederation member

Parameters:

iptupleiptuple.
conftrue if this peer is a confederation member.

Returns: true on success

bool  set_prefix_limit (const Iptuple& iptuple, uint32_t maximum, bool state)

set_prefix_limit

set prefix limit

Parameters:

maximumnumber of prefixes
statetrue if the prefix limit is being enforced

Returns: true on success

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

set_nexthop4

set IPv4 next-hop.

Parameters:

iptupleiptuple.
next-hop

Returns: true on success

bool  set_nexthop6 (const Iptuple& iptuple, const IPv6& next_hop)

set_nexthop6

set IPv6 next-hop.

Parameters:

iptupleiptuple.
next-hop

Returns: true on success

bool  get_nexthop6 (const Iptuple& iptuple, IPv6& next_hop)

get_nexthop6

get IPv6 next-hop.

Parameters:

iptupleiptuple.
next-hop

Returns: true on success

bool  set_peer_state (const Iptuple& iptuple, bool state)

set_peer_state

Set peer state.

@ return true on success.

Parameters:

iptupleiptuple.
stateshould the peering be enable or disabled.
bool  activate (const Iptuple& iptuple)

activate

Activate peer.

Enable the peering based on the peer state.

@ return true on success.

Parameters:

iptupleiptuple.
bool  activate_all_peers ()

activate_all_peers

Activate all peers.

Returns: true on success

bool  set_peer_md5_password (const Iptuple& iptuple, const string& password)

set_peer_md5_password

Set peer TCP-MD5 password.

Parameters:

iptupleiptuple.
passwordThe password to use for TCP-MD5 authentication; if this is the empty string, then authentication will be disabled.

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, string& local_ip, uint32_t& local_port, string& 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

shutdown BGP cleanly

bool  run ()

run

XorpFd  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  originate_route (const IPv4Net& nlri, const IPv4& next_hop, const bool& unicast, const bool& multicast, const PolicyTags& policytags)

originate_route

Originate an IPv4 route

Parameters:

nlrisubnet to announce
next_hopto forward to
unicastif true install in unicast routing table
multicastif true install in multicast routing table
policytagspolicy-tags associated with route.

Returns: true on success

bool  originate_route (const IPv6Net& nlri, const IPv6& next_hop, const bool& unicast, const bool& multicast, const PolicyTags& policytags)

originate_route

Originate an IPv6 route

Parameters:

nlrisubnet to announce
next_hopto forward to
unicastif true install in unicast routing table
multicastif true install in multicast routing table
policytagspolicy-tags associated with route.

Returns: true on success

bool  withdraw_route (const IPv4Net& nlri, const bool& unicast, const bool& multicast)

withdraw_route

[const]

Withdraw an IPv4 route

Parameters:

nlrisubnet to withdraw
unicastif true withdraw from unicast routing table
multicastif true withdraw from multicast routing table

Returns: true on success

bool  withdraw_route (const IPv6Net& nlri, const bool& unicast, const bool& multicast)

withdraw_route

[const]

Withdraw an IPv6 route

Returns: true on success

template <typename A> bool  get_route_list_start (uint32_t& token, const IPNet<A>& prefix, const bool& unicast, const bool& multicast)

get_route_list_start

template <typename A> bool  get_route_list_next ( const uint32_t& token, IPv4& peer_id, IPNet<A>& net, uint32_t& origin, vector<uint8_t>& aspath, A& 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, bool& unicast, bool& multicast)

get_route_list_next

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, const bool toggle)

set_parameter

set parameter

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

Parameters:

iptupleiptuple
toggleenable or disable parameter
BGPPlumbingplumbing_unicast ()

plumbing_unicast

[const]

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

BGPPlumbingplumbing_multicast ()

plumbing_multicast

[const]

XrlStdRouterget_router ()

get_router

EventLoop&  eventloop ()

eventloop

XrlBgpTargetget_xrl_target ()

get_xrl_target

void  notify_birth (const string& target_class, const string& target_instance)

notify_birth

Call via XrlBgpTarget when the finder reports that a process has started.

Parameters:

target_classClass of process that has started.
target_instanceInstance name of process that has started.
void  notify_death (const string& target_class, const string& target_instance)

notify_death

Call via XrlBgpTarget when the finder reports that a process has terminated.

Parameters:

target_classClass of process that has terminated.
target_instanceInstance name of process that has terminated.
bool  processes_ready ()

processes_ready

Returns: Return true when all the processes that BGP is dependent on are ready.

string  bgp_mib_name ()

bgp_mib_name

[const]

Returns: Return the bgp mib name.

bool  do_snmp_trap ()

do_snmp_trap

[const]

Check to see if the bgp snmp entity is running.

void  finder_death (const char *file, const int lineno)

finder_death

To be called when the finder dies.

void  configure_filter (const uint32_t& filter, const string& conf)

configure_filter

Configure a policy filter

Parameters:

filterId of filter to configure.
confConfiguration of filter.
void  reset_filter (const uint32_t& filter)

reset_filter

Reset a policy filter.

Parameters:

filterId of filter to reset.
void  push_routes ()

push_routes

Push routes through policy filters for re-filtering.

Profile&  profile ()

profile

Returns: a reference to the profiler.


Generated by: pavlin on kobe.xorp.net on Wed Jan 7 19:11:04 2009, using kdoc 2.0a54+XORP.