📄 bgp_base.hh
字号:
const string& local_ip, const uint32_t& local_port, const string& peer_ip, const uint32_t& peer_port, const uint32_t& maximum, const bool& state) = 0; /** * Pure-virtual function that needs to be implemented to: * * Set the peer's AS number. * * @param next_hop IPv4 nexthop. */ virtual XrlCmdError bgp_0_2_set_nexthop4( // Input values, const string& local_ip, const uint32_t& local_port, const string& peer_ip, const uint32_t& peer_port, const IPv4& next_hop) = 0; /** * Pure-virtual function that needs to be implemented to: * * Set the IPv6 nexthop. * * @param next_hop IPv6 nexthop */ virtual XrlCmdError bgp_0_2_set_nexthop6( // Input values, const string& local_ip, const uint32_t& local_port, const string& peer_ip, const uint32_t& peer_port, const IPv6& next_hop) = 0; /** * Pure-virtual function that needs to be implemented to: * * Get the IPv6 nexthop. * * @param next_hop IPv6 nexthop */ virtual XrlCmdError bgp_0_2_get_nexthop6( // Input values, const string& local_ip, const uint32_t& local_port, const string& peer_ip, const uint32_t& peer_port, // Output values, IPv6& next_hop) = 0; /** * Pure-virtual function that needs to be implemented to: * * Set the peer state enabled or disabled. * * @param toggle enabled or disabled. */ virtual XrlCmdError bgp_0_2_set_peer_state( // Input values, const string& local_ip, const uint32_t& local_port, const string& peer_ip, const uint32_t& peer_port, const bool& toggle) = 0; /** * Pure-virtual function that needs to be implemented to: * * Set the peer md5 password. * * @param password the password to use for TCP-MD5 authentication. */ virtual XrlCmdError bgp_0_2_set_peer_md5_password( // Input values, const string& local_ip, const uint32_t& local_port, const string& peer_ip, const uint32_t& peer_port, const string& password) = 0; /** * Pure-virtual function that needs to be implemented to: * * Enable or disable the peering based on the peer state. */ virtual XrlCmdError bgp_0_2_activate( // Input values, const string& local_ip, const uint32_t& local_port, const string& peer_ip, const uint32_t& peer_port) = 0; /** * Pure-virtual function that needs to be implemented to: * * Set which parameters we support per peer */ virtual XrlCmdError bgp_0_2_set_parameter( // Input values, const string& local_ip, const uint32_t& local_port, const string& peer_ip, const uint32_t& peer_port, const string& parameter, const bool& toggle) = 0; /** * Pure-virtual function that needs to be implemented to: * * Set next hop rewrite filter. XXX - This is a temporary hack until we * get programmable filters. */ virtual XrlCmdError bgp_0_2_next_hop_rewrite_filter( // Input values, const string& local_ip, const uint32_t& local_port, const string& peer_ip, const uint32_t& peer_port, const IPv4& next_hop) = 0; /** * Pure-virtual function that needs to be implemented to: * * Originate route IPv4 * * @param nlri subnet to announce * * @param next_hop to forward to * * @param unicast if true install in unicast routing table * * @param multicast if true install in multicast routing table */ virtual XrlCmdError bgp_0_2_originate_route4( // Input values, const IPv4Net& nlri, const IPv4& next_hop, const bool& unicast, const bool& multicast) = 0; /** * Pure-virtual function that needs to be implemented to: * * Originate route IPv6 * * @param nlri subnet to announce * * @param next_hop to forward to * * @param unicast if true install in unicast routing table * * @param multicast if true install in multicast routing table */ virtual XrlCmdError bgp_0_2_originate_route6( // Input values, const IPv6Net& nlri, const IPv6& next_hop, const bool& unicast, const bool& multicast) = 0; /** * Pure-virtual function that needs to be implemented to: * * Withdraw route IPv4 * * @param nlri subnet to withdraw * * @param unicast if true withdraw from unicast routing table * * @param multicast if true withdraw from multicast routing table */ virtual XrlCmdError bgp_0_2_withdraw_route4( // Input values, const IPv4Net& nlri, const bool& unicast, const bool& multicast) = 0; /** * Pure-virtual function that needs to be implemented to: * * Withdraw route IPv6 * * @param nlri subnet to withdraw * * @param unicast if true withdraw from unicast routing table * * @param multicast if true withdraw from multicast routing table */ virtual XrlCmdError bgp_0_2_withdraw_route6( // Input values, const IPv6Net& nlri, const bool& unicast, const bool& multicast) = 0; /** * Pure-virtual function that needs to be implemented to: * * Enable/Disable tracing. * * @param tvar trace variable. * * @param enable set to true to enable false to disable. */ virtual XrlCmdError bgp_0_2_trace( // Input values, const string& tvar, const bool& enable) = 0; /** * Pure-virtual function that needs to be implemented to: * * Get the first item of a list of BGP peers See RFC 1657 (BGP MIB) for * full definitions of return values. * * @param token returned token to be provided when calling * get_peer_list_next. * * @param more returned to indicate whether there are more list items * remaining. */ virtual XrlCmdError bgp_0_2_get_peer_list_start( // Output values, uint32_t& token, bool& more) = 0; /** * Pure-virtual function that needs to be implemented to: * * Get the next item of a list of BGP peers * * @param token token from prior call to get_peer_list * * @param more returned to indicate whether there are more list items * remaining. */ virtual XrlCmdError bgp_0_2_get_peer_list_next( // Input values, const uint32_t& token, // Output values, string& local_ip, uint32_t& local_port, string& peer_ip, uint32_t& peer_port, bool& more) = 0; virtual XrlCmdError bgp_0_2_get_peer_id( // Input values, const string& local_ip, const uint32_t& local_port, const string& peer_ip, const uint32_t& peer_port, // Output values, IPv4& peer_id) = 0; virtual XrlCmdError bgp_0_2_get_peer_status( // Input values, const string& local_ip, const uint32_t& local_port, const string& peer_ip, const uint32_t& peer_port, // Output values, uint32_t& peer_state, uint32_t& admin_status) = 0; virtual XrlCmdError bgp_0_2_get_peer_negotiated_version( // Input values, const string& local_ip, const uint32_t& local_port, const string& peer_ip, const uint32_t& peer_port, // Output values, int32_t& neg_version) = 0; virtual XrlCmdError bgp_0_2_get_peer_as( // Input values, const string& local_ip, const uint32_t& local_port, const string& peer_ip, const uint32_t& peer_port, // Output values, uint32_t& peer_as) = 0; virtual XrlCmdError bgp_0_2_get_peer_msg_stats( // Input values, const string& local_ip, const uint32_t& local_port, const string& peer_ip, const uint32_t& peer_port, // Output values, uint32_t& in_updates, uint32_t& out_updates, uint32_t& in_msgs, uint32_t& out_msgs, uint32_t& last_error, uint32_t& in_update_elapsed) = 0; virtual XrlCmdError bgp_0_2_get_peer_established_stats( // Input values, const string& local_ip, const uint32_t& local_port, const string& peer_ip, const uint32_t& peer_port, // Output values, uint32_t& transitions, uint32_t& established_time) = 0; virtual XrlCmdError bgp_0_2_get_peer_timer_config( // Input values, const string& local_ip, const uint32_t& local_port, const string& peer_ip, const uint32_t& peer_port, // Output values, uint32_t& retry_interval, uint32_t& hold_time, uint32_t& keep_alive, uint32_t& hold_time_conf, uint32_t& keep_alive_conf, uint32_t& min_as_orgination_interval, uint32_t& min_route_adv_interval) = 0; /** * Pure-virtual function that needs to be implemented to: * * Register rib. * * @param name rib name. */ virtual XrlCmdError bgp_0_2_register_rib( // Input values, const string& name) = 0; /** * Pure-virtual function that needs to be implemented to: * * Get the first item of a list of BGP routes See RFC 1657 (BGP MIB) for * full definitions of return values. * * @param net the subtree to examine. NB Either unicast or multicast * should be set to true, but not both. * * @param unicast request start of unicast routes. * * @param multicast request start of unicast routes. * * @param token returned token to be provided when calling * get_route_list_next. */ virtual XrlCmdError bgp_0_2_get_v4_route_list_start( // Input values, const IPv4Net& net, const bool& unicast, const bool& multicast, // Output values, uint32_t& token) = 0; /** * Pure-virtual function that needs to be implemented to: * * Get the first item of a list of BGP routes See RFC 1657 (BGP MIB) for * full definitions of return values. * * @param net the subtree to examine. NB Either unicast or multicast * should be set to true, but not both. * * @param unicast request start of unicast routes. * * @param multicast request start of multicast routes. * * @param token returned token to be provided when calling * get_route_list_next. */ virtual XrlCmdError bgp_0_2_get_v6_route_list_start( // Input values, const IPv6Net& net, const bool& unicast, const bool& multicast, // Output values, uint32_t& token) = 0; /** * Pure-virtual function that needs to be implemented to: * * Get the next route in the list See RFC 1657 (BGP MIB) for full * definitions of return values. */ virtual XrlCmdError bgp_0_2_get_v4_route_list_next( // Input values, const uint32_t& token, // Output values, IPv4& peer_id, IPv4Net& net, uint32_t& best_and_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& valid, bool& unicast, bool& multicast) = 0; /** * Pure-virtual function that needs to be implemented to: * * Get the next route in the list See RFC 1657 (BGP MIB) for full * definitions of return values. */ virtual XrlCmdError bgp_0_2_get_v6_route_list_next( // Input values, const uint32_t& token, // Output values, IPv4& peer_id, IPv6Net& net, uint32_t& best_and_origin, vector<uint8_t>& aspath,
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -