Definitions of Managed Objects for the Border Gateway Protocol: Version 3
obsoleted by
- rfc-4273 — Definitions of Managed Objects for BGP-4
Extracted elements (22)
bgpPathAttrASPath is represented as OCTET STRING rather than the more natural SEQUENCE OF INTEGER because the SMI (RFC 1155) restricts ASN.1 constructs for simplicity, and SEQUENCE OF INTEGER is not directly expressible. The document acknowledges this is 'probably best represented as SEQUENCE OF INTEGER' but encodes each AS as a two-byte pair for compatibility.
The Received Path Attribute Table captures all attributes received from all peers before local routing policy is applied. The actual attributes used to determine a route are a subset of this table, enabling operators to observe raw received data independently of local policy decisions.
The objects bgpPeerLocalAddr, bgpPeerLocalPort, bgpPeerRemoteAddr, and bgpPeerRemotePort provide the appropriate reference to the standard MIB-II TCP connection table, enabling correlation between BGP peer state and the underlying TCP connection.
Care should be used in providing write access to bgpPeerAdminStatus without adequate authentication, since this object can force BGP peer connections to restart or stop.
The objects bgpPeerInUpdates, bgpPeerOutUpdates, bgpPeerInTotalMessages, and bgpPeerOutTotalMessages should be initialized to zero when a BGP peer connection is established.
bgpBackwardTransition (TRAP-TYPE ::= 2) is sent with variables bgpPeerRemoteAddr, bgpPeerLastError, and bgpPeerState when the BGP FSM moves from a higher-numbered state to a lower-numbered state, indicating a session regression or failure.
bgpEstablished (TRAP-TYPE ::= 1) is sent with variables bgpPeerRemoteAddr, bgpPeerLastError, and bgpPeerState when the BGP FSM enters the ESTABLISHED state, allowing management stations to track peer session establishment.
bgpIdentifier (bgp 4) is a read-only IpAddress holding the BGP Identifier of the local system.
bgpLocalAs (bgp 2) is a read-only INTEGER (0..65535) containing the local autonomous system number.
bgpPathAttrInterASMetric (bgpPathAttrEntry 6) is a read-only object holding the optional inter-AS metric for a route. If this attribute was not provided by the peer, the value is 0.
bgpPathAttrNextHop (bgpPathAttrEntry 5) is a read-only IpAddress giving the address of the border router that should be used to reach the destination network.
bgpPathAttrOrigin (bgpPathAttrEntry 3) is a read-only INTEGER with values igp(1), egp(2), or incomplete(3), representing the ultimate origin of the path information as defined in the BGP protocol.
bgpPeerAdminStatus (bgpPeerEntry 3) is a read-write INTEGER controlling the desired connection state. A transition from 'stop' to 'start' generates a BGP Start Event; 'start' to 'stop' generates a BGP Stop Event, allowing peer connections to be restarted via SNMP.
bgpPeerLastError (bgpPeerEntry 14) is a read-only OCTET STRING of SIZE(2). The first byte contains the BGP error code and the second byte contains the subcode of the last error seen on this connection; the field is zero if no error has occurred.
bgpPeerTable (bgp 3) is a table of BgpPeerEntry rows indexed by bgpPeerRemoteAddr, each describing a BGP peer connection including its state, negotiated version, local/remote address and port, AS number, message counters, and last error.
bgpRcvdPathAttrTable (bgp 5) is a table of BgpPathAttrEntry rows indexed by (bgpPathAttrDestNetwork, bgpPathAttrPeer), holding all path attributes received from all peers before local routing policy has been applied.
bgpVersion (bgp 1) is a read-only OCTET STRING representing a bit-vector of supported BGP protocol version numbers. Bit i set means version (i+1) is supported; the MSB of the first octet refers to bit 0.
The BGP MIB root is assigned OID { mib-2 15 } (bgp OBJECT IDENTIFIER). The MIB is structured around two main tables — the BGP Peer Table and the BGP Received Path Attribute Table — plus a small set of system-level scalar objects.
The RFC explicitly states that security issues are not discussed in this memo. However, the MIB definition itself warns that write access to bgpPeerAdminStatus should require adequate authentication to prevent unauthorized manipulation of BGP peer sessions.
bgpPeerState models the BGP finite state machine with six states: idle(1), connect(2), active(3), opensent(4), openconfirm(5), established(6). The bgpEstablished trap fires on entry to established; bgpBackwardTransition fires on any move to a lower-numbered state.
bgpPathAttrASPath (bgpPathAttrEntry 4) encodes the AS path as an OCTET STRING where each AS number occupies two octets: first-byte = ASNumber / 256, second-byte = ASNumber & 255. This pairwise encoding is chosen for SMI compatibility rather than a native SEQUENCE OF INTEGER.
bgpPeerLastError encodes the BGP error as a 2-octet string: octet 1 = error code, octet 2 = error subcode. This maps directly to the BGP NOTIFICATION message error fields.