draft-ietf-idr-bgp4-20.txt   draft-ietf-idr-bgp4-21.txt 
Network Working Group Y. Rekhter Network Working Group Y. Rekhter
INTERNET DRAFT Juniper Networks INTERNET DRAFT Juniper Networks
T. Li T. Li
Procket Networks, Inc. Procket Networks, Inc.
S. Hares S. Hares
NextHop Technologies, Inc. NextHop Technologies, Inc.
Editors Editors
A Border Gateway Protocol 4 (BGP-4) A Border Gateway Protocol 4 (BGP-4)
<draft-ietf-idr-bgp4-20.txt> <draft-ietf-idr-bgp4-21.txt>
Status of this Memo Status of this Memo
This document is an Internet-Draft and is in full conformance with This document is an Internet-Draft and is in full conformance with
all provisions of Section 10 of RFC2026. all provisions of Section 10 of RFC2026.
Internet-Drafts are working documents of the Internet Engineering Internet-Drafts are working documents of the Internet Engineering
Task Force (IETF), its areas, and its working groups. Note that Task Force (IETF), its areas, and its working groups. Note that
other groups may also distribute working documents as Internet- other groups may also distribute working documents as Internet-
Drafts. Drafts.
skipping to change at page 1, line 35 skipping to change at page 1, line 35
and may be updated, replaced, or obsoleted by other documents at any and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use Internet-Drafts as reference time. It is inappropriate to use Internet-Drafts as reference
material or to cite them other than as ``work in progress.'' material or to cite them other than as ``work in progress.''
The list of current Internet-Drafts can be accessed at The list of current Internet-Drafts can be accessed at
http://www.ietf.org/ietf/1id-abstracts.txt http://www.ietf.org/ietf/1id-abstracts.txt
The list of Internet-Draft Shadow Directories can be accessed at The list of Internet-Draft Shadow Directories can be accessed at
http://www.ietf.org/shadow.html. http://www.ietf.org/shadow.html.
Specification of Requirements Copyright Notice
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", Copyright (C) The Internet Society (2003). All Rights Reserved.
"SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
document are to be interpreted as described in RFC2119 [RFC2119]. Abstract
The Border Gateway Protocol (BGP) is an inter-Autonomous System
routing protocol.
The primary function of a BGP speaking system is to exchange network
reachability information with other BGP systems. This network
reachability information includes information on the list of
Autonomous Systems (ASs) that reachability information traverses.
This information is sufficient to construct a graph of AS
connectivity for this reachability from which routing loops may be
pruned and some policy decisions at the AS level may be enforced.
BGP-4 provides a set of mechanisms for supporting Classless Inter-
Domain Routing (CIDR) [RFC1518, RFC1519]. These mechanisms include
support for advertising a set of destinations as an IP prefix, and
eliminating the concept of network "class" within BGP. BGP-4 also
introduces mechanisms which allow aggregation of routes, including
aggregation of AS paths.
Routing information exchanged via BGP supports only the destination-
based forwarding paradigm, which assumes that a router forwards a
packet based solely on the destination address carried in the IP
header of the packet. This, in turn, reflects the set of policy
decisions that can (and can not) be enforced using BGP. BGP can
support only the policies conforming to the destination-based
forwarding paradigm.
This specification covers only the exchange of IP version 4 network
reachability information.
Table of Contents Table of Contents
Abstract . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 1. Definition of commonly used terms . . . . . . . . . . . . . . 5
1. Definition of commonly used terms . . . . . . . . . . . . . . 4 2. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 7
2. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 6 Specification of Requirements . . . . . . . . . . . . . . . . . . 8
3. Summary of Operation . . . . . . . . . . . . . . . . . . . . . 7 3. Summary of Operation . . . . . . . . . . . . . . . . . . . . . 8
3.1 Routes: Advertisement and Storage . . . . . . . . . . . . . . 9 3.1 Routes: Advertisement and Storage . . . . . . . . . . . . . . 9
3.2 Routing Information Bases . . . . . . . . . . . . . . . . . . 10 3.2 Routing Information Bases . . . . . . . . . . . . . . . . . . 10
4. Message Formats . . . . . . . . . . . . . . . . . . . . . . . 11 4. Message Formats . . . . . . . . . . . . . . . . . . . . . . . 12
4.1 Message Header Format . . . . . . . . . . . . . . . . . . . . 11 4.1 Message Header Format . . . . . . . . . . . . . . . . . . . . 12
4.2 OPEN Message Format . . . . . . . . . . . . . . . . . . . . . 12 4.2 OPEN Message Format . . . . . . . . . . . . . . . . . . . . . 13
4.3 UPDATE Message Format . . . . . . . . . . . . . . . . . . . . 14 4.3 UPDATE Message Format . . . . . . . . . . . . . . . . . . . . 15
4.4 KEEPALIVE Message Format . . . . . . . . . . . . . . . . . . 21 4.4 KEEPALIVE Message Format . . . . . . . . . . . . . . . . . . 22
4.5 NOTIFICATION Message Format . . . . . . . . . . . . . . . . . 21 4.5 NOTIFICATION Message Format . . . . . . . . . . . . . . . . . 22
5. Path Attributes . . . . . . . . . . . . . . . . . . . . . . . 23 5. Path Attributes . . . . . . . . . . . . . . . . . . . . . . . 24
5.1 Path Attribute Usage . . . . . . . . . . . . . . . . . . . . 25 5.1 Path Attribute Usage . . . . . . . . . . . . . . . . . . . . 26
5.1.1 ORIGIN . . . . . . . . . . . . . . . . . . . . . . . . . . 25 5.1.1 ORIGIN . . . . . . . . . . . . . . . . . . . . . . . . . . 26
5.1.2 AS_PATH . . . . . . . . . . . . . . . . . . . . . . . . . . 25 5.1.2 AS_PATH . . . . . . . . . . . . . . . . . . . . . . . . . . 26
5.1.3 NEXT_HOP . . . . . . . . . . . . . . . . . . . . . . . . . 26 5.1.3 NEXT_HOP . . . . . . . . . . . . . . . . . . . . . . . . . 27
5.1.4 MULTI_EXIT_DISC . . . . . . . . . . . . . . . . . . . . . . 28 5.1.4 MULTI_EXIT_DISC . . . . . . . . . . . . . . . . . . . . . . 29
5.1.5 LOCAL_PREF . . . . . . . . . . . . . . . . . . . . . . . . 28 5.1.5 LOCAL_PREF . . . . . . . . . . . . . . . . . . . . . . . . 30
5.1.6 ATOMIC_AGGREGATE . . . . . . . . . . . . . . . . . . . . . 29 5.1.6 ATOMIC_AGGREGATE . . . . . . . . . . . . . . . . . . . . . 30
5.1.7 AGGREGATOR . . . . . . . . . . . . . . . . . . . . . . . . 30 5.1.7 AGGREGATOR . . . . . . . . . . . . . . . . . . . . . . . . 31
6. BGP Error Handling . . . . . . . . . . . . . . . . . . . . . . 30 6. BGP Error Handling . . . . . . . . . . . . . . . . . . . . . . 31
6.1 Message Header error handling . . . . . . . . . . . . . . . . 30 6.1 Message Header error handling . . . . . . . . . . . . . . . . 31
6.2 OPEN message error handling . . . . . . . . . . . . . . . . . 31 6.2 OPEN message error handling . . . . . . . . . . . . . . . . . 32
6.3 UPDATE message error handling . . . . . . . . . . . . . . . . 32 6.3 UPDATE message error handling . . . . . . . . . . . . . . . . 33
6.4 NOTIFICATION message error handling . . . . . . . . . . . . . 34 6.4 NOTIFICATION message error handling . . . . . . . . . . . . . 35
6.5 Hold Timer Expired error handling . . . . . . . . . . . . . . 34 6.5 Hold Timer Expired error handling . . . . . . . . . . . . . . 35
6.6 Finite State Machine error handling . . . . . . . . . . . . . 34 6.6 Finite State Machine error handling . . . . . . . . . . . . . 35
6.7 Cease . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34 6.7 Cease . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
6.8 BGP connection collision detection . . . . . . . . . . . . . 35 6.8 BGP connection collision detection . . . . . . . . . . . . . 36
7. BGP Version Negotiation . . . . . . . . . . . . . . . . . . . 36 7. BGP Version Negotiation . . . . . . . . . . . . . . . . . . . 37
8. BGP Finite State machine . . . . . . . . . . . . . . . . . . . 36 8. BGP Finite State machine . . . . . . . . . . . . . . . . . . . 38
8.1 Events for the BGP FSM . . . . . . . . . . . . . . . . . . . 37 8.1 Events for the BGP FSM . . . . . . . . . . . . . . . . . . . 39
8.1.1 Administrative Events . . . . . . . . . . . . . . . . . . 37 8.1.1 Optional Events linked to Optional Session attributes . . . 39
8.1.2 Timer Events . . . . . . . . . . . . . . . . . . . . . . . 40 8.1.2 Administrative Events . . . . . . . . . . . . . . . . . . 44
8.1.3 TCP connection based Events . . . . . . . . . . . . . . . . 41 8.1.3 Timer Events . . . . . . . . . . . . . . . . . . . . . . . 47
8.1.4 BGP Messages based Events . . . . . . . . . . . . . . . . . 43 8.1.4 TCP connection based Events . . . . . . . . . . . . . . . . 49
8.2 Description of FSM . . . . . . . . . . . . . . . . . . . . . 45 8.1.5 BGP Messages based Events . . . . . . . . . . . . . . . . . 51
8.2.1 FSM Definition . . . . . . . . . . . . . . . . . . . . . . 45 8.2 Description of FSM . . . . . . . . . . . . . . . . . . . . . 53
8.2.1.1 Terms "active" and "passive" . . . . . . . . . . . . . . 46 8.2.1 FSM Definition . . . . . . . . . . . . . . . . . . . . . . 53
8.2.1.2 FSM and collision detection . . . . . . . . . . . . . . . 46 8.2.1.1 Terms "active" and "passive" . . . . . . . . . . . . . . 54
8.2.1.3 FSM and Optional Attributes . . . . . . . . . . . . . . 47 8.2.1.2 FSM and collision detection . . . . . . . . . . . . . . . 54
8.2.1.4 FSM Event numbers . . . . . . . . . . . . . . . . . . . . 47 8.2.1.3 FSM and Optional Attributes . . . . . . . . . . . . . . 55
8.2.2 Finite State Machine . . . . . . . . . . . . . . . . . . . 47 8.2.1.4 FSM Event numbers . . . . . . . . . . . . . . . . . . . . 55
9. UPDATE Message Handling . . . . . . . . . . . . . . . . . . . 62 8.2.1.5 FSM actions that are implementation dependent . . . . . . 56
9.1 Decision Process . . . . . . . . . . . . . . . . . . . . . . 63 8.2.2 Finite State Machine . . . . . . . . . . . . . . . . . . . 56
9.1.1 Phase 1: Calculation of Degree of Preference . . . . . . . 64 9. UPDATE Message Handling . . . . . . . . . . . . . . . . . . . 72
9.1.2 Phase 2: Route Selection . . . . . . . . . . . . . . . . . 65 9.1 Decision Process . . . . . . . . . . . . . . . . . . . . . . 73
9.1.2.1 Route Resolvability Condition . . . . . . . . . . . . . . 66 9.1.1 Phase 1: Calculation of Degree of Preference . . . . . . . 74
9.1.2.2 Breaking Ties (Phase 2) . . . . . . . . . . . . . . . . . 67 9.1.2 Phase 2: Route Selection . . . . . . . . . . . . . . . . . 74
9.1.3 Phase 3: Route Dissemination . . . . . . . . . . . . . . . 69 9.1.2.1 Route Resolvability Condition . . . . . . . . . . . . . . 76
9.1.4 Overlapping Routes . . . . . . . . . . . . . . . . . . . . 70 9.1.2.2 Breaking Ties (Phase 2) . . . . . . . . . . . . . . . . . 77
9.2 Update-Send Process . . . . . . . . . . . . . . . . . . . . . 71 9.1.3 Phase 3: Route Dissemination . . . . . . . . . . . . . . . 79
9.2.1 Controlling Routing Traffic Overhead . . . . . . . . . . . 72 9.1.4 Overlapping Routes . . . . . . . . . . . . . . . . . . . . 80
9.2.1.1 Frequency of Route Advertisement . . . . . . . . . . . . 72 9.2 Update-Send Process . . . . . . . . . . . . . . . . . . . . . 81
9.2.1.2 Frequency of Route Origination . . . . . . . . . . . . . 73 9.2.1 Controlling Routing Traffic Overhead . . . . . . . . . . . 82
9.2.2 Efficient Organization of Routing Information . . . . . . . 73 9.2.1.1 Frequency of Route Advertisement . . . . . . . . . . . . 82
9.2.2.1 Information Reduction . . . . . . . . . . . . . . . . . . 73 9.2.1.2 Frequency of Route Origination . . . . . . . . . . . . . 83
9.2.2.2 Aggregating Routing Information . . . . . . . . . . . . . 74 9.2.2 Efficient Organization of Routing Information . . . . . . . 83
9.3 Route Selection Criteria . . . . . . . . . . . . . . . . . . 76 9.2.2.1 Information Reduction . . . . . . . . . . . . . . . . . . 83
9.4 Originating BGP routes . . . . . . . . . . . . . . . . . . . 77 9.2.2.2 Aggregating Routing Information . . . . . . . . . . . . . 84
10. BGP Timers . . . . . . . . . . . . . . . . . . . . . . . . . 77 9.3 Route Selection Criteria . . . . . . . . . . . . . . . . . . 86
Appendix A. Comparison with RFC1771 . . . . . . . . . . . . . . . 78 9.4 Originating BGP routes . . . . . . . . . . . . . . . . . . . 87
Appendix B. Comparison with RFC1267 . . . . . . . . . . . . . . . 79 10. BGP Timers . . . . . . . . . . . . . . . . . . . . . . . . . 87
Appendix C. Comparison with RFC 1163 . . . . . . . . . . . . . . 80 Appendix A. Comparison with RFC1771 . . . . . . . . . . . . . . . 88
Appendix D. Comparison with RFC 1105 . . . . . . . . . . . . . . 80 Appendix B. Comparison with RFC1267 . . . . . . . . . . . . . . . 89
Appendix E. TCP options that may be used with BGP . . . . . . . . 81 Appendix C. Comparison with RFC 1163 . . . . . . . . . . . . . . 90
Appendix F. Implementation Recommendations . . . . . . . . . . . 81 Appendix D. Comparison with RFC 1105 . . . . . . . . . . . . . . 90
Appendix F.1 Multiple Networks Per Message . . . . . . . . . . . 81 Appendix E. TCP options that may be used with BGP . . . . . . . . 91
Appendix F.2 Reducing route flapping . . . . . . . . . . . . . . 82 Appendix F. Implementation Recommendations . . . . . . . . . . . 91
Appendix F.3 Path attribute ordering . . . . . . . . . . . . . . 82 Appendix F.1 Multiple Networks Per Message . . . . . . . . . . . 91
Appendix F.4 AS_SET sorting . . . . . . . . . . . . . . . . . . . 82 Appendix F.2 Reducing route flapping . . . . . . . . . . . . . . 92
Appendix F.5 Control over version negotiation . . . . . . . . . . 83 Appendix F.3 Path attribute ordering . . . . . . . . . . . . . . 92
Appendix F.6 Complex AS_PATH aggregation . . . . . . . . . . . . 83 Appendix F.4 AS_SET sorting . . . . . . . . . . . . . . . . . . . 92
Security Considerations . . . . . . . . . . . . . . . . . . . . . 84 Appendix F.5 Control over version negotiation . . . . . . . . . . 93
IANA Considerations . . . . . . . . . . . . . . . . . . . . . . . 84 Appendix F.6 Complex AS_PATH aggregation . . . . . . . . . . . . 93
Normative References . . . . . . . . . . . . . . . . . . . . . . 84 Security Considerations . . . . . . . . . . . . . . . . . . . . . 94
Non-normative References . . . . . . . . . . . . . . . . . . . . 85 IANA Considerations . . . . . . . . . . . . . . . . . . . . . . . 94
Authors Information . . . . . . . . . . . . . . . . . . . . . . . 86 IPR Notice . . . . . . . . . . . . . . . . . . . . . . . . . . . 95
Full Copyright Notice . . . . . . . . . . . . . . . . . . . . . . 95
Normative References . . . . . . . . . . . . . . . . . . . . . . 96
Non-normative References . . . . . . . . . . . . . . . . . . . . 96
Authors Information . . . . . . . . . . . . . . . . . . . . . . . 97
Abstract Abstract
The Border Gateway Protocol (BGP) is an inter-Autonomous System rout- The Border Gateway Protocol (BGP) is an inter-Autonomous System rout-
ing protocol. ing protocol.
The primary function of a BGP speaking system is to exchange network The primary function of a BGP speaking system is to exchange network
reachability information with other BGP systems. This network reacha- reachability information with other BGP systems. This network reacha-
bility information includes information on the list of Autonomous bility information includes information on the list of Autonomous
Systems (ASs) that reachability information traverses. This informa- Systems (ASs) that reachability information traverses. This informa-
tion is sufficient to construct a graph of AS connectivity from which tion is sufficient to construct a graph of AS connectivity for this
routing loops may be pruned and some policy decisions at the AS level reachability from which routing loops may be pruned and some policy
may be enforced. decisions at the AS level may be enforced.
BGP-4 provides a set of mechanisms for supporting Classless Inter- BGP-4 provides a set of mechanisms for supporting Classless Inter-
Domain Routing (CIDR) [RFC1518, RFC1519]. These mechanisms include Domain Routing (CIDR) [RFC1518, RFC1519]. These mechanisms include
support for advertising a set of destinations as an IP prefix and support for advertising a set of destinations as an IP prefix and
eliminating the concept of network "class" within BGP. BGP-4 also eliminating the concept of network "class" within BGP. BGP-4 also
introduces mechanisms which allow aggregation of routes, including introduces mechanisms which allow aggregation of routes, including
aggregation of AS paths. aggregation of AS paths.
Routing information exchanged via BGP supports only the destination- Routing information exchanged via BGP supports only the destination-
based forwarding paradigm, which assumes that a router forwards a based forwarding paradigm, which assumes that a router forwards a
skipping to change at page 7, line 13 skipping to change at page 8, line 13
Pei, Mathew Richardson, John Scudder, John Stewart III, Dave Thaler, Pei, Mathew Richardson, John Scudder, John Stewart III, Dave Thaler,
Paul Traina, Russ White, Curtis Villamizar, and Alex Zinin for their Paul Traina, Russ White, Curtis Villamizar, and Alex Zinin for their
comments. comments.
We would like to specially acknowledge Andrew Lange for his help in We would like to specially acknowledge Andrew Lange for his help in
preparing the final version of this document. preparing the final version of this document.
Finally, we would like to thank all the members of the IDR Working Finally, we would like to thank all the members of the IDR Working
Group for their ideas and support they have given to this document. Group for their ideas and support they have given to this document.
Specification of Requirements
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
document are to be interpreted as described in RFC2119 [RFC2119].
3. Summary of Operation 3. Summary of Operation
The Border Gateway Protocol (BGP) is an inter-Autonomous System rout- The Border Gateway Protocol (BGP) is an inter-Autonomous System rout-
ing protocol. It is built on experience gained with EGP as defined in ing protocol. It is built on experience gained with EGP as defined in
[RFC904] and EGP usage in the NSFNET Backbone as described in [RFC904] and EGP usage in the NSFNET Backbone as described in
[RFC1092] and [RFC1093]. [RFC1092] and [RFC1093].
The primary function of a BGP speaking system is to exchange network The primary function of a BGP speaking system is to exchange network
reachability information with other BGP systems. This network reacha- reachability information with other BGP systems. This network reacha-
bility information includes information on the list of Autonomous bility information includes information on the list of Autonomous
skipping to change at page 8, line 42 skipping to change at page 9, line 51
Two systems form a TCP connection between one another. They exchange Two systems form a TCP connection between one another. They exchange
messages to open and confirm the connection parameters. messages to open and confirm the connection parameters.
The initial data flow is the portion of the BGP routing table that is The initial data flow is the portion of the BGP routing table that is
allowed by the export policy, called the Adj-Ribs-Out (see 3.2). allowed by the export policy, called the Adj-Ribs-Out (see 3.2).
Incremental updates are sent as the routing tables change. BGP does Incremental updates are sent as the routing tables change. BGP does
not require periodic refresh of the routing table. To allow local not require periodic refresh of the routing table. To allow local
policy changes to have the correct effect without resetting any BGP policy changes to have the correct effect without resetting any BGP
connections, a BGP speaker SHOULD either (a) retain the current ver- connections, a BGP speaker SHOULD either (a) retain the current ver-
sion of the routes advertised to it by all of its peers for the dura- sion of the routes advertised to it by all of its peers for the
tion of the connection, or (b) make use of the Route Refresh exten- duration of the connection, or (b) make use of the Route Refresh
sion [RFC2918]. extension [RFC2918].
KEEPALIVE messages may be sent periodically to ensure the liveness of KEEPALIVE messages may be sent periodically to ensure the liveness of
the connection. NOTIFICATION messages are sent in response to errors the connection. NOTIFICATION messages are sent in response to errors
or special conditions. If a connection encounters an error condition, or special conditions. If a connection encounters an error condition,
a NOTIFICATION message is sent and the connection is closed. a NOTIFICATION message is sent and the connection is closed.
A peer in a different AS is referred to as an external peer, while a A peer in a different AS is referred to as an external peer, while a
peer in the same AS is referred to as an internal peer. Internal BGP peer in the same AS is referred to as an internal peer. Internal BGP
and external BGP are commonly abbreviated IBGP and EBGP. and external BGP are commonly abbreviated IBGP and EBGP.
If a particular AS has multiple BGP speakers and is providing transit If a particular AS has multiple BGP speakers and is providing transit
service for other ASs, then care must be taken to ensure a consistent service for other ASs, then care must be taken to ensure a consistent
view of routing within the AS. A consistent view of the interior view of routing within the AS. A consistent view of the interior
routes of the AS is provided by the IGP used within the AS. For the routes of the AS is provided by the IGP used within the AS. For the
purpose of this document, it is assumed that a consistent view of the purpose of this document, it is assumed that a consistent view of the
routes exterior to the AS is provided by having all BGP speakers routes exterior to the AS is provided by having all BGP speakers
within the AS maintain IBGP with each other. Care must be taken to within the AS maintain IBGP with each other.
ensure that the interior routers have all been updated with transit
information before the BGP speakers announce to other ASs that tran-
sit service is being provided.
This document specifies the base behavior of the BGP protocol. This This document specifies the base behavior of the BGP protocol. This
behavior can and is modified by extention specifications. When the behavior can and is modified by extension specifications. When the
protocol is extended the new behavior is fully documented in the protocol is extended the new behavior is fully documented in the
extention specifications. extension specifications.
3.1 Routes: Advertisement and Storage 3.1 Routes: Advertisement and Storage
For the purpose of this protocol, a route is defined as a unit of For the purpose of this protocol, a route is defined as a unit of
information that pairs a set of destinations with the attributes of a information that pairs a set of destinations with the attributes of a
path to those destinations. The set of destinations are systems whose path to those destinations. The set of destinations are systems whose
IP addresses are contained in one IP address prefix carried in the IP addresses are contained in one IP address prefix carried in the
Network Layer Reachability Information (NLRI) field of an UPDATE mes- Network Layer Reachability Information (NLRI) field of an UPDATE mes-
sage, and the path is the information reported in the path attributes sage, and the path is the information reported in the path attributes
field of the same UPDATE message. field of the same UPDATE message.
Routes are advertised between BGP speakers in UPDATE messages. Mul- Routes are advertised between BGP speakers in UPDATE messages. Mul-
tiple routes that have the same path attributes can be advertised in tiple routes that have the same path attributes can be advertised in
a single UPDATE message by including multiple prefixes in the NLRI a single UPDATE message by including multiple prefixes in the NLRI
field of the UPDATE message. field of the UPDATE message.
Routes are stored in the Routing Information Bases (RIBs): namely, Routes are stored in the Routing Information Bases (RIBs): namely,
the Adj-RIBs-In, the Loc-RIB, and the Adj-RIBs-Out, as described in the Adj-RIBs-In, the Loc-RIB, and the Adj-RIBs-Out, as described in
Section 3.2. Section 3.2.
If a BGP speaker chooses to advertise the route, it MAY add to or If a BGP speaker chooses to advertise a previously received route, it
modify the path attributes of the route before advertising it to a MAY add to or modify the path attributes of the route before adver-
peer. tising it to a peer.
BGP provides mechanisms by which a BGP speaker can inform its peer BGP provides mechanisms by which a BGP speaker can inform its peer
that a previously advertised route is no longer available for use. that a previously advertised route is no longer available for use.
There are three methods by which a given BGP speaker can indicate There are three methods by which a given BGP speaker can indicate
that a route has been withdrawn from service: that a route has been withdrawn from service:
a) the IP prefix that expresses the destination for a previously a) the IP prefix that expresses the destination for a previously
advertised route can be advertised in the WITHDRAWN ROUTES field advertised route can be advertised in the WITHDRAWN ROUTES field
in the UPDATE message, thus marking the associated route as being in the UPDATE message, thus marking the associated route as being
no longer available for use no longer available for use
b) a replacement route with the same NLRI can be advertised, or b) a replacement route with the same NLRI can be advertised, or
c) the BGP speaker - BGP speaker connection can be closed, which c) the BGP speaker - BGP speaker connection can be closed, which
implicitly removes from service all routes which the pair of implicitly removes from service all routes which the pair of
speakers had advertised to each other. speakers had advertised to each other.
Changing attribute of a route is accomplished by advertising a Changing attribute(s) of a route is accomplished by advertising a
replacement route. The replacement route carries new (changed) replacement route. The replacement route carries new (changed)
attributes and has the same NLRI as the original route. attributes and has the same address prefix as the original route.
3.2 Routing Information Bases 3.2 Routing Information Base
The Routing Information Base (RIB) within a BGP speaker consists of The Routing Information Base (RIB) within a BGP speaker consists of
three distinct parts: three distinct parts:
a) Adj-RIBs-In: The Adj-RIBs-In store routing information that has a) Adj-RIBs-In: The Adj-RIBs-In store routing information that has
been learned from inbound UPDATE messages received from other BGP been learned from inbound UPDATE messages received from other BGP
speakers. Their contents represent routes that are available as an speakers. Their contents represent routes that are available as an
input to the Decision Process. input to the Decision Process.
b) Loc-RIB: The Loc-RIB contains the local routing information b) Loc-RIB: The Loc-RIB contains the local routing information
skipping to change at page 12, line 49 skipping to change at page 13, line 49
1 - OPEN 1 - OPEN
2 - UPDATE 2 - UPDATE
3 - NOTIFICATION 3 - NOTIFICATION
4 - KEEPALIVE 4 - KEEPALIVE
[RFC2918] defines one more type code. [RFC2918] defines one more type code.
4.2 OPEN Message Format 4.2 OPEN Message Format
After a TCP is established, the first message sent by each side is an After a TCP connection is established, the first message sent by each
OPEN message. If the OPEN message is acceptable, a KEEPALIVE message side is an OPEN message. If the OPEN message is acceptable, a
confirming the OPEN is sent back. KEEPALIVE message confirming the OPEN is sent back.
In addition to the fixed-size BGP header, the OPEN message contains In addition to the fixed-size BGP header, the OPEN message contains
the following fields: the following fields:
0 1 2 3 0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+
| Version | | Version |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| My Autonomous System | | My Autonomous System |
skipping to change at page 14, line 35 skipping to change at page 15, line 35
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-... +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-...
| Parm. Type | Parm. Length | Parameter Value (variable) | Parm. Type | Parm. Length | Parameter Value (variable)
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-... +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-...
Parameter Type is a one octet field that unambiguously identi- Parameter Type is a one octet field that unambiguously identi-
fies individual parameters. Parameter Length is a one octet fies individual parameters. Parameter Length is a one octet
field that contains the length of the Parameter Value field in field that contains the length of the Parameter Value field in
octets. Parameter Value is a variable length field that is octets. Parameter Value is a variable length field that is
interpreted according to the value of the Parameter Type field. interpreted according to the value of the Parameter Type field.
[RFC2842] defines the Capabilities Optional Parameter. [RFC3392] defines the Capabilities Optional Parameter.
The minimum length of the OPEN message is 29 octets (including mes- The minimum length of the OPEN message is 29 octets (including mes-
sage header). sage header).
4.3 UPDATE Message Format 4.3 UPDATE Message Format
UPDATE messages are used to transfer routing information between BGP UPDATE messages are used to transfer routing information between BGP
peers. The information in the UPDATE message can be used to construct peers. The information in the UPDATE message can be used to construct
a graph describing the relationships of the various Autonomous Sys- a graph describing the relationships of the various Autonomous Sys-
tems. By applying rules to be discussed, routing information loops tems. By applying rules to be discussed, routing information loops
skipping to change at page 18, line 49 skipping to change at page 19, line 49
(unicast) IP address of the router that SHOULD be used as (unicast) IP address of the router that SHOULD be used as
the next hop to the destinations listed in the Network Layer the next hop to the destinations listed in the Network Layer
Reachability Information field of the UPDATE message. Reachability Information field of the UPDATE message.
Usage of this attribute is defined in 5.1.3. Usage of this attribute is defined in 5.1.3.
d) MULTI_EXIT_DISC (Type Code 4): d) MULTI_EXIT_DISC (Type Code 4):
This is an optional non-transitive attribute that is a four This is an optional non-transitive attribute that is a four
octet unsigned integer. The value of this attribute MAY be octet unsigned integer. The value of this attribute MAY be
used by a BGP speaker's decision process to discriminate used by a BGP speaker's Decision Process to discriminate
among multiple entry points to a neighboring autonomous among multiple entry points to a neighboring autonomous
system. system.
Usage of this attribute is defined in 5.1.4. Usage of this attribute is defined in 5.1.4.
e) LOCAL_PREF (Type Code 5): e) LOCAL_PREF (Type Code 5):
LOCAL_PREF is a well-known attribute that is a four octet LOCAL_PREF is a well-known attribute that is a four octet
unsigned integer. A BGP speaker uses it to inform other unsigned integer. A BGP speaker uses it to inform its other
internal peers of the advertising speaker's degree of pref- internal peers of the advertising speaker's degree of pref-
erence for an advertised route. erence for an advertised route.
Usage of this attribute is defined in 5.1.5. Usage of this attribute is defined in 5.1.5.
f) ATOMIC_AGGREGATE (Type Code 6) f) ATOMIC_AGGREGATE (Type Code 6)
ATOMIC_AGGREGATE is a well-known discretionary attribute of ATOMIC_AGGREGATE is a well-known discretionary attribute of
length 0. length 0.
skipping to change at page 23, line 33 skipping to change at page 24, line 33
This section discusses the path attributes of the UPDATE message. This section discusses the path attributes of the UPDATE message.
Path attributes fall into four separate categories: Path attributes fall into four separate categories:
1. Well-known mandatory. 1. Well-known mandatory.
2. Well-known discretionary. 2. Well-known discretionary.
3. Optional transitive. 3. Optional transitive.
4. Optional non-transitive. 4. Optional non-transitive.
Well-known attributes MUST be recognized by all BGP implementations. BGP implementations MUST recognize all well-known attrbutes. Some of
Some of these attributes are mandatory and MUST be included in every these attributes are mandatory and MUST be included in every UPDATE
UPDATE message that contains NLRI. Others are discretionary and MAY message that contains NLRI. Others are discretionary and MAY or MAY
or MAY NOT be sent in a particular UPDATE message. NOT be sent in a particular UPDATE message.
All well-known attributes MUST be passed along (after proper updat- Once a BGP peer has updated any well-known attributes, it MUST pass
ing, if necessary) to other BGP peers. these attributes in any updates it transmits to its peers.
In addition to well-known attributes, each path MAY contain one or In addition to well-known attributes, each path MAY contain one or
more optional attributes. It is not required or expected that all BGP more optional attributes. It is not required or expected that all BGP
implementations support all optional attributes. The handling of an implementations support all optional attributes. The handling of an
unrecognized optional attribute is determined by the setting of the unrecognized optional attribute is determined by the setting of the
Transitive bit in the attribute flags octet. Paths with unrecognized Transitive bit in the attribute flags octet. Paths with unrecognized
transitive optional attributes SHOULD be accepted. If a path with transitive optional attributes SHOULD be accepted. If a path with
unrecognized transitive optional attribute is accepted and passed unrecognized transitive optional attribute is accepted and passed
along to other BGP peers, then the unrecognized transitive optional along to other BGP peers, then the unrecognized transitive optional
attribute of that path MUST be passed along with the path to other attribute of that path MUST be passed along with the path to other
BGP peers with the Partial bit in the Attribute Flags octet set to 1. BGP peers with the Partial bit in the Attribute Flags octet set to 1.
If a path with recognized transitive optional attribute is accepted If a path with recognized transitive optional attribute is accepted
and passed along to other BGP peers and the Partial bit in the and passed along to other BGP peers and the Partial bit in the
Attribute Flags octet is set to 1 by some previous AS, it is not set Attribute Flags octet is set to 1 by some previous AS, it MUST NOT be
back to 0 by the current AS. Unrecognized non-transitive optional set back to 0 by the current AS. Unrecognized non-transitive optional
attributes MUST be quietly ignored and not passed along to other BGP attributes MUST be quietly ignored and not passed along to other BGP
peers. peers.
New transitive optional attributes MAY be attached to the path by the New transitive optional attributes MAY be attached to the path by the
originator or by any other BGP speaker in the path. If they are not originator or by any other BGP speaker in the path. If they are not
attached by the originator, the Partial bit in the Attribute Flags attached by the originator, the Partial bit in the Attribute Flags
octet is set to 1. The rules for attaching new non-transitive octet is set to 1. The rules for attaching new non-transitive
optional attributes will depend on the nature of the specific optional attributes will depend on the nature of the specific
attribute. The documentation of each new non-transitive optional attribute. The documentation of each new non-transitive optional
attribute will be expected to include such rules. (The description of attribute will be expected to include such rules. (The description of
skipping to change at page 25, line 38 skipping to change at page 26, line 38
a) When a given BGP speaker advertises the route to an internal a) When a given BGP speaker advertises the route to an internal
peer, the advertising speaker SHALL NOT modify the AS_PATH peer, the advertising speaker SHALL NOT modify the AS_PATH
attribute associated with the route. attribute associated with the route.
b) When a given BGP speaker advertises the route to an external b) When a given BGP speaker advertises the route to an external
peer, then the advertising speaker updates the AS_PATH attribute peer, then the advertising speaker updates the AS_PATH attribute
as follows: as follows:
1) if the first path segment of the AS_PATH is of type 1) if the first path segment of the AS_PATH is of type
AS_SEQUENCE, the local system prepends its own AS number as the AS_SEQUENCE, the local system prepends its own AS number as the
last element of the sequence (put it in the leftmost position). last element of the sequence (put it in the leftmost position
If the act of prepending will cause an overflow in the AS_PATH with respect to the position of octets in the protocol mes-
segment, i.e. more than 255 ASs, it is legal to prepend a new sage). If the act of prepending will cause an overflow in the
segment of type AS_SEQUENCE and prepend its own AS number to AS_PATH segment, i.e. more than 255 ASs, it SHOULD prepend a
this new segment. new segment of type AS_SEQUENCE and prepend its own AS number
to this new segment.
2) if the first path segment of the AS_PATH is of type AS_SET, 2) if the first path segment of the AS_PATH is of type AS_SET,
the local system prepends a new path segment of type the local system prepends a new path segment of type
AS_SEQUENCE to the AS_PATH, including its own AS number in that AS_SEQUENCE to the AS_PATH, including its own AS number in that
segment. segment.
When a BGP speaker originates a route then: When a BGP speaker originates a route then:
a) the originating speaker includes its own AS number in a path a) the originating speaker includes its own AS number in a path
segment of type AS_SEQUENCE in the AS_PATH attribute of all UPDATE segment of type AS_SEQUENCE in the AS_PATH attribute of all UPDATE
skipping to change at page 28, line 28 skipping to change at page 29, line 30
5.1.4 MULTI_EXIT_DISC 5.1.4 MULTI_EXIT_DISC
The MULTI_EXIT_DISC is an optional non-transitive attribute which is The MULTI_EXIT_DISC is an optional non-transitive attribute which is
intended to be used on external (inter-AS) links to discriminate intended to be used on external (inter-AS) links to discriminate
among multiple exit or entry points to the same neighboring AS. The among multiple exit or entry points to the same neighboring AS. The
value of the MULTI_EXIT_DISC attribute is a four octet unsigned num- value of the MULTI_EXIT_DISC attribute is a four octet unsigned num-
ber which is called a metric. All other factors being equal, the exit ber which is called a metric. All other factors being equal, the exit
point with lower metric SHOULD be preferred. If received over EBGP, point with lower metric SHOULD be preferred. If received over EBGP,
the MULTI_EXIT_DISC attribute MAY be propagated over IBGP to other the MULTI_EXIT_DISC attribute MAY be propagated over IBGP to other
BGP speakers within the same AS. The MULTI_EXIT_DISC attribute BGP speakers within the same AS (see also 9.1.2.2). The
received from a neighboring AS MUST NOT be propagated to other neigh- MULTI_EXIT_DISC attribute received from a neighboring AS MUST NOT be
boring ASs. propagated to other neighboring ASs.
A BGP speaker MUST IMPLEMENT a mechanism based on local configuration A BGP speaker MUST implement a mechanism based on local configuration
which allows the MULTI_EXIT_DISC attribute to be removed from a which allows the MULTI_EXIT_DISC attribute to be removed from a
route. This MAY be done prior to determining the degree of preference route. If a BGP speaker is configured to remove the MULTI_EXIT_DISC
of the route and performing route selection (decision process phases attribute from a route, then this removal MUST be done prior to
1 and 2). determining the degree of preference of the route and performing
route selection (Decision Process phases 1 and 2).
An implementation MAY also (based on local configuration) alter the An implementation MAY also (based on local configuration) alter the
value of the MULTI_EXIT_DISC attribute received over EBGP. This MAY value of the MULTI_EXIT_DISC attribute received over EBGP. If a BGP
be done prior to determining the degree of preference of the route speaker is configured to alter the value of the MULTI_EXIT_DISC
and performing route selection (decision process phases 1 and 2). See attribute received over EBGP, then altering the value MUST be done
Section 9.1.2.2 for necessary restrictions on this. prior to determining the degree of preference of the route and per-
forming route selection (Decision Process phases 1 and 2). See Sec-
tion 9.1.2.2 for necessary restrictions on this.
5.1.5 LOCAL_PREF 5.1.5 LOCAL_PREF
LOCAL_PREF is a well-known attribute that SHALL be included in all LOCAL_PREF is a well-known attribute that SHALL be included in all
UPDATE messages that a given BGP speaker sends to the other internal UPDATE messages that a given BGP speaker sends to the other internal
peers. A BGP speaker SHALL calculate the degree of preference for peers. A BGP speaker SHALL calculate the degree of preference for
each external route based on the locally configured policy, and each external route based on the locally configured policy, and
include the degree of preference when advertising a route to its include the degree of preference when advertising a route to its
internal peers. The higher degree of preference MUST be preferred. A internal peers. The higher degree of preference MUST be preferred. A
BGP speaker uses the degree of preference learned via LOCAL_PREF in BGP speaker uses the degree of preference learned via LOCAL_PREF in
its decision process (see Section 9.1.1). its Decision Process (see Section 9.1.1).
A BGP speaker MUST NOT include this attribute in UPDATE messages that A BGP speaker MUST NOT include this attribute in UPDATE messages that
it sends to external peers, except for the case of BGP Confederations it sends to external peers, except for the case of BGP Confederations
[RFC3065]. If it is contained in an UPDATE message that is received [RFC3065]. If it is contained in an UPDATE message that is received
from an external peer, then this attribute MUST be ignored by the from an external peer, then this attribute MUST be ignored by the
receiving speaker, except for the case of BGP Confederations receiving speaker, except for the case of BGP Confederations
[RF3065]. [RF3065].
5.1.6 ATOMIC_AGGREGATE 5.1.6 ATOMIC_AGGREGATE
skipping to change at page 29, line 43 skipping to change at page 30, line 48
A BGP speaker that receives a route with the ATOMIC_AGGREGATE A BGP speaker that receives a route with the ATOMIC_AGGREGATE
attribute SHOULD NOT remove the attribute from the route when propa- attribute SHOULD NOT remove the attribute from the route when propa-
gating it to other speakers. gating it to other speakers.
A BGP speaker that receives a route with the ATOMIC_AGGREGATE A BGP speaker that receives a route with the ATOMIC_AGGREGATE
attribute MUST NOT make any NLRI of that route more specific (as attribute MUST NOT make any NLRI of that route more specific (as
defined in 9.1.4) when advertising this route to other BGP speakers. defined in 9.1.4) when advertising this route to other BGP speakers.
A BGP speaker that receives a route with the ATOMIC_AGGREGATE A BGP speaker that receives a route with the ATOMIC_AGGREGATE
attribute needs to be cognizant of the fact that the actual path to attribute needs to be aware of the fact that the actual path to des-
destinations, as specified in the NLRI of the route, while having the tinations, as specified in the NLRI of the route, while having the
loop-free property, may not be the path specified in the AS_PATH loop-free property, may not be the path specified in the AS_PATH
attribute of the route. attribute of the route.
5.1.7 AGGREGATOR 5.1.7 AGGREGATOR
AGGREGATOR is an optional transitive attribute which MAY be included AGGREGATOR is an optional transitive attribute which MAY be included
in updates which are formed by aggregation (see Section 9.2.2.2). A in updates which are formed by aggregation (see Section 9.2.2.2). A
BGP speaker which performs route aggregation MAY add the AGGREGATOR BGP speaker which performs route aggregation MAY add the AGGREGATOR
attribute which SHALL contain its own AS number and IP address. The attribute which SHALL contain its own AS number and IP address. The
IP address SHOULD be the same as the BGP Identifier of the speaker. IP address SHOULD be the same as the BGP Identifier of the speaker.
skipping to change at page 30, line 29 skipping to change at page 31, line 31
TION message with the indicated Error Code, Error Subcode, and Data TION message with the indicated Error Code, Error Subcode, and Data
fields is sent, and the BGP connection is closed, unless it is fields is sent, and the BGP connection is closed, unless it is
explicitly stated that no NOTIFICATION message is to be sent and the explicitly stated that no NOTIFICATION message is to be sent and the
BGP connection is not to be closed. If no Error Subcode is specified, BGP connection is not to be closed. If no Error Subcode is specified,
then a zero MUST be used. then a zero MUST be used.
The phrase "the BGP connection is closed" means that the TCP connec- The phrase "the BGP connection is closed" means that the TCP connec-
tion has been closed, the associated Adj-RIB-In has been cleared, and tion has been closed, the associated Adj-RIB-In has been cleared, and
that all resources for that BGP connection have been deallocated. that all resources for that BGP connection have been deallocated.
Entries in the Loc-RIB associated with the remote peer are marked as Entries in the Loc-RIB associated with the remote peer are marked as
invalid. The fact that the routes have become invalid is passed to invalid. The local system recalculates its best routes for the des-
other BGP peers before the routes are deleted from the system. tinations of the routes marked as invalid, and before the invalid
routes are deleted from the system advertises to its peers either
withdraws for the routes marked as invalid, or the new best routes
before the invalid routes are deleted from the system.
Unless specified explicitly, the Data field of the NOTIFICATION mes- Unless specified explicitly, the Data field of the NOTIFICATION mes-
sage that is sent to indicate an error is empty. sage that is sent to indicate an error is empty.
6.1 Message Header error handling. 6.1 Message Header error handling.
All errors detected while processing the Message Header are indicated All errors detected while processing the Message Header MUST be indi-
by sending the NOTIFICATION message with Error Code Message Header cated by sending the NOTIFICATION message with Error Code Message
Error. The Error Subcode elaborates on the specific nature of the Header Error. The Error Subcode elaborates on the specific nature of
error. the error.
The expected value of the Marker field of the message header is all The expected value of the Marker field of the message header is all
ones. If the Marker field of the message header is not as expected, ones. If the Marker field of the message header is not as expected,
then a synchronization error has occurred and the Error Subcode is then a synchronization error has occurred and the Error Subcode MUST
set to Connection Not Synchronized. be set to Connection Not Synchronized.
If the Length field of the message header is less than 19 or greater If at least one of the following is true:
than 4096, or if the Length field of an OPEN message is less than the
minimum length of the OPEN message, or if the Length field of an - if the Length field of the message header is less than 19 or
UPDATE message is less than the minimum length of the UPDATE message, greater than 4096, or
or if the Length field of a KEEPALIVE message is not equal to 19, or
if the Length field of a NOTIFICATION message is less than the mini- - if the Length field of an OPEN message is less than the minimum
mum length of the NOTIFICATION message, then the Error Subcode is set length of the OPEN message, or
to Bad Message Length. The Data field contains the erroneous Length
field. - if the Length field of an UPDATE message is less than the mini-
mum length of the UPDATE message, or
- if the Length field of a KEEPALIVE message is not equal to 19,
or
- if the Length field of a NOTIFICATION message is less than the
minimum length of the NOTIFICATION message,
then the Error Subcode MUST be set to Bad Message Length. The Data
field MUST contain the erroneous Length field.
If the Type field of the message header is not recognized, then the If the Type field of the message header is not recognized, then the
Error Subcode is set to Bad Message Type. The Data field contains the Error Subcode MUST be set to Bad Message Type. The Data field MUST
erroneous Type field. contain the erroneous Type field.
6.2 OPEN message error handling. 6.2 OPEN message error handling.
All errors detected while processing the OPEN message are indicated All errors detected while processing the OPEN message MUST be indi-
by sending the NOTIFICATION message with Error Code OPEN Message cated by sending the NOTIFICATION message with Error Code OPEN Mes-
Error. The Error Subcode elaborates on the specific nature of the sage Error. The Error Subcode elaborates on the specific nature of
error. the error.
If the version number contained in the Version field of the received If the version number contained in the Version field of the received
OPEN message is not supported, then the Error Subcode is set to OPEN message is not supported, then the Error Subcode MUST be set to
Unsupported Version Number. The Data field is a 2-octets unsigned Unsupported Version Number. The Data field is a 2-octets unsigned
integer, which indicates the largest locally supported version number integer, which indicates the largest locally supported version number
less than the version the remote BGP peer bid (as indicated in the less than the version the remote BGP peer bid (as indicated in the
received OPEN message), or if the smallest locally supported version received OPEN message), or if the smallest locally supported version
number is greater than the version the remote BGP peer bid, then the number is greater than the version the remote BGP peer bid, then the
smallest locally supported version number. smallest locally supported version number.
If the Autonomous System field of the OPEN message is unacceptable, If the Autonomous System field of the OPEN message is unacceptable,
then the Error Subcode is set to Bad Peer AS. The determination of then the Error Subcode MUST be set to Bad Peer AS. The determination
acceptable Autonomous System numbers is outside the scope of this of acceptable Autonomous System numbers is outside the scope of this
protocol. protocol.
If the Hold Time field of the OPEN message is unacceptable, then the If the Hold Time field of the OPEN message is unacceptable, then the
Error Subcode MUST be set to Unacceptable Hold Time. An implementa- Error Subcode MUST be set to Unacceptable Hold Time. An implementa-
tion MUST reject Hold Time values of one or two seconds. An imple- tion MUST reject Hold Time values of one or two seconds. An imple-
mentation MAY reject any proposed Hold Time. An implementation which mentation MAY reject any proposed Hold Time. An implementation which
accepts a Hold Time MUST use the negotiated value for the Hold Time. accepts a Hold Time MUST use the negotiated value for the Hold Time.
If the BGP Identifier field of the OPEN message is syntactically If the BGP Identifier field of the OPEN message is syntactically
incorrect, then the Error Subcode is set to Bad BGP Identifier. Syn- incorrect, then the Error Subcode MUST be set to Bad BGP Identifier.
tactic correctness means that the BGP Identifier field represents a Syntactic correctness means that the BGP Identifier field represents
valid IP host address. a valid unicast IP host address.
If one of the Optional Parameters in the OPEN message is not If one of the Optional Parameters in the OPEN message is not recog-
recognized, then the Error Subcode is set to Unsupported Optional nized, then the Error Subcode MUST be set to Unsupported Optional
Parameters. Parameters.
If one of the Optional Parameters in the OPEN message is recognized, If one of the Optional Parameters in the OPEN message is recognized,
but is malformed, then the Error Subcode is set to 0 (Unspecific). but is malformed, then the Error Subcode MUST be set to 0 (Unspe-
cific).
6.3 UPDATE message error handling. 6.3 UPDATE message error handling.
All errors detected while processing the UPDATE message are indicated All errors detected while processing the UPDATE message MUST be indi-
by sending the NOTIFICATION message with Error Code UPDATE Message cated by sending the NOTIFICATION message with Error Code UPDATE Mes-
Error. The error subcode elaborates on the specific nature of the sage Error. The error subcode elaborates on the specific nature of
error. the error.
Error checking of an UPDATE message begins by examining the path Error checking of an UPDATE message begins by examining the path
attributes. If the Withdrawn Routes Length or Total Attribute Length attributes. If the Withdrawn Routes Length or Total Attribute Length
is too large (i.e., if Withdrawn Routes Length + Total Attribute is too large (i.e., if Withdrawn Routes Length + Total Attribute
Length + 23 exceeds the message Length), then the Error Subcode is Length + 23 exceeds the message Length), then the Error Subcode MUST
set to Malformed Attribute List. be set to Malformed Attribute List.
If any recognized attribute has Attribute Flags that conflict with If any recognized attribute has Attribute Flags that conflict with
the Attribute Type Code, then the Error Subcode is set to Attribute the Attribute Type Code, then the Error Subcode MUST be set to
Flags Error. The Data field contains the erroneous attribute (type, Attribute Flags Error. The Data field MUST contain the erroneous
length and value). attribute (type, length and value).
If any recognized attribute has Attribute Length that conflicts with If any recognized attribute has Attribute Length that conflicts with
the expected length (based on the attribute type code), then the the expected length (based on the attribute type code), then the
Error Subcode is set to Attribute Length Error. The Data field con- Error Subcode MUST be set to Attribute Length Error. The Data field
tains the erroneous attribute (type, length and value). MUST contain the erroneous attribute (type, length and value).
If any of the mandatory well-known attributes are not present, then If any of the mandatory well-known attributes are not present, then
the Error Subcode is set to Missing Well-known Attribute. The Data the Error Subcode MUST be set to Missing Well-known Attribute. The
field contains the Attribute Type Code of the missing well-known Data field MUST contain the Attribute Type Code of the missing well-
attribute. known attribute.
If any of the mandatory well-known attributes are not recognized, If any of the mandatory well-known attributes are not recognized,
then the Error Subcode is set to Unrecognized Well-known Attribute. then the Error Subcode MUST be set to Unrecognized Well-known
The Data field contains the unrecognized attribute (type, length and Attribute. The Data field MUST contain the unrecognized attribute
value). (type, length and value).
If the ORIGIN attribute has an undefined value, then the Error Sub- If the ORIGIN attribute has an undefined value, then the Error Sub-
code is set to Invalid Origin Attribute. The Data field contains the code MUST be set to Invalid Origin Attribute. The Data field MUST
unrecognized attribute (type, length and value). contain the unrecognized attribute (type, length and value).
If the NEXT_HOP attribute field is syntactically incorrect, then the If the NEXT_HOP attribute field is syntactically incorrect, then the
Error Subcode is set to Invalid NEXT_HOP Attribute. The Data field Error Subcode MUST be set to Invalid NEXT_HOP Attribute. The Data
contains the incorrect attribute (type, length and value). Syntactic field MUST contain the incorrect attribute (type, length and value).
correctness means that the NEXT_HOP attribute represents a valid IP Syntactic correctness means that the NEXT_HOP attribute represents a
host address. valid IP host address.
The IP address in the NEXT_HOP MUST meet the following criteria to be The IP address in the NEXT_HOP MUST meet the following criteria to be
considered semantically correct: considered semantically correct:
a) It MUST NOT be the IP address of the receiving speaker a) It MUST NOT be the IP address of the receiving speaker
b) In the case of an EBGP where the sender and receiver are one IP b) In the case of an EBGP where the sender and receiver are one IP
hop away from each other, either the IP address in the NEXT_HOP hop away from each other, either the IP address in the NEXT_HOP
MUST be the sender's IP address (that is used to establish the BGP MUST be the sender's IP address (that is used to establish the BGP
connection), or the interface associated with the NEXT_HOP IP connection), or the interface associated with the NEXT_HOP IP
address MUST share a common subnet with the receiving BGP speaker. address MUST share a common subnet with the receiving BGP speaker.
If the NEXT_HOP attribute is semantically incorrect, the error SHOULD If the NEXT_HOP attribute is semantically incorrect, the error SHOULD
be logged, and the route SHOULD be ignored. In this case, a NOTIFICA- be logged, and the route SHOULD be ignored. In this case, a NOTIFICA-
TION message SHOULD NOT be sent, and connection SHOULD NOT be closed. TION message SHOULD NOT be sent, and connection SHOULD NOT be closed.
The AS_PATH attribute is checked for syntactic correctness. If the The AS_PATH attribute is checked for syntactic correctness. If the
path is syntactically incorrect, then the Error Subcode is set to path is syntactically incorrect, then the Error Subcode MUST be set
Malformed AS_PATH. to Malformed AS_PATH.
If the UPDATE message is received from an external peer, the local If the UPDATE message is received from an external peer, the local
system MAY check whether the leftmost AS in the AS_PATH attribute is system MAY check whether the leftmost (with respect to the position
of octets in the protocol message) AS in the AS_PATH attribute is
equal to the autonomous system number of the peer that sent the mes- equal to the autonomous system number of the peer that sent the mes-
sage. If the check determines that this is not the case, the Error sage. If the check determines that this is not the case, the Error
Subcode is set to Malformed AS_PATH. Subcode MUST be set to Malformed AS_PATH.
If an optional attribute is recognized, then the value of this If an optional attribute is recognized, then the value of this
attribute is checked. If an error is detected, the attribute is dis- attribute MUST be checked. If an error is detected, the attribute
carded, and the Error Subcode is set to Optional Attribute Error. MUST be discarded, and the Error Subcode MUST be set to Optional
The Data field contains the attribute (type, length and value). Attribute Error. The Data field MUST contain the attribute (type,
length and value).
If any attribute appears more than once in the UPDATE message, then If any attribute appears more than once in the UPDATE message, then
the Error Subcode is set to Malformed Attribute List. the Error Subcode MUST be set to Malformed Attribute List.
The NLRI field in the UPDATE message is checked for syntactic valid- The NLRI field in the UPDATE message is checked for syntactic valid-
ity. If the field is syntactically incorrect, then the Error Subcode ity. If the field is syntactically incorrect, then the Error Subcode
is set to Invalid Network Field. MUST be set to Invalid Network Field.
If a prefix in the NLRI field is semantically incorrect (e.g., an If a prefix in the NLRI field is semantically incorrect (e.g., an
unexpected multicast IP address), an error SHOULD be logged locally, unexpected multicast IP address), an error SHOULD be logged locally,
and the prefix SHOULD be ignored. and the prefix SHOULD be ignored.
An UPDATE message that contains correct path attributes, but no NLRI, An UPDATE message that contains correct path attributes, but no NLRI,
SHALL be treated as a valid UPDATE message. SHALL be treated as a valid UPDATE message.
6.4 NOTIFICATION message error handling. 6.4 NOTIFICATION message error handling.
skipping to change at page 35, line 5 skipping to change at page 36, line 23
A BGP speaker MAY support the ability to impose an (locally config- A BGP speaker MAY support the ability to impose an (locally config-
ured) upper bound on the number of address prefixes the speaker is ured) upper bound on the number of address prefixes the speaker is
willing to accept from a neighbor. When the upper bound is reached, willing to accept from a neighbor. When the upper bound is reached,
the speaker (under control of local configuration) either (a) dis- the speaker (under control of local configuration) either (a) dis-
cards new address prefixes from the neighbor (while maintaining BGP cards new address prefixes from the neighbor (while maintaining BGP
connection with the neighbor), or (b) terminates the BGP connection connection with the neighbor), or (b) terminates the BGP connection
with the neighbor. If the BGP speaker decides to terminate its BGP with the neighbor. If the BGP speaker decides to terminate its BGP
connection with a neighbor because the number of address prefixes connection with a neighbor because the number of address prefixes
received from the neighbor exceeds the locally configured upper received from the neighbor exceeds the locally configured upper
bound, then the speaker MUST send to the neighbor a NOTIFICATION mes- bound, then the speaker MUST send to the neighbor a NOTIFICATION mes-
sage with the Error Code Cease. sage with the Error Code Cease. The speaker MAY also log this
locally.
6.8 BGP connection collision detection. 6.8 BGP connection collision detection.
If a pair of BGP speakers try simultaneously to establish a BGP con- If a pair of BGP speakers try simultaneously to establish a BGP con-
nection to each other, then two parallel connections between this nection to each other, then two parallel connections between this
pair of speakers might well be formed. If the source IP address used pair of speakers might well be formed. If the source IP address used
by one of these connections is the same as the destination IP address by one of these connections is the same as the destination IP address
used by the other, and the destination IP address used by the first used by the other, and the destination IP address used by the first
connection is the same as the source IP address used by the other, we connection is the same as the source IP address used by the other, we
refer to this situation as connection collision. Clearly in the refer to this situation as connection collision. Clearly in the
skipping to change at page 35, line 30 skipping to change at page 36, line 49
for detecting which BGP connection is to be preserved when a colli- for detecting which BGP connection is to be preserved when a colli-
sion does occur. The convention is to compare the BGP Identifiers of sion does occur. The convention is to compare the BGP Identifiers of
the peers involved in the collision and to retain only the connection the peers involved in the collision and to retain only the connection
initiated by the BGP speaker with the higher-valued BGP Identifier. initiated by the BGP speaker with the higher-valued BGP Identifier.
Upon receipt of an OPEN message, the local system MUST examine all of Upon receipt of an OPEN message, the local system MUST examine all of
its connections that are in the OpenConfirm state. A BGP speaker MAY its connections that are in the OpenConfirm state. A BGP speaker MAY
also examine connections in an OpenSent state if it knows the BGP also examine connections in an OpenSent state if it knows the BGP
Identifier of the peer by means outside of the protocol. If among Identifier of the peer by means outside of the protocol. If among
these connections there is a connection to a remote BGP speaker whose these connections there is a connection to a remote BGP speaker whose
BGP Identifier equals the one in the OPEN message, and this connec- BGP Identifier equals the one in the OPEN message, and this
tion collides with the connection over which the OPEN message is connection collides with the connection over which the OPEN message
received then the local system performs the following collision reso- is received then the local system performs the following collision
lution procedure: resolution procedure:
1. The BGP Identifier of the local system is compared to the BGP 1. The BGP Identifier of the local system is compared to the BGP
Identifier of the remote system (as specified in the OPEN mes- Identifier of the remote system (as specified in the OPEN mes-
sage). Comparing BGP Identifiers is done by converting them to sage). Comparing BGP Identifiers is done by converting them to
host byte order and treating them as (4-octet long) unsigned inte- host byte order and treating them as (4-octet long) unsigned inte-
gers. gers.
2. If the value of the local BGP Identifier is less than the 2. If the value of the local BGP Identifier is less than the
remote one, the local system closes the BGP connection that remote one, the local system closes the BGP connection that
already exists (the one that is already in the OpenConfirm state), already exists (the one that is already in the OpenConfirm state),
skipping to change at page 36, line 30 skipping to change at page 38, line 5
version number each supports. If an open attempt fails with an Error version number each supports. If an open attempt fails with an Error
Code OPEN Message Error, and an Error Subcode Unsupported Version Code OPEN Message Error, and an Error Subcode Unsupported Version
Number, then the BGP speaker has available the version number it Number, then the BGP speaker has available the version number it
tried, the version number its peer tried, the version number passed tried, the version number its peer tried, the version number passed
by its peer in the NOTIFICATION message, and the version numbers that by its peer in the NOTIFICATION message, and the version numbers that
it supports. If the two peers do support one or more common versions, it supports. If the two peers do support one or more common versions,
then this will allow them to rapidly determine the highest common then this will allow them to rapidly determine the highest common
version. In order to support BGP version negotiation, future versions version. In order to support BGP version negotiation, future versions
of BGP MUST retain the format of the OPEN and NOTIFICATION messages. of BGP MUST retain the format of the OPEN and NOTIFICATION messages.
8. BGP Finite State machine 8. BGP Finite State machine (FSM)
The data structures and FSM described in this document are
conceptual and do not have to be implemented precisely as described
here, as long as the implementations support the described
functionality and their externally visible behavior is the same.
This section specifies the BGP operation in terms of a Finite State This section specifies the BGP operation in terms of a Finite State
Machine (FSM). The section falls into 2 parts: Machine (FSM). The section falls into 2 parts:
1) Description of Events for the State machine (Section 8.1) 1) Description of Events for the State machine (Section 8.1)
2) Description of the FSM (Section 8.2) 2) Description of the FSM (Section 8.2)
The data structures and FSM described in this document are conceptual Session attributes required (mandatory) for each connection are:
and do not have to be implemented precisely as described here, as
long as the implementations support the described functionality and
their externally visible behavior is the same.
Session Attributes required for each connection are:
1) State 1) State
2) Connect Retry timer 2) ConnectRetryCounter
3) Hold timer 3) ConnectRetryTimer
4) Hold time 4) ConnectRetryTime
5) Keepalive timer 5) HoldTimer
6) Keepalive time 6) HoldTime
7) Connect Retry Count 7) KeepaliveTimer
8) Connect Retry Initial Value 8) KeepaliveTime
The state session attribute indicates what state the BGP FSM
is in. The ConnectRetryCounter indicates the number of times
a BGP peer has tried to establish a peer session.
The mandatory attributes related to timers are described in
section 10. Each timer has a "timer" and a "time" (the initial
value).
The optional Session attributes are listed below. These optional The optional Session attributes are listed below. These optional
attributes may be supported either per connection or per local sys- attributes may be supported either per connection or per local sys-
tem: tem:
1) Delay Open flag 1) AcceptConnectionsUnconfiguredPeers
2) Open Delay Timer 2) AllowAutomaticStart
3) Perform automatic start flag 3) AllowAutomaticStop
4) Perform automatic stop flag 4) CollisionDetectEstablishedState
5) Passive TCP establishment flag 5) DampPeerOscillations
6) Perform BGP peer oscillation damping flag 6) DelayOpen
(which will be denoted as stop_peer_flap in text) 7) DelayOpenTime
7) Idle Hold timer 8) DelayOpenTimer
8) Perform Collision detect in Established flag 9) IdleHoldTime
9) Accept connections from un-configured peers 10) IdleHoldTimer
10) Track TCP state flag 11) PassiveTcpEstablishment
11) Send NOTIFICATION without an OPEN flag 12) SendNOTIFICATIONwithoutOPEN
13) TrackTcpState
The optional session attributes support different features of the BGP
functionality that have implications for the BGP FSM state
transitions. Two groups of the attributes relate to timers are:
group 1: DelayOpen, DelayOpenTime, DelayOpenTimer
group 2: DampPeerOscillations, IdleHoldTime, IdleHoldTimer
The first parameter (DelayOpen, DampPeerOscillations) is an
optional attribute that indicates that the Timer function is
active. The "Time" value specifies the initial value for "Timer"
(DelayOpenTime, IdleHoldTime). The "Timer" specifies the actual timer.
Please refer to section 8.1.1 for an explanation
of the interaction between these optional attributes and the events
signaled to the state machine. Section 8.2.1.4 also provides
a short overview of the different types of optional attributes
(flags or timers).
8.1 Events for the BGP FSM 8.1 Events for the BGP FSM
8.1.1 Administrative Events 8.1.1 Optional Events linked to Optional Session attributes
Please note that only Event 1 (manual start) and Event 2 (manual The Inputs to the BGP FSM are events. Events can either be
stop) are mandatory administrative events. All other administrative mandatory or optional. Some optional events are linked to
events are optional. The optional attributes do not have to be sup- optional session attributes. Optional session attributes enable
ported. However, if these attributes are supported, the state of the several groups of FSM functionality.
flags should be as indicated.
Event1: Manual start The description below describes the linkage between FSM
functionality, events and the optional session attributes.
Group 1: Automatic Administrative Events (Start/Stop)
Optional Session Attributes: AllowAutomaticStart, AllowAutomaticStop,
DampPeerOscillations, IdleHoldTime,
IdleHoldTimer
Option 1: AllowAutomaticStart
Description: A BGP peer connection can be started and stopped
by administrative control. This administrative
control can either be manual, based on
operator intervention, or under the control
of logic specific to a BGP implementation.
The term "automatic" refers to a start being
issued to the BGP peer connection FSM when
such logic determines that the BGP peer
connection should be restarted.
The AllowAutomaticStart attribute specifies
that this BGP connection supports automatic
starting of the BGP connection.
If the BGP implementation supports
AllowAutomaticStart, the peer may be
repeatedly restarted. Three other options
control the rate at which the automatic
restart occurs: DampPeerOscillations,
IdleHoldTime, and the IdleHoldTimer.
The DampPeerOscillations option specifies
that the implementation engages additional
logic to damp the oscillations of BGP peers
in the face of sequences of automatic start
and automatic stop. IdleHoldTime specifies
how long the BGP peer is held in the Idle
state prior to allowing the next automatic
restart. The IdleHoldTimer is the timer
that runs to hold the peer in Idle state.
An example of DampPeerOscillations logic
is an increase of the IdleHoldTime value
if a BGP peer oscillates connectivity
(connected/disconnected) repeatedly
within a time period. To engage this
logic, a peer could connected and disconnect
10 times within 5 minutes. The IdleHoldTime
value would be reset from 0 to 120 seconds.
Values: TRUE or FALSE
Option 2: AllowAutomaticStop
Description: This BGP peer session optional attribute
indicates that the BGP connection allows
"automatic" stopping of the BGP connection.
An "automatic" stop is defined as a stop under
the control of implementation specific logic.
The implementation specific logic is outside
the scope of this specification.
Values: TRUE or FALSE
Option 3: DampPeerOscillations
Description: The DampPeerOscillations optional session
attribute indicates that this BGP connection
is using logic that damps BGP peer oscillations
in the Idle State.
Value: TRUE or FALSE
Option 4: IdleHoldTime
Description: The IdleHoldTime is a the value
that is set in the IdleHoldtimer.
Values: Time in seconds
Option 5: IdleHoldTimer
Description: The IdleHoldTimer aids in controlling BGP peer
oscillation. The IdleHoldTimer is used to keep
the BGP peer in Idle for a particular duration.
The IdleHoldTimer expired event is described
in section 8.1.3.
Values: Time in seconds
Group 2: Unconfigured Peers
Optional Session Attributes: AcceptConnectionsUnconfiguredPeers
Option 1: AcceptConnectionsUnconfiguredPeers
Description: The BGP FSM optionally allows the acceptance of BGP
peer connections from neighbors that are not
pre-configured. The
"AcceptConnectionsUnconfiguredPeers" optional
session attribute allows the FSM to support
the state transitions that allow the
implementation to accept or reject these
unconfigured peers.
The AcceptConnectionsUnconfiguredPeers has
security implications. Please refer to the
BGP Vulnerabilities document[BGP_VULN] for
details.
Value: True or False
Group 3: TCP processing
Optional Session Attributes: PassiveTcpEstablishment, TrackTcpState
Option 1: PassiveTcpEstablishment
Description: This option indicates that the BGP FSM will passively
wait for the remote BGP peer to establish the BGP
TCP connection.
value: TRUE or FALSE
Option 2: TrackTcpState
Description: The BGP FSM normally tracks the end result of a TCP
connection attempt rather than individual TCP messages.
Optionally, the BGP FSM can support additional
interaction with the TCP connection negotiation. The
interaction with the TCP events may increase the
amount of logging the BGP peer connection
requires and the number of BGP FSM changes.
Value: TRUE or FALSE
Group 4: BGP Message Processing
Optional Session Attributes: DelayOpen, DelayOpenTimer,
SendNOTIFICATIONwithoutOPEN,
CollisionDetectEstablishedState
Option 1: DelayOpen
Description: The DelayOpen optional session attribute allows
implementations to be configured to delay
sending an OPEN message for specific time
period (DelayOpenTime). The delay allows
the remote BGP Peer time to send the first
OPEN message.
Value: TRUE or FALSE
Option 2: DelayOpenTime
Description: The DelayOpenTime is the initial value that is
set in the DelayOpenTimer.
Value: Time in seconds
Option 3: DelayOpenTimer
Description: The DelayOpenTimer optional session attribute
specifies a time that the local system will wait
prior to sending an OPEN message on the connection.
Value: Time in seconds
Option 4: SendNOTIFICATIONwithoutOPEN
Description: The SendNOTIFICIATONwithoutOPEN allows a peer to
send a NOTIFICATION without first sending an
OPEN message. Without this optional session
attribute, the BGP connection assumes that an
OPEN message must be sent by a peer prior
to the peer sending a NOTIFICATION message.
Value: True or False
Option 5: CollisionDetectEstablishedState
Description: Normally, a Detect Collision (6.8) will
be ignored in the Established state. This
optional session attribute indicates that
this BGP connection processes a
collisions in the Established state.
Value: True or False
Note: The optional session attributes clarify the BGP FSM description
for existing features of BGP implementations. The optional
session attributes may be pre-defined for an implementation
and not readable via management interfaces for existing
correct implementations. As newer BGP MIBs (version 2
and beyond) are supported, these fields will be accessible
via a management interface.
8.1.2 Administrative Events
An administrative event is an event in which the operator interface
and BGP Policy engine signal the BGP finite state machine to start or
stop the BGP state machine. The basic start and stop indication are
augmented by optional connection attributes to signal a certain type
of start or stop mechanism to the BGP FSM. An example of this combi-
nation is event 5, AutomaticStart_with_PassiveTcpEstablishment. With
this event, the BGP implementation signals to the BGP FSM that the
implementation is using an Automatic Start with option to use a Pas-
sive TCP Establishment. The Passive TCP establishment signals that
this BGP FSM will wait for the remote side to start the TCP estab-
lishment.
Please note that only Event 1 (ManualStart) and Event 2 (ManualStop)
are mandatory administrative events. All other administrative events
are optional (Events 3-8). Each event below has a name, definition,
status (mandatory or optional), and what optional session attributes
SHOULD be set at each stage. When generating Event 1 through Event 8
for the BGP FSM, the conditions specified in the "Optional Attribute
Status" section are verified. If any of these conditions are not
satisfied, then the local system should log a FSM error.
The settings of optional session attributes may be implicit in some
implementations and therefore may not be set explicitly by an exter-
nal operator action. Section 8.2.1.5 describes these implicit set-
tings of the optional session attributes. The administrative states
described below may also be implicit in some implementations and not
directly configurable by an external operator.
Event1: ManualStart
Definition: Local system administrator manually starts peer Definition: Local system administrator manually starts peer
connection. connection.
Status: Mandatory Status: Mandatory
Optional Optional
attributes: Passive TCP establishment flag SHOULD not be set. Attribute
Status: The PassiveTcpEstablishment attribute SHOULD be
set to FALSE.
Event2: ManualStop
Event2: Manual stop
Definition: Local system administrator manually Definition: Local system administrator manually
stops the peer connection. stops the peer connection.
Status: Mandatory Status: Mandatory
Event3: Automatic start Optional
Attribute
Status: No interaction with any optional attributes.
Event3: AutomaticStart
Definition: Local system automatically starts the Definition: Local system automatically starts the
BGP connection. BGP connection.
Status: Optional depending on local system. Status: Optional, depending on local system
Optional Optional
attributes: 1) Perform automatic start flag SHOULD be set Attribute
Status: 1) The AllowAutomaticStart attribute SHOULD be set
if this event occurs. if this event occurs.
2) if the passive Passive TCP establishment flag 2) If the PassiveTcpEstablishment optional session
is supported, it SHOULD not be set if this attribute is supported, it SHOULD be set to FALSE.
event occurs. 3) If the DampPeerOscillations is supported, it
3) if bgp peer oscillation damping is supported, SHOULD be set to FALSE when this event occurs.
the BGP stop_peer_flap flag should not be set
when this event occurs.
Event4: Manual start with passive TCP flag Event4: ManualStart_with_PassiveTcpEstablishment
Definition: Local system administrator manually starts the peer Definition: Local system administrator manually starts the peer
connection, but has the passive TCP establishment connection, but has the PassiveTcpEstablishment
enabled. The passive TCP establishment flag indicates enabled. The PassiveTcpEstablishment optional
that the peer will listen prior to attribute indicates that the peer will listen prior
establishing the connection. to establishing the connection.
Status: Optional depending on local system. Status: Optional, depending on local system
Optional Optional
attributes: 1) Passive TCP Establishment flag SHOULD be set. Attribute
if this event occurs. Status: 1) The PassiveTcpEstablishment attribute SHOULD
2) If bgp peer oscilation damping is supported, the be set to TRUE if this event occurs.
stop_peer_flap flag should not be set when 2) The DampPeerOscillations attribute SHOULD be
this event occurs. set to FALSE when this event occurs.
Event5: Automatic start with passive TCP flag Event5: AutomaticStart_with_PassiveTcpEstablishment
Definition: Local system automatically starts the Definition: Local system automatically starts the
BGP connection with the passive flag BGP connection with the PassiveTcpEstablishment
enabled. The passive flag indicates enabled. The PassiveTcpEstablishment
optional attribute indicates
that the peer will listen prior to that the peer will listen prior to
establishing a connection. establishing a connection.
Status: Optional depending on local system use Status: Optional, depending on local system
of a passive connection and automatic start.
Optional Optional
attributes: 1) Perform Automatic start flag SHOULD be set Attribute
2) Passive TCP establishment flag SHOULD be set Status: 1) The AllowAutomaticStart attribute SHOULD
3) If the bgp peer oscillation flag is supported, be set to TRUE.
the stop_peer_flap flag SHOULD not be set. 2) The PassiveTcpEstablishment attribute SHOULD
be set to TRUE
3) If the DampPeerOscillations attribute is
supported, the DampPeerOscillations SHOULD
be set to FALSE.
Event6: Automatic start with bgp_stop_flap option set Event6: AutomaticStart_with_DampPeerOscillations
Definition: Local system automatically starts the Definition: Local system automatically starts the
BGP peer connection with peer oscillation BGP peer connection with peer oscillation
damping enabled. The exact method of damping damping enabled. The exact method of damping
persistent peer oscillations is left up to the persistent peer oscillations is left up to the
implementation, and is outside the scope of implementation and is outside the scope of
this document. this document.
Status: Optional, used only if the bgp peer has enabled Status: Optional, depending on local system.
bgp peer oscillation damping enabled with the
optional attribute settings below.
Optional Optional
attributes: 1) Perform automatic start flag SHOULD be set Attribute
2) stop_peer_flap flag SHOULD be set Status: 1) The AllowAutomaticStart attribute SHOULD
3) Passive TCP establishment flag SHOULD not be set be set to TRUE.
(cleared). 2) The DampPeerOscillations attribute SHOULD
be set to TRUE.
3) The PassiveTcpEstablishment attribute
SHOULD be set to FALSE.
Event 7: Automatic start with bgp_stop_flap option set and passive Event 7: AutomaticStart_with_DampPeerOscillations_and_
TCP establishment option set PassiveTcpEstablishment
Definition: Local system automatically starts the Definition: Local system automatically starts the
BGP peer connection with peer oscillation BGP peer connection with peer oscillation
damping enabled and passive TCP establishment damping enabled and PassiveTcpEstablishment
enabled. The exact method of damping enabled. The exact method of damping
persistent peer oscillations is left up to the persistent peer oscillations is left up to the
implementation, and is outside the scope of implementation and is outside the scope of
this document. this document.
Status: Optional, used only if the bgp peer has enabled Status: Optional, depending on local system
bgp peer oscillation damping with following optional
flags settings below.
Optional Optional
attributes: 1) Perform automatic start flag SHOULD be set Attributes
2) stop_peer_flap flag SHOULD be set Status: 1) The AllowAutomaticStart attribute
3) Passive TCP establishment flag SHOULD be set SHOULD be set to TRUE.
2) The DampPeerOscillations attribute SHOULD
be set to TRUE.
3) The PassiveTcpEstablishment attribute
SHOULD be set to TRUE.
Event8: Automatic stop Event8: AutomaticStop
Definition: Local system automatically stops the Definition: Local system automatically stops the
BGP connection. BGP connection.
An example of an automatic stop event is An example of an automatic stop event is
exceeding the number of prefixes for a given exceeding the number of prefixes for a given
peer and the local system automatically peer and the local system automatically
disconnecting the peer. disconnecting the peer.
Status: Optional depending on local system Status: Optional, depending on local system
Optional Optional
attributes: 1) Peform automatic stop flag SHOULD Be set Attribute
Status: 1) The AllowAutomaticStop attribute
8.1.2 Timer Events SHOULD be TRUE
Event9: Connect retry timer expires 8.1.3 Timer Events
Definition: An event generated when the Connect Retry timer Event9: ConnectRetryTime_Expires
Definition: An event generated when the ConnectRetryTimer
expires. expires.
Status: Mandatory Status: Mandatory
Event10: Hold timer expires Event10: HoldTimer_Expires
Definition: An event generated when the Hold Timer expires. Definition: An event generated when the Hold Timer expires.
Status: Mandatory Status: Mandatory
Event11: Keepalive timer expires Event11: KeepaliveTimer_Expires
Definition: An event generated when the Keepalive timer expires. Definition: An event generated when the KeepaliveTimer expires.
Status: Mandatory Status: Mandatory
Event12: Open Delay timer expires Event12: DelayOpenTimer_Expires
Definition: An event generated when the Open Delay timer expires.
Definition: An event generated when the DelayOpenTimer expires.
Status: Optional Status: Optional
Optional Optional
attributes: If this event occurs, Attribute
1) Delay Open flag SHOULD be set Status: If this event occurs,
2) Open Delay timer SHOULD be supported 1) DelayOpen attribute SHOULD be set to TRUE,
2) DelayOpenTime attribute SHOULD be supported,
3) DelayOpenTimer SHOULD be supported,
Event13: Idle hold timer expires Event13: IdleHoldTimer_Expires
Definition: An event generated when the Idle Hold Timer Definition: An event generated when the Idle Hold Timer
expires indicating that the session has completed expires indicating that the BGP connection has
waiting for a back-off period to prevent bgp peer completed waiting for the back-off period
oscillation. to prevent BGP peer oscillation.
The Idle Hold Timer is only used when the persistent The IdleHoldTimer is only used when the
peer oscillation damping function is enabled. persistent peer oscillation damping
function is enabled by setting the
DampPeerOscillations optional attribute
is set to TRUE.
Implementations not implementing the presistent peer Implementations not implementing the
oscillation damping function may not have the Idle Hold persistent peer oscillation damping
Timer. function may not have the IdleHoldTimer.
Status: Optional Status: Optional
Optional Optional
Attributes: If this event occurs: Attribute
1) stop_peer_flap flag SHOULD be set indicating Status: If this event occurs:
support for persistent peer oscillation damping 1) DampPeerOscillations attribute SHOULD be set
functions, to TRUE.
2) Idle Hold timer should be supported 2) IdleHoldTimer SHOULD have just expired.
8.1.3 TCP Connection based Events 8.1.4 TCP Connection based Events
Event14: TCP connection valid indication Event14: TcpConnection_Valid
Definition: Event indicating the local system reception of Definition: Event indicating the local system reception of
a TCP connection request with a valid source a TCP connection request with a valid
IP address and TCP port, and valid destination source IP address and TCP port and a valid
IP address and TCP Port. The definition of destination IP address and TCP Port. The
invalid source, and invalid destination definition of invalid source and invalid
IP address is left to the implementation. destination IP address is left to the
implementation.
BGP's destination port SHOULD be port BGP's destination port SHOULD be port 179
179 as defined by IANA. as defined by IANA.
TCP connection request is denoted by TCP connection request is denoted by the
the local system receiving a TCP SYN. local system receiving a TCP SYN.
Status: Optional Status: Optional
Optional Optional
Attributes: 1) The Track TCP state flag SHOULD be set if Attribute
this event occurs. Status: 1) The TrackTcpState attribute SHOULD be set to
TRUE if this event occurs.
Event15: RCV TCP invalid indication Event15: Tcp_CR_Invalid
Definition: Event indicating the local system reception of Definition: Event indicating the local system reception
a TCP connection request with either of a TCP connection request with either
an invalid source address or port an invalid source address or port
number or an invalid destination number or an invalid destination
address or port number. address or port number.
BGP destination port number SHOULD be 179 BGP destination port number SHOULD be 179
as defined by IANA. as defined by IANA.
Again, a TCP connection request A TCP connection request occurs when
denoted by local system receiving a TCP the local system receives a TCP
SYN. SYN.
Status: Optional Status: Optional
Optional Optional
Attributes: 1) The Track TCP state should be set if this event Attribute
occurs. Status: 1) The TrackTcpState attribute should be set to
TRUE if this event occurs.
Event16: TCP connection request Acknowledged Event16: Tcp_CR_Acked
Definition: Event indicating the Local system's request Definition: Event indicating the local system's request
to establish a TCP connection to the remote to establish a TCP connection to the remote
peer. peer.
The local system's TCP session sent a TCP The local system's TCP connection sent a TCP
SYN, and received a TCP SYN, ACK messages, SYN, and received a TCP SYN/ACK messages,
and Sent a TCP ACK. and sent a TCP ACK.
Status: Mandatory Status: Mandatory
Event17: TCP connection confirmed Event17: TcpConnectionConfirmed
Definition: Event indicates that the local system receiving
a confirmation that the TCP connection has Definition: Event indicating that the local system has
been established by the remote site. received a confirmation that the TCP
connection has been established by the
remote site.
The remote peer's TCP engine sent a TCP SYN. The remote peer's TCP engine sent a TCP SYN.
The local peer's TCP engine sent a SYN, ACK The local peer's TCP engine sent a SYN, ACK
message, and now has received a final ACK. message and now has received a final ACK.
Status: Mandatory Status: Mandatory
Event18: TCP connection fails Event18: TcpConnectionFails
Definition: Event indicates that the local system has Definition: Event indicating that the local system has
received a TCP connection failure notice. received a TCP connection failure notice.
The remote BGP peer's TCP machine could have The remote BGP peer's TCP machine could have
sent a FIN. The local peer would respond sent a FIN. The local peer would respond
with a FIN-ACK. Another alternative is that with a FIN-ACK. Another alternative is that
the local peer indicated a timeout in the the local peer indicated a timeout in the
TCP session and downed the connection. TCP connection and downed the connection.
Status: Mandatory Status: Mandatory
8.1.4 BGP Messages based Events 8.1.5 BGP Message-based Events
Event19: BGPOpen Event19: BGPOpen
Definition: An event is generated when a valid OPEN Definition: An event is generated when a valid OPEN
message has been received. message has been received.
Status: Mandatory Status: Mandatory
optional Optional
attributes: 1) Delay Open flag SHOULD not be set Attribute
2) Open Delay timer SHOULD not be running Status: 1) The DelayOpen optional attribute SHOULD
be set to FALSE.
2) The DelayOpenTimer SHOULD not be running.
Event20: BGPOpen with Open Delay Timer running Event20: BGPOpen with DelayOpenTimer running
Definition: An event is generated when valid OPEN Definition: An event is generated when a valid OPEN
message has been received for a peer message has been received for a peer
that has a successfully established that has a successfully established
transport connection and is currently transport connection and is currently
delaying the sending of a BGP open delaying the sending of a BGP open
message. message.
Status: Optional Status: Optional
Optional Optional
attributes: 1) Delay Open Flag SHOULD be set Attribute
2) Open Delay Timer SHOULD be running. Status: 1) The DelayOpen attribute SHOULD be
set to TRUE.
2) The DelayOpenTimer SHOULD be running.
Event21: BGPHeaderErr Event21: BGPHeaderErr
Definition: An event is generated when a received Definition: An event is generated when a received
BGP message header is not valid. BGP message header is not valid.
Status: Mandatory Status: Mandatory
Event22: BGPOpenMsgErr Event22: BGPOpenMsgErr
Definition: An event is generated when an OPEN message Definition: An event is generated when an OPEN message
has been received with errors. has been received with errors.
Status: Mandatory Status: Mandatory
Event23: Open collision dump Event23: OpenCollisionDump
Definition: An event generated administratively Definition: An event generated administratively
when a connection collision has been when a connection collision has been
detected while processing an incoming detected while processing an incoming
OPEN message and this connection has been OPEN message and this connection has been
selected to disconnected. See Section selected to be disconnected. See section
6.8 for more information on collision 6.8 for more information on collision
detection. detection.
Event23 is an administrative based only Event23 is an administrative action
implementation specific policy. This generated by implementation logic
Event may occur if the FSM is implemented that determines that this connection
as two linked state machines. needs to be dropped per the rules in
section 6.8. This event may occur if the FSM
is implemented as two linked state machines.
Status: Optional, depending on local system Status: Optional, depending on local system
Optional Optional
Attributes: If the state machine is to process this Attribute
Status: If the state machine is to process this
attribute in Established state, attribute in Established state,
1) Peform Collision detect in Established 1) CollisionDetectEstablished
flag SHOULD be set. optional attribute SHOULD be set to TRUE
Please note: The Open collision dump can occur Please note: The OpenCollisionDump event can occur
in Idle, Connect, Active, OpenSent, OpenConfirm in Idle, Connect, Active, OpenSent, OpenConfirm
without any optional flags being set. without any optional attributes being set.
Event24: NotifMsgVerErr Event24: NotifMsgVerErr
Definition: An event is generated when a Definition: An event is generated when a
NOTIFICATION message with "version NOTIFICATION message with "version
error" is received. error" is received.
Status: Mandatory Status: Mandatory
Event25: NotifMsg Event25: NotifMsg
skipping to change at page 45, line 16 skipping to change at page 53, line 4
Event24: NotifMsgVerErr Event24: NotifMsgVerErr
Definition: An event is generated when a Definition: An event is generated when a
NOTIFICATION message with "version NOTIFICATION message with "version
error" is received. error" is received.
Status: Mandatory Status: Mandatory
Event25: NotifMsg Event25: NotifMsg
Definition: An event is generated when a Definition: An event is generated when a
NOTIFICATION messages is received and NOTIFICATION message is received and
the error code is anything but the error code is anything but
"version error". "version error".
Status: Mandatory Status: Mandatory
Event26: KeepAliveMsg Event26: KeepAliveMsg
Definition: An event is generated when a KEEPALIVE Definition: An event is generated when a KEEPALIVE
message is received. message is received.
skipping to change at page 46, line 7 skipping to change at page 53, line 36
Definition: An event is generated when an invalid Definition: An event is generated when an invalid
UPDATE message is received. UPDATE message is received.
Status: Mandatory Status: Mandatory
8.2 Description of FSM 8.2 Description of FSM
8.2.1 FSM Definition 8.2.1 FSM Definition
BGP MUST maintain a separate FSM for each configured peer, Each BGP BGP MUST maintain a separate FSM for each configured peer. Each BGP
peer paired in a potential connection unless configured to remain in peer paired in a potential connection, unless configured to remain in
the idle state, or configured to remain passive, will attempt to to the idle state, or configured to remain passive, will attempt to con-
connect to the other. For the purpose of this discussion, the active nect to the other. For the purpose of this discussion, the active or
or connect side of the TCP connection (the side of a TCP connection connecting side of the TCP connection (the side of a TCP connection
sending the first TCP SYN packet) is called outgoing. The passive or sending the first TCP SYN packet) is called outgoing. The passive or
listening side (the sender of the first SYN ACK) is called an incom- listening side (the sender of the first SYN/ACK) is called an incom-
ing connection (see Section 8.2.1.1 on the terms active and passive ing connection. (See Section 8.2.1.1 for information on the terms
below). active and passive used below.)
A BGP implementation MUST connect to and listen on TCP port 179 for A BGP implementation MUST connect to and listen on TCP port 179 for
incoming connections in addition to trying to connect to peers. For incoming connections in addition to trying to connect to peers. For
each incoming connection, a state machine MUST be instantiated. each incoming connection, a state machine MUST be instantiated.
There exists a period in which the identity of the peer on the other There exists a period in which the identity of the peer on the other
end of an incoming connection is known but the BGP identifier is not end of an incoming connection is known, but the BGP identifier is not
known. During this time, both an incoming and an outgoing connection known. During this time, both an incoming and an outgoing connection
for the same configured peering may exist. This is referred to as a for the same configured peering may exist. This is referred to as a
connection collision (see Section 6.8). connection collision. (See Section 6.8.)
A BGP implementation will have at most one FSM for each configured A BGP implementation will have at most one FSM for each configured
peering plus one FSM for each incoming TCP connection for which the peering plus one FSM for each incoming TCP connection for which the
peer has not yet been identified. Each FSM corresponds to exactly one peer has not yet been identified. Each FSM corresponds to exactly one
TCP connection. TCP connection.
There may be more than one connections between a pair of peers if the There may be more than one connection between a pair of peers if the
connections are configured to use a different pair of IP addresses. connections are configured to use a different pair of IP addresses.
This is referred to as multiple "configured peerings" to the same This is referred to as multiple "configured peerings" to the same
peer. peer.
8.2.1.1 Terms "active" and "passive" 8.2.1.1 Terms "active" and "passive"
The terms active and passive have been in our vocabulary for almost a The terms active and passive have been in the Internet operator's
decade and have proven useful. The words active and passive have vocabulary for almost a decade and have proven useful. The words
slightly different meanings applied to a TCP connection or applied to active and passive have slightly different meanings applied to a TCP
a peer. There is only one active side and one passive side to any connection or applied to a peer. There is only one active side and
one TCP connection per the definition above and the state machine one passive side to any one TCP connection per the definition above
below. When a BGP speaker is configured active it may end up on and the state machine below. When a BGP speaker is configured active,
either the active or passive side of the connection that eventually it may end up on either the active or passive side of the connection
gets established. Once the TCP connection is completed, it doesn't that eventually gets established. Once the TCP connection is com-
matter which end was active and which end was passive and the only pleted, it doesn't matter which end was active and which end was pas-
difference is which side of the TCP connection has port number 179. sive. The only difference is which side of the TCP connection has
port number 179.
8.2.1.2 FSM and collision detection 8.2.1.2 FSM and collision detection
There is one FSM per BGP connection. Prior to determining what peer There is one FSM per BGP connection. When the connection collision
a connection is associated with there may be two connections for a occurs prior to determining what peer a connection is associated
given peer. There SHOULD be no more than one connection per peer. with, there may be two connections for one peer. After the connec-
The collision detection identifies the case where there is more than tion collision is resolved (see Section 6.8) the FSM for the connec-
one connection per peer and provides guidance for which connection to
get rid of. When this occurs, the corresponding FSM for the connec-
tion that is closed SHOULD be disposed of. tion that is closed SHOULD be disposed of.
8.2.1.3 FSM and Optional Attributes 8.2.1.3 FSM and Optional Session Attributes
Optional Attributes specify either flags that augment the normal pro-
cessing of the BGP FSM, or optional timers. If a Optional attribute
can be set on a system, the Events and the BGP FSM actions must be
supported. For example, if the following options can be set in a BGP
implementation: AutoStart and Passive TCP connection Establishment
flag, then the events 3, 4 and 5 must be supported.
If an Optional attribute cannot be set (that is declared always off Optional Session Attributes specify either attributes that act
logically), the events supporting that set of options do not have to as flags (TRUE or FALSE) or optional timers. For optional
attributes that act as flags, if the optional session attribute
can be set to TRUE on the system, the corresponding the BGP FSM
actions must be supported. For example, if the following options
can be set in a BGP implementation: AutoStart and
PassiveTCPEstablishment, then the events 3, 4 and 5 must be
supported. If an Optional Session attribute cannot be set to
TRUE, the events supporting that set of options do not have to
be supported. be supported.
Each of the optional timers (DelayOpenTimer and IdleHoldTimer),
has a group of attributes that are:
- flag indicating support,
- Time set in Timer
- Timer.
The two optional timers show this format:
DelayOpenTimer: DelayOpen, DelayOpenTime, DelayOpenTimer
IdleHoldTimer: DampPeerOscillations, IdleHoldTime,
IdleHoldTmer
If the flag indicating support for an optional timer
(DelayOpen or DampPeerOscillations), cannot be set to TRUE,
the timers and events supporting that
option do not have to be supported.
8.2.1.4 FSM Event numbers 8.2.1.4 FSM Event numbers
The Event numbers (1-28) utilized in this state machine description The Event numbers (1-28) utilized in this state machine description
aid in specifying the behavior of the BGP state machine. Implementa- aid in specifying the behavior of the BGP state machine. Implementa-
tions MAY use these numbers to provide network management informa- tions MAY use these numbers to provide network management informa-
tion. The exact form of the FSM and the FSM events is specific to tion. The exact form of a FSM or the FSM events are specific to each
each implementation. implementation.
8.2.1.5 FSM actions that are implementation dependent.
The BGP FSM specifies at certain points that BGP initialization will
occur or that BGP resources will be deleted. The initialization of
the BGP FSM and the associated resources depend on the policy portion
of the BGP implementation. The details of these actions are outside
the scope of the FSM document.
8.2.2 Finite State Machine 8.2.2 Finite State Machine
Idle state: Idle state:
Initially BGP is in the Idle state. Initially the BGP peer FSM is in the Idle state. (Hereafter
the BGP peer FSM will be shortened to BGP FSM.)
In this state BGP refuses all incoming BGP connections. No In this state BGP FSM refuses all incoming BGP
resources are allocated to the peer. In response to a connections for this peer. No resources are allocated to the peer.
manual start event(Event1) or an automatic start In response to a ManualStart event (Event 1) or an
event(Event3), the local system: AutomaticStart event (Event 3), the local system:
- initializes all BGP resources, - initializes all BGP resources for the peer connection,
- sets ConnectRetryCnt (the connect retry counter) to zero - sets ConnectRetryCounter to zero,
- starts the Connect Retry timer with initial value, - starts the ConnectRetryTimer with initial value,
- initiates a TCP connection to the other BGP peer, - initiates a TCP connection to the other BGP peer,
- listens for a connection that may be initiated by - listens for a connection that may be initiated by
the remote BGP peer, and the remote BGP peer, and
- changes its state to Connect. - changes its state to Connect.
The manual stop event (Event2) and Automatic stop event (Event 8) The ManualStop event (Event 2) and AutomaticStop (Event 8) event
are ignored in the Idle state. are ignored in the Idle state.
In response to a manual start event with the passive TCP connection In response to a ManualStart_with_PassiveTcpEstablishment event
flag (Event 4) or automatic start with the passive TCP connection (Event 4) or AutomaticStart_with_PassiveTcpEstablishment event
flag (Event 5), the local system: (Event 5), the local system:
- initializes all BGP resources, - initializes all BGP resources,
- sets ConnectRetryCnt (the connect retry counter) to zero, - sets the ConnectRetryCounter to zero,
- starts the Connect Retry timer with initial value, - starts the ConnectRetryTimer with initial value,
- listens for a connection that may be initiated by - listens for a connection that may be initiated by
the remote peer, and the remote peer, and
- changes its state to Active. - changes its state to Active.
The exact value of the ConnectRetry timer is a local The exact value of the ConnectRetryTimer is a local
matter, but it SHOULD be sufficiently large to allow TCP matter, but it SHOULD be sufficiently large to allow TCP
initialization. initialization.
If the persistent peer oscillation damping function is If the DampPeerOscillations attribute is set to TRUE,
enabled, three additional events may occur within Idle state: the following three additional events may occur
- Automatic start with peer_stop_flap set [Event6], within Idle state:
- Automatic start with peer_stop_flap set and - AutomaticStart_with_DampPeerOscillations (Event6),
passive TCP establishment flag set [Event7], - AutomaticStart_with_DampPeerOscillations_and_
- Idle Hold Timer expired [Event 13]. PassiveTcpEstablishment (Event7),
- IdleHoldTimer_Expired (Event 13).
Upon receiving these 3 events, the local system will
use these events to prevent peer oscillations.
The method of preventing persistent peer oscillation is The method of preventing persistent peer oscillation is
outside the scope of this document. outside the scope of this document.
Any other events [Events 9-12, 15-28] received in the Idle state Any other event (Events 9-12, 15-28) received in the Idle state
does not cause change in the state of the local system. does not cause change in the state of the local system.
Connect State: Connect State:
In this state, BGP is waiting for the TCP connection to In this state, BGP FSM is waiting for the TCP connection to
be completed. be completed.
The start events [Event 1, 3-7] are ignored in connect The start events (Events 1, 3-7) are ignored in connect
state. state.
In response to a manual stop event [Event2], the local system: In response to a ManualStop event [Event 2), the local system:
- drops the TCP connection, - drops the TCP connection,
- releases all BGP resources, - releases all BGP resources,
- sets ConnectRetryCnt (the connect retry count) to zero - sets ConnectRetryCounter to zero,
- sets the Connect Retry timer to zero, and - stops the ConnectRetryTimer and sets ConnectRetryTimer
to zero, and
- changes its state to Idle. - changes its state to Idle.
In response to the Connect Retry timer expires event [Event In response to the ConnectRetryTimer_Expires event (Event
9], the local system: 9), the local system:
- drops the TCP connection, - drops the TCP connection,
- restarts the Connect Retry timer, - restarts the ConnectRetryTimer,
- stops the Open Delay timer and resets the timer to zero, - stops the DelayOpenTimer and resets the timer to zero,
- initiates a TCP connection to the other BGP peer, - initiates a TCP connection to the other BGP peer,
- continues to listen for a connection that may be - continues to listen for a connection that may be
initiated by the remote BGP peer, and initiated by the remote BGP peer, and
- stays in Connect state. - stays in Connect state.
If the Open Delay timer expires [Event12] in the connect If the DelayOpenTimer_Expires event (Event12) occurs in the
state, the local system: Connect state, the local system:
- sends an OPEN message to its peer, - sends an OPEN message to its peer,
- sets the hold timer to a large value, and - sets the HoldTimer to a large value, and
- changes its state to OpenSent. - changes its state to OpenSent.
If the BGP port receives a valid TCP connection indication If the BGP FSM receives a TcpConnection_valid event
[Event 14], the TCP connection is processed and (Event 14), the TCP connection is processed, and
the connection remains in the Connect state. the connection remains in the Connect state.
If the TCP connection receives an invalid indication [Event 15]: If the BGP FSM receives a Tcp_CR_Invalid event (Event 15),
the local system rejects the TCP connection and the connection the local system rejects the TCP connection, and the connection
remains in the Connect state. remains in the Connect state.
If the TCP connection succeeds [Event 16 or Event 17], If the TCP connection succeeds (Event 16 or
the local system checks the Delay Open flag prior to Event 17), the local system checks the DelayOpen attribute prior
processing. If the Delay Open flag is set, the local system: to processing. If the DelayOpen attribute is set to TRUE,
- sets the Connect Retry timer to zero, the local system:
- set the Open Delay timer to the initial value, and - stops the ConnectRetryTimer (if running) and sets the
ConnectRetryTimer to zero,
- sets the DelayOpenTimer to the initial value, and
- stays in the Connect state. - stays in the Connect state.
If the Delay Open flag is not set, the local system: If the DelayOpen attribute is not set to TRUE, the local system:
- sets the Connect Retry timer to zero, - stops the ConnectRetryTimer (if running) and sets the
ConnectRetryTimer to zero,
- completes BGP initialization - completes BGP initialization
- sends an OPEN message to its peer, - sends an OPEN message to its peer,
- sets hold timer to a large value, and - sets HoldTimer to a large value, and
- changes its state to OpenSent. - changes its state to OpenSent.
A hold timer value of 4 minutes is suggested. A HoldTimer value of 4 minutes is suggested.
If the TCP connection fails [Event18], the local system checks If the TCP connection fails (Event18),
the Open Delay Timer. If the Open Delay timer is running, the local system checks the DelayOpenTimer. If the
the local system: DelayOpenTimer is running, the local system:
- restarts the connect retry time with initial value, - restarts the ConnectRetryTimer with initial value,
- stops the Open Delay timer and resets value to zero, - stops the DelayOpenTimer and resets value to zero,
- continues to listen for a connection that may be - continues to listen for a connection that may be
initiated by the remote BGP peer, and initiated by the remote BGP peer, and
- changes its state to Active. - changes its state to Active.
If the open Delay timer is not running, the local system:
- sets the Connect Retry timer to zero, If the DelayOpenTimer is not running, the local system:
- stops the ConnectRetryTimer to zero,
- drops the TCP connection, - drops the TCP connection,
- releases all BGP resources, and - releases all BGP resources, and
- changes its state to Idle. - changes its state to Idle.
If an OPEN message is received with the Open Delay timer is If an OPEN message is received while the DelayOpenTimer is
running [Event 20], the local system: running (Event 20), the local system:
- sets the Connect Retry timer to zero,
- stops the ConnectRetryTimer (if running) and
sets the ConnectRetryTimer to zero,
- completes the BGP initialization, - completes the BGP initialization,
- stops and clears the Open Delay timer (sets the value to zero), - stops and clears the DelayOpenTimer
(sets the value to zero),
- sends an OPEN message, - sends an OPEN message,
- sends a KEEPALIVE message, - sends a KEEPALIVE message,
- If the hold timer value is non-zero, - if the HoldTimer initial value is non-zero,
- start the keepalive timer to inital value, - starts the keepaliveTimer with the initial value and
- reset the hold timer to the negotiated value, - resets the hold timer to the negotiated value,
else if hold timer value is zero, else if HoldTimer Initial value is zero,
- reset the keepalive timer, and - resets the KeepaliveTimer and
- reset the hold timer value to zero - resets the HoldTimer value to zero,
- and changes its state to OpenConfirm. - and changes its state to OpenConfirm.
If the value of the autonomous system field is the same as the local If the value of the autonomous system field is the same as the local
Autonomous System number, set the connection status to an internal Autonomous System number, set the connection status to an internal
connection; otherwise it is "external". connection; otherwise it is "external".
If BGP message header checking detects an error [Event 21] or If BGP message header checking detects an error (Event 21) or
OPEN message checking detects an error [Event 22] (see section OPEN message checking detects an error (Event 22) (see section
6.2), the local system: 6.2), the local system:
- (optionally) If the Send Notification without Open flag is set, - (optionally) If the SendNOTIFICATIONwithoutOPEN attribute
then the local system first sends a NOTIFICATION message is set to TRUE, then the local system first sends
with the appropriate error code, and then a NOTIFICATION message with the appropriate error
code, and then
- sets the Connect Retry timer to zero, - stops the ConnectRetryTimer (if running)
and sets the ConnectRetryTimer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) by 1, - increments the ConnectRetryCounter by 1,
- optionally performs peer oscillation damping, - (optionally) performs peer oscillation damping
- and changes its state to Idle. if the DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle.
If a NOTIFICATION message is received with a version If a NOTIFICATION message is received with a version
error[Event24], the local system checks the Open Delay timer. error(Event24), the local system checks the DelayOpenTimer.
If the DelayOpenTimer is running, the local system:
If the Open Delay timer is running, the local system: - stops the ConnectRetryTimer (if running)
- sets the Connect Retry timer to zero, and sets the ConnectRetryTimer to zero,
- stops and reset the Open Delay timer (sets to zero), - stops and resets the DelayOpenTimer (sets to zero),
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, and - drops the TCP connection, and
- changes its state to Idle. - changes its state to Idle.
If the Open Delay timer is not running, the local system:
- sets the Connect Retry timer to zero, If the DelayOpenTimer is not running, the local system:
- stops the ConnectRetryTimer and sets the
ConnectRetryTimer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) by 1, - increments the ConnectRetryCounter by 1,
- optionally performs peer oscillation damping, and - performs peer oscillation damping if the
DampPeerOscillations attribute is set to True, and
- changes its state to Idle. - changes its state to Idle.
In response to any other events [Events 8,10-11,13,19,23, In response to any other events (Events 8,10-11,13,19,23,
25-28] the local system: 25-28) the local system:
- if the Connect Retry timer is running, - if the ConnectRetryTimer is running,
stop and reset the Connect Retry timer (sets to zero), stops and resets the ConnectRetrytimer (sets to zero),
- if the Open Delay timer is running, - if the DelayOpenTimer is running,
stop and reset the Open Delay timer (sets to zero), stops and resets the DelayOpenTimer (sets to zero),
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) by 1, - increments the ConnectRetryCounter by 1,
- optionally performs peer oscillation damping, and - performs peer oscillation damping if the
DampPeerOscillations attribute is set to True, and
- changes its state to Idle. - changes its state to Idle.
Active State: Active State:
In this state BGP is trying to acquire a peer by listening In this state BGP FSM is trying to acquire a peer by listening
for and accepting a TCP connection. for and accepting a TCP connection.
The start events [Event1, 3-7] are ignored in the Active The start events (Event1, 3-7) are ignored in the Active
state. state.
In response to a manual stop event[Event2], the local system: In response to a ManualStop event (Event 2), the local system:
- If the Open Delay timer is running and the - If the DelayOpenTimer is running and the
Send NOTIFICATION without Open flag is set, SendNOTIFICATIONwithoutOPEN session attribute is set,
the local system Sends a NOTIFICATION with a Cease, the local system sends a NOTIFICATION with a Cease,
- releases all BGP resources including - releases all BGP resources including
- stopping the Open delay timer stopping the DelayOpenTimer
- drops the TCP connection, - drops the TCP connection,
- sets ConnectRetryCnt (connect retry count) to zero - sets ConnectRetryCounter to zero,
- sets the Connect Retry timer to zero, and - stops the ConnectRetryTimer and sets the
ConnectRetryTimer to zero, and
- changes its state to Idle. - changes its state to Idle.
In response the ConnectRetry timer expires event[Event9], In response to a ConnectRetryTimer expires event (Event 9),
the local system: the local system:
- restarts the Connect Retry timer (with initial value), - restarts the ConnectRetryTimer (with initial value),
- initiates a TCP connection to the other BGP peer, - initiates a TCP connection to the other BGP peer,
- Continues to listen for TCP connection that may be - continues to listen for TCP connection that may be
initiated by remote BGP peer, and initiated by remote BGP peer, and
- changes its state to Connect. - changes its state to Connect.
If the local system has the Open Delay timer expired If the local system receives an DelayOpenTimer_Expired event
[Event12], the local system: (Event 12), the local system:
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- stops and clears the Open Delay timer (set to zero), - stops and clears the DelayOpenTimer (set to zero),
- completes the BGP initialization, - completes the BGP initialization,
- sends the OPEN message to it's remote peer, - sends the OPEN message to its remote peer,
- sets its hold timer to a large value, and - sets its hold timer to a large value, and
- changes its state to OpenSent. - changes its state to OpenSent.
A hold timer value of 4 minutes is also suggested for this A HoldTimer value of 4 minutes is also suggested for this
state transition. state transition.
If the local system receives a valid TCP indication If the local system receives a TcpConnection_Valid event
[Event 14], the local system processes the TCP connection (Event 14), the local system processes the TCP connection
flags, and stays in Active state. flags and stays in Active state.
If the local system receives an invalid TCP indication [Event 15]: If the local system receives an Tcp_CR_Invalid event (Event 15):
the local system rejects the TCP connection, and stays in the local system rejects the TCP connection and stays in
the Active State. the Active State.
In response to a TCP connection succeeds [Event 16 or Event 17], the In response to a TCP connection succeeding (Event 16 or Event 17), the
local system checks the "Delay Open Flag" prior to local system checks the DelayOpen optional attribute prior to
processing. If the Delay Open flag is set, the local system processing.
o sets the Connect Retry timer to zero, If the DelayOpen attribute is set to TRUE, the local
o sets the Open Delay timer to the initial value, and system:
o stays in the Active state. - stops the ConnectRetryTimer and sets the
ConnectRetryTimer to zero,
- sets the DelayOpenTimer to the initial value
(DelayOpenTime), and
- stays in the Active state.
If the DelayOpen attribute is set to FALSE, the local
system:
- sets the ConnectRetryTimer to zero,
- completes the BGP initialization,
- sends the OPEN message to its peer,
- sets its HoldTimer to a large value, and
- changes its state to OpenSent.
-If the Delay Open flag is not set, the local system A HoldTimer value of 4 minutes is suggested as a "large value" for
o sets the Connect Retry timer to zero, the HoldTimer.
o completes the BGP initialization,
o sends the OPEN message to it's peer,
o sets its hold timer to a large value, and
o changes its state to OpenSent.
A hold timer value of 4 minutes is suggested as a "large value" for If the local system receives a TcpConnectionFails event (Event 18),
the hold timer. the local system:
If the local system receives a TCP connection fails event [Event 18], - restarts ConnectRetryTimer (with initial value),
the local system will: - stops and clears the DelayOpenTimer (sets the value to zero),
- restart the Connect Retry timer (with initial value), - releases all BGP resource,
- stops and clears the Open Delay Timer (sets the value to zero), - increments ConnectRetryCounter by 1,
- release all BGP resources - optionally performs peer oscillation damping if
- Acknowledge the drop of TCP connection if the DampPeerOscillations attribute is set to TRUE, and
TCP disconnect (send a FIN ACK),
- Increment ConnectRetryCnt (connect retry count) by 1, and
- optionally perform peer oscillation damping, and
- changes its state to Idle. - changes its state to Idle.
If an OPEN message is received with the Open Delay timer is If an OPEN message is received and the DelayOpenTimer is
running [Event 20], the local system running (Event 20), the local system:
- sets the Connect Retry timer to zero, - stops ConnectRetryTimer (if running) and sets
- stops and clears the Open Delay timer the ConnectRetryTimer to zero,
- stops and clears DelayOpenTimer (sets to zero),
- completes the BGP initialization, - completes the BGP initialization,
- sends an OPEN message, - sends an OPEN message,
- sends a KEEPALIVE message, and - sends a KEEPALIVE message,
- if the hold timer value is non-zero, - if the HoldTimer value is non-zero,
- starts the keepalive timer to initial value, - starts the KeepaliveTimer to initial value,
- resets the hold timer to the negotiated value, - resets the HoldTimer to the negotiated value,
else if the hold timer is zero else if the HoldTimer is zero
- resets the keepalive timer (set to zero), - resets the KeepaliveTimer (set to zero),
- resets the hold timer to zero, - resets the HoldTimer to zero, and
- and changes its state to OpenConfirm. - changes its state to OpenConfirm.
If the value of the autonomous system field is the same as the local If the value of the autonomous system field is the same as
Autonomous System number, set the connection status to an internal the local Autonomous System number, set the connection status
connection; otherwise it is "external". to an internal connection; otherwise it is external.
If BGP message header checking detects an error [Event 21] or OPEN If BGP message header checking detects an error (Event 21)
message checking detects an error [Event 22] (see section 6.2), the or OPEN message checking detects an error (Event 22) (see
local system: section 6.2), the local system:
- (optionally) sends NOTIFICATION message with the - (optionally) sends a NOTIFICATION message with the
appropriate error code, appropriate error code if the SendNOTIFICATIONwithoutOPEN
- sets the Connect Retry timer to zero, attribute is set to TRUE,
- sets the ConnectRetryTimer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) by 1, - increments the ConnectRetryCounter by 1,
- optionally performs peer oscillation damping, - (optionally) performs peer oscillation damping if the
- and changes its state to Idle. DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle.
If a NOTIFICATION message is received with a version If a NOTIFICATION message is received with a version
error[Event24], the local system checks the Open Delay timer. error (Event 24), the local system checks the DelayOpenTimer.
If the Open Delay timer is running, the local system: If the DelayOpenTimer is running, the local system:
- sets the Connect Retry timer to zero, - stops the ConnectRetryTimer (if running) and
- stops and reset the Open Delay timer (sets to zero, sets the ConnectRetryTimer to zero,
- stops and resets the DelayOpenTimer (sets to zero),
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, and - drops the TCP connection, and
- changes its state to Idle. - changes its state to Idle.
If the Open Delay timer is not running, the local system: If the DelayOpenTimer is not running, the local system:
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) by 1, - increments the ConnectRetryCounter by 1,
- optionally performs peer oscillation damping, and - (optionally) performs peer oscillation damping
if the DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
In response to any other event [Events 8,10-11,13,19,23,25-28], In response to any other event (Events 8,10-11,13,19,23,25-28),
the local system: the local system:
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) by one, - increments the ConnectRetryCounter by one,
- optionally performs peer oscillation damping, and - (optionally) performs peer oscillation damping if
the DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
OpenSent: OpenSent:
In this state BGP waits for an OPEN message from its peer. In this state BGP FSM waits for an OPEN message from its peer.
The Start events [Event1, 3-7] are ignored in the OpenSent The start events (Event1, 3-7) are ignored in the OpenSent
state. state.
If a manual stop event [Event 2] is issued in Open sent If a ManualStop event (Event 2) is issued in OpenSent
state, the local system: state, the local system:
- sends the NOTIFICATION with a cease, - sends the NOTIFICATION with a cease,
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- release all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- set ConnectRetryCnt (connect retry count) to zero, and - sets ConnectRetryCounter to zero, and
- changes its state to Idle. - changes its state to Idle.
If an automatic stop event [Event 8] is issued in OpenSent If an AutomaticStop event (Event 8) is issued in OpenSent
state, the local system: state, the local system:
- sends the NOTIFICATION with a cease, - sends the NOTIFICATION with a cease,
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- release all the BGP resources - release all the BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) by 1, - increments the ConnectRetryCounter by 1,
- optionally performs peer oscillation damping, and - (optionally) performs peer oscillation damping if the
DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
If the Hold Timer expires[Event 10], the local system: If the HoldTimer_Expires (Event 10), the local system:
- sends a NOTIFICATION message with error code Hold
- send a NOTIFICATION message with error code Hold
Timer Expired, Timer Expired,
- set the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) by 1, - increments the ConnectRetryCounter,
- optionally performs peer oscillation damping, and - (optionally) performs peer oscillation damping if the
DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
If a TCP indication is received for valid connection If a TcpConnection_Valid (Event 14) or Tcp_CR_Acked (Event 16)
[Event 14] or TCP request aknowledgement [Event 16] is received, or a TcpConnectConfirm event (Event 17) is
is received, or a TCP connect confirm [Event 17] is received, a second TCP connection may be in progress. This
received a second TCP session may be in progress. This second TCP connection is tracked per Connection Collision
second TCP session is tracked per the Connection Collision
processing (Section 6.8) until an OPEN message is received. processing (Section 6.8) until an OPEN message is received.
A TCP connection for an invalid port [Event 15] is ignored. A TCP Connection Request for an Invalid port
(Tcp_CR_Invalid (Event 15)) is ignored.
If a TCP connection fails event [Event18] indication is received If a TcpConnectionFails event (Event18) indication is received,
the local system: the local system:
- closes the BGP connection, - closes the BGP connection,
- restarts the Connect Retry timer, - restarts the ConnectRetryTimer,
- continues to listen for a connection that may be - continues to listen for a connection that may be
initiated by the remote BGP peer, and initiated by the remote BGP peer, and
- changes its state to Active. - changes its state to Active.
When an OPEN message is received, all fields are checked When an OPEN message is received, all fields are checked
for correctness. If there are no errors in the OPEN message for correctness. If there are no errors in the OPEN message
[Event 19] the local system: (Event 19), the local system:
- resets the Open Delay timer to zero, - resets the DelayOpenTimer to zero,
- sets the BGP Connect Retry timer to zero, - sets the BGP ConnectRetryTimer to zero,
- sends a KEEPALIVE message and - sends a KEEPALIVE message, and
- sets a KeepAlive timer (via the text below) - sets a KeepAliveTimer (via the text below)
- sets the hold timer according to the negotiated value - sets the HoldTimer according to the negotiated value
(see Section 4.2), and (see Section 4.2),
- changes its state to OpenConfirm. - changes its state to OpenConfirm.
If the negotiated hold time value is zero, then the Hold and If the negotiated hold time value is zero, then the HoldTimer and
KeepAlive timers are not started. If the value of the Autonomous KeepaliveTimer are not started. If the value of the Autonomous
System field is the same as the local Autonomous System number, System field is the same as the local Autonomous System number,
then the connection is an "internal" connection; otherwise, it then the connection is an "internal" connection; otherwise, it
is an "external" connection. (This will impact UPDATE processing is an "external" connection. (This will impact UPDATE processing
as described below.) as described below.)
If the BGP message header checking [Event21] or OPEN message If the BGP message header checking (Event 21) or OPEN message
check detects an error (see Section 6.2)[Event22], the local system: check detects an error (Event 22)(see Section 6.2), the local system:
- sends a NOTIFICATION message with appropriate error - sends a NOTIFICATION message with appropriate error
code, code,
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry cout) by 1, - increments the ConnectRetryCounter by 1,
- optionally performs peer oscillation damping, and - (optionally) performs peer oscillation damping if the
DampPeerOscillations attribute is TRUE, and
- changes its state to Idle. - changes its state to Idle.
Collision detection mechanisms (Section 6.8) need to be Collision detection mechanisms (Section 6.8) need to be
applied when a valid BGP OPEN message is received [Event 19 or applied when a valid BGP OPEN message is received (Event 19 or
Event 20]. Please refer to Section 6.8 for the details of Event 20). Please refer to Section 6.8 for the details of
the comparison. An administrative collision detect is when the comparison. A CollisionDetectDump event occurs when the
BGP implementation determines by means outside the scope of BGP implementation determines, by a means outside the scope of
this document that a connection collision has occurred. this document, that a connection collision has occurred.
If a connection in OpenSent is determined to be the If a connection in OpenSent is determined to be the
connection that must be closed, an open collision dump [Event 23] connection that must be closed, an OpenCollisionDump (Event 23)
is signaled to the state machine. If such an event is is signaled to the state machine. If such an event is
received in OpenSent, the local system: received in OpenSent state, the local system:
- sends a NOTIFICATION with a Cease - sends a NOTIFICATION with a Cease
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments ConnectRetryCnt (connect retry count) by 1, - increments ConnectRetryCounter by 1,
- optionally performs peer oscillation damping, and - (optionally) performs peer oscillation damping if the
DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
If a NOTIFICATION message is received with a version If a NOTIFICATION message is received with a version
error[Event24], the local system: error (Event24), the local system:
- sets the Connect Retry timer to zero - sets the ConnectRetryTimer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection, and
- changes its state to Idle. - changes its state to Idle.
In response to any other event [Events 9, 11-13,20,25-28], In response to any other event (Events 9, 11-13,20,25-28),
the local system: the local system:
- sends the NOTIFICATION with the Error Code Finite - sends the NOTIFICATION with the Error Code Finite
state machine error, state machine error,
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- releases all BGP resources - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) by 1, - increments the ConnectRetryCounter by 1,
- optionally performs peer oscillation damping, and - (optionally) performs peer oscillation damping if the
DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
OpenConfirm State: OpenConfirm State:
In this state BGP waits for a KEEPALIVE or NOTIFICATION In this state BGP waits for a KEEPALIVE or NOTIFICATION
message. message.
Any start event [Event1, 3-7] is ignored in the OpenConfirm Any start event (Event1, 3-7) is ignored in the OpenConfirm
state. state.
In response to a manual stop event[Event 2] initiated by In response to a ManualStop event (Event 2) initiated by
the operator, the local system: the operator, the local system:
- sends the NOTIFICATION message with Cease, - sends the NOTIFICATION message with Cease,
- releases all BGP resources, - releases all BGP resources,
- drop the TCP connection, - drops the TCP connection,
- sets the ConnectRetryCnt (connect retry count) to zero - sets the ConnectRetryCounter to zero,
- sets the Connect Retry timer to zero, and - sets the ConnectRetryTimer to zero, and
- changes its state to Idle. - changes its state to Idle.
In response to the Automatic stop event initiated by the In response to the AutomaticStop event initiated by the
system[Event 8], the local system: system (Event 8), the local system:
- sends the NOTIFICATION message with Cease, - sends the NOTIFICATION message with Cease,
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- release all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) - increments the ConnectRetryCounter by 1,
by 1, - (optionally) performs peer oscillation damping
- optionally performs peer oscillation damping, and if the DampPeerOscillations attribute is set to TRUE,
and
- changes its state to Idle. - changes its state to Idle.
If the Hold Timer expires before a KEEPALIVE message is If the HoldTime_Expires event (Event 10) occurs before a KEEPALIVE
received [Event 10], the local system: message is received, the local system:
- send the NOTIFICATION message with the error code - sends the NOTIFICATION message with the error code,
set to Hold Time Expired, - sets the ConnectRetryTimer to zero,
- sets the Connect Retry timer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) by 1, - increments the ConnectRetryCounter by 1,
- optionally performs peer oscillation damping, and - (optionally) performs peer oscillation damping if
the DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
If the local system receives a KEEPALIVE timer expires If the local system receives a KEEPALIVETimer_Expires
event [Event 11], the system: event (Event 11), the system:
- sends a KEEPALIVE message, - sends a KEEPALIVE message,
- restarts the Keepalive timer, and - restarts the KeepaliveTimer, and
- remains in OpenConfirmed state. - remains in OpenConfirmed state.
In the event of TCP connection valid indication [Event 14], or TCP In the event of TcpConnection_Valid event (Event 14), or TCP
connection succeeding [Event 16 or Event 17] while in OpenConfirm, connection succeeding (Event 16 or Event 17) while in OpenConfirm,
the local system needs to track the 2nd connection. the local system needs to track the second connection.
If a TCP connection is attempted to an invalid port [Event If a TCP connection is attempted to an invalid port (Event
15], the local system will ignore the second connection 15), the local system will ignore the second connection
attempt. attempt.
If the local system receives a TCP connection fails event If the local system receives a TcpConnectionFails event
[Event 18] from the underlying TCP, or a NOTIFICATION (Event 18) from the underlying TCP or a NOTIFICATION
message [Event 25] the local system: message (Event 25), the local system:
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) - increments the ConnectRetryCounter by 1,
by 1, - (optionally) performs peer oscillation damping if the
- optionally performs peer oscillation damping, and DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
If the local system receives a NOTIFICATION message [Event 24] If the local system receives a NOTIFICATION message with a
with a version error, the local system: version error (NotifMsgVerErr (Event 24)), the local system:
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, and - drops the TCP connection, and
- changes its state to Idle. - changes its state to Idle.
If the local system receives a valid OPEN message [Event 19], the If the local system receives a valid OPEN message
collision detect function is processed per Section 6.8. If this (BGPOpen (Event 19)), the collision detect function is
connection is to be dropped due to connection collision, the processed per Section 6.8. If this connection is to be
local system: dropped due to connection collision, the local system:
- sends a NOTIFICATION with a Cease - sends a NOTIFICATION with a Cease,
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection (send TCP FIN), - drops the TCP connection (send TCP FIN),
- increments the ConnectRetryCnt by 1 (connect retry count), - increments the ConnectRetryCounter by 1,
- optionally performs peer oscillation damping, and - (optionally) performs peer oscillation damping if the
DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
If an OPEN message is received, all fields are check for If an OPEN message is received, all fields are checked for
correctness. If the BGP message header checking [Event21] correctness. If the BGP message header checking
or OPEN message check detects an error (see Section (BGPHeaderErr (Event21)) or OPEN message check detects
6.2)[Event22], the local system: an error (see Section 6.2) (BGPOpenMsgErr(Event22)), the
local system:
- sends a NOTIFICATION message with appropriate error - sends a NOTIFICATION message with appropriate error
code, code,
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) by 1, - increments the ConnectRetryCounter by 1,
- optionally performs peer oscillation damping, and - (optionally) performs peer oscillation damping if the
DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
If during the processing of another OPEN message, the BGP If during the processing of another OPEN message, the BGP
implementation determines by means outside the scope of implementation determines by a means outside the scope of
this document that a connection collision has occurred and this document that a connection collision has occurred and
this connection is to be closed, the local system will this connection is to be closed, the local system will
issue a open collision dump [Event 23]. When the local issue an OpenCollisionDump event (Event 23). When the local
system receives a open collision dump event [Event 23], the system receives an OpenCollisionDump event (Event 23), the
local system: local system:
- sends a NOTIFICATION with a Cease - sends a NOTIFICATION with a Cease
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- releases all BGP resources - releases all BGP resources
- drops all TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) by 1, - increments the ConnectRetryCounter by 1,
- optionally performs peer oscillation damping, and - (optionally) performs peer oscillation damping if the
DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
If the local system receives a KEEPALIVE message[Event 26], If the local system receives a KEEPALIVE message
- restarts the Hold timer, and (KeepAliveMsg (Event 26)), the local system:
- restarts the HoldTimer and
- changes its state to Established. - changes its state to Established.
In response to any other event [Events 9, 12-13, 20, 27-28], In response to any other event (Events 9, 12-13, 20, 27-28),
the local system: the local system:
- sends a NOTIFICATION with a code of Finite State - sends a NOTIFICATION with a code of Finite State
Machine Error, Machine Error,
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retrycount) by 1, - increments the ConnectRetryCounter by 1,
- optionally performs peer oscillation damping, and - (optionally) performs peer oscillation damping if the
DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
Established State: Established State:
In the Established state BGP can exchange UPDATE, In the Established state, the BGP FSM can exchange UPDATE,
NOTFICATION, and KEEPALIVE messages with its peer. NOTFICATION, and KEEPALIVE messages with its peer.
Any start event (Event 1, 3-7) is ignored in the Any Start event (Event 1, 3-7) is ignored in the
Established state. Established state.
In response to a manual stop event (initiated by an In response to a ManualStop event (initiated by an
operator)[Event2], the local sytem: operator)(Event2), the local system:
- sends the NOTIFICATION message with Cease, - sends the NOTIFICATION message with Cease,
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- delete all routes associated with this connection, - deletes all routes associated with this connection,
- release BGP resources, - releases BGP resources,
- drops TCP connection, - drops the TCP connection,
- sets ConnectRetryCnt (connect retry count) - sets ConnectRetryCounter to zero, and
to zero (0), and
- changes its state to Idle. - changes its state to Idle.
In response to an automatic stop event initiated by the In response to an AutomaticStop event (Event8), the local system:
system (automatic) [Event8], the local system:
- sends a NOTIFICATION with Cease, - sends a NOTIFICATION with Cease,
- sets the Connect Retry timer to zero - sets the ConnectRetryTimer to zero
- deletes all routes associated with this connection, - deletes all routes associated with this connection,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) - increments the ConnectRetryCounter by 1,
by 1, - (optionally) performs peer oscillation damping if the
- optionally performs peer oscillation damping, and DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
An example automatic stop event is exceeding the number of One reason for an AutomaticStop event is: A BGP receives
prefixes for a given peer and the local system UPDATE messages with number of prefixes for a given
automatically disconnecting the peer. peer so that the total prefixes received exceeds the
maximum number of prefixes configured. The local system
automatically disconnects the peer.
If the Hold timer expires [Event10], the local system: If the HoldTimer_Expires event occurs (Event10), the
local system:
- sends a NOTIFICATION message with Error Code Hold - sends a NOTIFICATION message with Error Code Hold
Timer Expired, Timer Expired,
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) - increments the ConnectRetryCounter by 1,
by 1, - (optionally) performs peer oscillation damping if the
- optionally performs peer oscillation damping, and DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
If the KeepAlive timer expires [Event11], the local system If the KeepaliveTimer_Expires event occurs (Event11),
sends a KEEPALIVE message, it restarts its KeepAlive timer, the local system:
unless the negotiated Hold Time value is zero. - sends a KEEPALIVE message, and
- restarts its KeepAliveTimer unless the negotiated
HoldTime value is zero.
Each time the local system sends a KEEPALIVE or UPDATE Each time the local system sends a KEEPALIVE or UPDATE
message, it restarts its KeepAlive timer, unless the message, it restarts its KeepAliveTimer, unless the
negotiated Hold Time value is zero. negotiated Hold Time value is zero.
A TCP connection indication [Event 14] received A TcpConnection_valid (Event 14) received for a
for a valid port will cause the 2nd connection to be valid port will cause the second connection to be
tracked. tracked.
A TCP connection indications for invalid port [Event 15], An invalid TCP connection (Tcp_CR_Invalid Event
will be ignored. (Event 15)), will be ignored.
In response to a TCP connection succeeds [Event 16 In response to an indication that the TCP connection
or Event 17], the 2nd connection SHALL be tracked until is successfully established (Event 16
or Event 17), the second connection SHALL be tracked until
it sends an OPEN message. it sends an OPEN message.
If a valid OPEN message [Event 19] is received, it will be If a valid OPEN message (BGPOpen (Event 19)) is received,
checked to see if it collides (Section 6.8) with any other and if the CollisionDetectEstablishedState optional
session. If the BGP implementation determines that this attribute is TRUE, the OPEN message will be checked
connection needs to be terminated, it will process an open to see if it collides (Section 6.8) with any other connection.
collision dump event[Event 23]. If this session needs to be If the BGP implementation determines that this connection
terminated, the connection will be terminated by: needs to be terminated, it will process an OpenCollisionDump
event (Event 23). If this connection needs to be
terminated, the local system:
- sends a NOTIFICATION with a Cease, - sends a NOTIFICATION with a Cease,
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- deletes all routes associated with this connection, - deletes all routes associated with this connection,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments ConnectRetryCnt (connect retry count) - increments ConnectRetryCounter by 1,
by 1, - (optionally) performs peer oscillation damping if the
- optionally performs peer oscillation damping, and DampPeerOscillations is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
If the local system receives a NOTIFICATION message If the local system receives a NOTIFICATION message
[Event24 or Event 25] or a TCP connections fails [Event18] (Event24 or Event 25) or a TcpConnectionsFails (Event18)
from the underlying TCP, it: from the underlying TCP, it:
- sets the Connect Retry timer to zero, - sets the ConnectRetryTimer to zero,
- deletes all routes associated with this connection, - deletes all routes associated with this connection,
- releases all the BGP resources, - releases all the BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) - increments the ConnectRetryCounter by 1,
by 1, and
- changes its state to Idle. - changes its state to Idle.
If the local system receives a KEEPALIVE message If the local system receives a KEEPALIVE message
[Event 26], the local system will: (Event 26), the local system:
- restarts its Hold Timer, if the negotiated Hold Time - restarts its Hold Timer, if the negotiated Hold Time
value is non-zero, and value is non-zero, and
- remain in the Established state. - remains in the Established state.
If the local system receives an UPDATE message [Event27], If the local system receives an UPDATE message (Event27),
the local system will: the local system:
- process the update packet - processes the update packet,
- restarts its Hold timer, if the negotiated Hold Time - restarts its HoldTimer if the negotiated HoldTime
value is non-zero, and value is non-zero, and
- remain in the Established state. - remains in the Established state.
If the local system receives an UPDATE message, and the If the local system receives an UPDATE message, and the
UPDATE message error handling procedure (see Section 6.3) UPDATE message error handling procedure (see Section 6.3)
detects an error [Event28], the local system: detects an error (Event28), the local system:
- sends a NOTIFICATION message with Update error, - sends a NOTIFICATION message with Update error,
- sets the Connect Retry timer to zero, - sets the Connect Retry timer to zero,
- delets all routes associated with this connection, - deletes all routes associated with this connection,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) - increments the ConnectRetryCounter by 1,
by 1, - (optionally) performs peer oscillation damping if the
- optionally performs peer oscillation damping, and DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
In response to any other event [Events 9, 12-13, 20-22] the In response to any other event (Events 9, 12-13, 20-22) the
local system: local system:
- sends a NOTIFICATION message with Error Code Finite - sends a NOTIFICATION message with Error Code Finite
State Machine Error, State Machine Error,
- deletes all routes associated with this connection, - deletes all routes associated with this connection,
- sets the Connect Retry timer to zero - sets the Connect Retry timer to zero,
- releases all BGP resources, - releases all BGP resources,
- drops the TCP connection, - drops the TCP connection,
- increments the ConnectRetryCnt (connect retry count) - increments the ConnectRetryCounter by 1,
by 1, - (optionally) performs peer oscillation damping if the
- optionally performs peer oscillation damping, and DampPeerOscillations attribute is set to TRUE, and
- changes its state to Idle. - changes its state to Idle.
9. UPDATE Message Handling 9. UPDATE Message Handling
An UPDATE message may be received only in the Established state. An UPDATE message may be received only in the Established state.
When an UPDATE message is received, each field is checked for valid- Receiving an UPDATE message in any other state is an error. When an
ity as specified in Section 6.3. UPDATE message is received, each field is checked for validity as
specified in Section 6.3.
If an optional non-transitive attribute is unrecognized, it is qui- If an optional non-transitive attribute is unrecognized, it is qui-
etly ignored. If an optional transitive attribute is unrecognized, etly ignored. If an optional transitive attribute is unrecognized,
the Partial bit (the third high-order bit) in the attribute flags the Partial bit (the third high-order bit) in the attribute flags
octet is set to 1, and the attribute is retained for propagation to octet is set to 1, and the attribute is retained for propagation to
other BGP speakers. other BGP speakers.
If an optional attribute is recognized, and has a valid value, then, If an optional attribute is recognized, and has a valid value, then,
depending on the type of the optional attribute, it is processed depending on the type of the optional attribute, it is processed
locally, retained, and updated, if necessary, for possible propaga- locally, retained, and updated, if necessary, for possible propaga-
skipping to change at page 63, line 33 skipping to change at page 73, line 11
Once the BGP speaker updates the Adj-RIB-In, the speaker SHALL run Once the BGP speaker updates the Adj-RIB-In, the speaker SHALL run
its Decision Process. its Decision Process.
9.1 Decision Process 9.1 Decision Process
The Decision Process selects routes for subsequent advertisement by The Decision Process selects routes for subsequent advertisement by
applying the policies in the local Policy Information Base (PIB) to applying the policies in the local Policy Information Base (PIB) to
the routes stored in its Adj-RIBs-In. The output of the Decision Pro- the routes stored in its Adj-RIBs-In. The output of the Decision Pro-
cess is the set of routes that will be advertised to peers; the cess is the set of routes that will be advertised to peers; the
selected routes will be stored in the local speaker's Adj-RIB-Out selected routes will be stored in the local speaker's Adj-RIBs-Out
according to policy. according to policy.
The BGP Decision Process described here is conceptual, and does not
have to be implemented precisely as described here, as long as the
implementations support the described functionality and their exter-
nally visible behavior is the same.
The selection process is formalized by defining a function that takes The selection process is formalized by defining a function that takes
the attribute of a given route as an argument and returns either (a) the attribute of a given route as an argument and returns either (a)
a non-negative integer denoting the degree of preference for the a non-negative integer denoting the degree of preference for the
route, or (b) a value denoting that this route is ineligible to be route, or (b) a value denoting that this route is ineligible to be
installed in LocRib and will be excluded from the next phase of route installed in Loc-RIB and will be excluded from the next phase of
selection. route selection.
The function that calculates the degree of preference for a given The function that calculates the degree of preference for a given
route SHALL NOT use as its inputs any of the following: the existence route SHALL NOT use as its inputs any of the following: the existence
of other routes, the non-existence of other routes, or the path of other routes, the non-existence of other routes, or the path
attributes of other routes. Route selection then consists of individ- attributes of other routes. Route selection then consists of individ-
ual application of the degree of preference function to each feasible ual application of the degree of preference function to each feasible
route, followed by the choice of the one with the highest degree of route, followed by the choice of the one with the highest degree of
preference. preference.
The Decision Process operates on routes contained in the Adj-RIB-In, The Decision Process operates on routes contained in the Adj-RIBs-In,
and is responsible for: and is responsible for:
- selection of routes to be used locally by the speaker - selection of routes to be used locally by the speaker
- selection of routes to be advertised to other BGP peers - selection of routes to be advertised to other BGP peers
- route aggregation and route information reduction - route aggregation and route information reduction
The Decision Process takes place in three distinct phases, each trig- The Decision Process takes place in three distinct phases, each trig-
gered by a different event: gered by a different event:
skipping to change at page 65, line 11 skipping to change at page 74, line 39
the LOCAL_PREF attribute is taken as the degree of preference, or the LOCAL_PREF attribute is taken as the degree of preference, or
the local system computes the degree of preference of the route the local system computes the degree of preference of the route
based on preconfigured policy information. Note that the latter based on preconfigured policy information. Note that the latter
(computing the degree of preference based on preconfigured policy (computing the degree of preference based on preconfigured policy
information) may result in formation of persistent routing loops. information) may result in formation of persistent routing loops.
If the route is learned from an external peer, then the local BGP If the route is learned from an external peer, then the local BGP
speaker computes the degree of preference based on preconfigured speaker computes the degree of preference based on preconfigured
policy information. If the return value indicates that the route policy information. If the return value indicates that the route
is ineligible, the route MAY NOT serve as an input to the next is ineligible, the route MAY NOT serve as an input to the next
phase of route selection; otherwise the return value is used as phase of route selection; otherwise the return value MUST be used
the LOCAL_PREF value in any IBGP readvertisement. as the LOCAL_PREF value in any IBGP readvertisement.
The exact nature of this policy information and the computation The exact nature of this policy information and the computation
involved is a local matter. involved is a local matter.
9.1.2 Phase 2: Route Selection 9.1.2 Phase 2: Route Selection
The Phase 2 decision function is invoked on completion of Phase 1. The Phase 2 decision function is invoked on completion of Phase 1.
The Phase 2 function is a separate process which completes when it The Phase 2 function is a separate process which completes when it
has no further work to do. The Phase 2 process considers all routes has no further work to do. The Phase 2 process considers all routes
that are eligible in the Adj-RIBs-In. that are eligible in the Adj-RIBs-In.
The Phase 2 decision function is blocked from running while the Phase The Phase 2 decision function is blocked from running while the Phase
3 decision function is in process. The Phase 2 function locks all 3 decision function is in process. The Phase 2 function locks all
Adj-RIBs-In prior to commencing its function, and unlocks them on Adj-RIBs-In prior to commencing its function, and unlocks them on
completion. completion.
If the NEXT_HOP attribute of a BGP route depicts an address that is If the NEXT_HOP attribute of a BGP route depicts an address that is
skipping to change at page 67, line 30 skipping to change at page 77, line 12
ing the BGP route's NEXT_HOP. Mutually recursive routes (routes ing the BGP route's NEXT_HOP. Mutually recursive routes (routes
resolving each other or themselves), also fail the resolvability resolving each other or themselves), also fail the resolvability
check. check.
It is also important that implementations do not consider feasible It is also important that implementations do not consider feasible
routes that would become unresolvable if they were installed in the routes that would become unresolvable if they were installed in the
Routing Table even if their NEXT_HOPs are resolvable using the cur- Routing Table even if their NEXT_HOPs are resolvable using the cur-
rent contents of the Routing Table (an example of such routes would rent contents of the Routing Table (an example of such routes would
be mutually recursive routes). This check ensures that a BGP speaker be mutually recursive routes). This check ensures that a BGP speaker
does not install in the Routing Table routes that will be removed and does not install in the Routing Table routes that will be removed and
not used by the speaker. Therefore, in addition to local Routing not used by the speaker. Therefore, in addition to local Routing Ta-
Table stability, this check also improves behavior of the protocol in ble stability, this check also improves behavior of the protocol in
the network. the network.
Whenever a BGP speaker identifies a route that fails the resolvabil- Whenever a BGP speaker identifies a route that fails the resolvabil-
ity check because of mutual recursion, an error message SHOULD be ity check because of mutual recursion, an error message SHOULD be
logged. logged.
9.1.2.2 Breaking Ties (Phase 2) 9.1.2.2 Breaking Ties (Phase 2)
In its Adj-RIBs-In a BGP speaker may have several routes to the same In its Adj-RIBs-In a BGP speaker may have several routes to the same
destination that have the same degree of preference. The local destination that have the same degree of preference. The local
skipping to change at page 69, line 17 skipping to change at page 78, line 47
MULTI_EXIT_DISC attribute MAY still be performed. If an implemen- MULTI_EXIT_DISC attribute MAY still be performed. If an implemen-
tation chooses to remove MULTI_EXIT_DISC, then the optional com- tation chooses to remove MULTI_EXIT_DISC, then the optional com-
parison on MULTI_EXIT_DISC if performed at all MUST be performed parison on MULTI_EXIT_DISC if performed at all MUST be performed
only among EBGP learned routes. The best EBGP learned route may only among EBGP learned routes. The best EBGP learned route may
then be compared with IBGP learned routes after the removal of the then be compared with IBGP learned routes after the removal of the
MULTI_EXIT_DISC attribute. If MULTI_EXIT_DISC is removed from a MULTI_EXIT_DISC attribute. If MULTI_EXIT_DISC is removed from a
subset of EBGP learned routes and the selected "best" EBGP learned subset of EBGP learned routes and the selected "best" EBGP learned
route will not have MULTI_EXIT_DISC removed, then the route will not have MULTI_EXIT_DISC removed, then the
MULTI_EXIT_DISC must be used in the comparison with IBGP learned MULTI_EXIT_DISC must be used in the comparison with IBGP learned
routes. For IBGP learned routes the MULTI_EXIT_DISC MUST be used routes. For IBGP learned routes the MULTI_EXIT_DISC MUST be used
in route comparisons which reach this step in the decision pro- in route comparisons which reach this step in the Decision Pro-
cess. Including the MULTI_EXIT_DISC of an EBGP learned route in cess. Including the MULTI_EXIT_DISC of an EBGP learned route in
the comparison with an IBGP learned route, then removing the the comparison with an IBGP learned route, then removing the
MULTI_EXIT_DISC atribute and advertising the route has been proven MULTI_EXIT_DISC attribute and advertising the route has been
to cause route loops. proven to cause route loops.
d) If at least one of the candidate routes was received via EBGP, d) If at least one of the candidate routes was received via EBGP,
remove from consideration all routes which were received via IBGP. remove from consideration all routes which were received via IBGP.
e) Remove from consideration any routes with less-preferred inte- e) Remove from consideration any routes with less-preferred inte-
rior cost. The interior cost of a route is determined by calcu- rior cost. The interior cost of a route is determined by calcu-
lating the metric to the NEXT_HOP for the route using the Routing lating the metric to the NEXT_HOP for the route using the Routing
Table. If the NEXT_HOP hop for a route is reachable, but no cost Table. If the NEXT_HOP hop for a route is reachable, but no cost
can be determined, then this step should be skipped (equivalently, can be determined, then this step should be skipped (equivalently,
consider all routes to have equal costs). consider all routes to have equal costs).
skipping to change at page 71, line 18 skipping to change at page 80, line 44
The precedence relationship effectively decomposes less specific The precedence relationship effectively decomposes less specific
routes into two parts: routes into two parts:
- a set of destinations described only by the less specific route, - a set of destinations described only by the less specific route,
and and
- a set of destinations described by the overlap of the less spe- - a set of destinations described by the overlap of the less spe-
cific and the more specific routes cific and the more specific routes
When overlapping routes are present in the same Adj-RIB-In, the more
specific route takes precedence, in order from more specific to least
specific.
The set of destinations described by the overlap represents a portion The set of destinations described by the overlap represents a portion
of the less specific route that is feasible, but is not currently in of the less specific route that is feasible, but is not currently in
use. If a more specific route is later withdrawn, the set of desti- use. If a more specific route is later withdrawn, the set of desti-
nations described by the overlap will still be reachable using the nations described by the overlap will still be reachable using the
less specific route. less specific route.
If a BGP speaker receives overlapping routes, the Decision Process If a BGP speaker receives overlapping routes, the Decision Process
MUST consider both routes based on the configured acceptance policy. MUST consider both routes based on the configured acceptance policy.
If both a less and a more specific route are accepted, then the Deci- If both a less and a more specific route are accepted, then the Deci-
sion Process MUST either install both the less and the more specific sion Process MUST either install in Loc-RIB both the less and the
routes or it MUST aggregate the two routes and install the aggregated more specific routes or it MUST aggregate the two routes and install
route, provided that both routes have the same value of the NEXT_HOP in Loc-RIB the aggregated route, provided that both routes have the
attribute. same value of the NEXT_HOP attribute.
If a BGP speaker chooses to aggregate, then it SHOULD either include If a BGP speaker chooses to aggregate, then it SHOULD either include
all AS used to form the aggreagate in an AS_SET or add the all AS used to form the aggregate in an AS_SET or add the
ATOMIC_AGGREGATE attribute to the route. This attribute is now pri- ATOMIC_AGGREGATE attribute to the route. This attribute is now pri-
marily informational. With the elimination of IP routing protocols marily informational. With the elimination of IP routing protocols
that do not support classless routing and the elimination of router that do not support classless routing and the elimination of router
and host implementations that do not support classless routing, there and host implementations that do not support classless routing, there
is no longer a need to deaggregate. Routes SHOULD NOT be de-aggre- is no longer a need to de-aggregate. Routes SHOULD NOT be de-aggre-
gated. A route that carries ATOMIC_AGGREGATE attribute in particular gated. A route that carries ATOMIC_AGGREGATE attribute in particular
MUST NOT be de-aggregated. That is, the NLRI of this route can not be MUST NOT be de-aggregated. That is, the NLRI of this route can not be
made more specific. Forwarding along such a route does not guarantee made more specific. Forwarding along such a route does not guarantee
that IP packets will actually traverse only ASs listed in the AS_PATH that IP packets will actually traverse only ASs listed in the AS_PATH
attribute of the route. attribute of the route.
9.2 Update-Send Process 9.2 Update-Send Process
The Update-Send process is responsible for advertising UPDATE mes- The Update-Send process is responsible for advertising UPDATE mes-
sages to all peers. For example, it distributes the routes chosen by sages to all peers. For example, it distributes the routes chosen by
the Decision Process to other BGP speakers which may be located in the Decision Process to other BGP speakers which may be located in
either the same autonomous system or a neighboring autonomous system. either the same autonomous system or a neighboring autonomous system.
When a BGP speaker receives an UPDATE message from an internal peer, When a BGP speaker receives an UPDATE message from an internal peer,
the receiving BGP speaker SHALL NOT re-distribute the routing infor- the receiving BGP speaker SHALL NOT re-distribute the routing infor-
mation contained in that UPDATE message to other internal peers, mation contained in that UPDATE message to other internal peers
unless the speaker acts as a BGP Route Reflector [RFC2796]. (unless the speaker acts as a BGP Route Reflector [RFC2796]).
As part of Phase 3 of the route selection process, the BGP speaker As part of Phase 3 of the route selection process, the BGP speaker
has updated its Adj-RIBs-Out. All newly installed routes and all has updated its Adj-RIBs-Out. All newly installed routes and all
newly unfeasible routes for which there is no replacement route SHALL newly unfeasible routes for which there is no replacement route SHALL
be advertised to its peers by means of an UPDATE message. be advertised to its peers by means of an UPDATE message.
A BGP speaker SHOULD NOT advertise a given feasible BGP route from A BGP speaker SHOULD NOT advertise a given feasible BGP route from
its Adj-RIB-Out if it would produce an UPDATE message containing the its Adj-RIB-Out if it would produce an UPDATE message containing the
same BGP route as was previously advertised. same BGP route as was previously advertised.
skipping to change at page 72, line 45 skipping to change at page 82, line 20
9.2.1 Controlling Routing Traffic Overhead 9.2.1 Controlling Routing Traffic Overhead
The BGP protocol constrains the amount of routing traffic (that is, The BGP protocol constrains the amount of routing traffic (that is,
UPDATE messages) in order to limit both the link bandwidth needed to UPDATE messages) in order to limit both the link bandwidth needed to
advertise UPDATE messages and the processing power needed by the advertise UPDATE messages and the processing power needed by the
Decision Process to digest the information contained in the UPDATE Decision Process to digest the information contained in the UPDATE
messages. messages.
9.2.1.1 Frequency of Route Advertisement 9.2.1.1 Frequency of Route Advertisement
The parameter MinRouteAdvertisementInterval determines the minimum The parameter MinRouteAdvertisementIntervalTimer determines the mini-
amount of time that must elapse between advertisement and/or with- mum amount of time that must elapse between advertisement and/or
drawal of routes to a particular destination by a BGP speaker to a withdrawal of routes to a particular destination by a BGP speaker to
peer. This rate limiting procedure applies on a per-destination a peer. This rate limiting procedure applies on a per-destination
basis, although the value of MinRouteAdvertisementInterval is set on basis, although the value of MinRouteAdvertisementIntervalTimer is
a per BGP peer basis. set on a per BGP peer basis.
Two UPDATE messages sent by a BGP speaker to a peer that advertise Two UPDATE messages sent by a BGP speaker to a peer that advertise
feasible routes and/or withdrawal of unfeasible routes to some common feasible routes and/or withdrawal of unfeasible routes to some common
set of destinations MUST be separated by at least MinRouteAdvertise- set of destinations MUST be separated by at least MinRouteAdvertise-
mentInterval. Clearly, this can only be achieved precisely by keeping mentIntervalTimer. Clearly, this can only be achieved precisely by
a separate timer for each common set of destinations. This would be keeping a separate timer for each common set of destinations. This
unwarranted overhead. Any technique which ensures that the interval would be unwarranted overhead. Any technique which ensures that the
between two UPDATE messages sent from a BGP speaker to a peer that interval between two UPDATE messages sent from a BGP speaker to a
advertise feasible routes and/or withdrawal of unfeasible routes to peer that advertise feasible routes and/or withdrawal of unfeasible
some common set of destinations will be at least MinRouteAdvertise- routes to some common set of destinations will be at least Min-
mentInterval, and will also ensure a constant upper bound on the RouteAdvertisementIntervalTimer, and will also ensure a constant
interval is acceptable. upper bound on the interval is acceptable.
Since fast convergence is needed within an autonomous system, either Since fast convergence is needed within an autonomous system, either
(a) the MinRouteAdvertisementInterval used for internal peers SHOULD (a) the MinRouteAdvertisementIntervalTimer used for internal peers
be shorter than the MinRouteAdvertisementInterval used for external SHOULD be shorter than the MinRouteAdvertisementIntervalTimer used
peers, or (b) the procedure describe in this section SHOULD NOT apply for external peers, or (b) the procedure describe in this section
for routes sent to internal peers. SHOULD NOT apply for routes sent to internal peers.
This procedure does not limit the rate of route selection, but only This procedure does not limit the rate of route selection, but only
the rate of route advertisement. If new routes are selected multiple the rate of route advertisement. If new routes are selected multiple
times while awaiting the expiration of MinRouteAdvertisementInterval, times while awaiting the expiration of MinRouteAdvertisementInterval-
the last route selected SHALL be advertised at the end of MinRouteAd- Timer, the last route selected SHALL be advertised at the end of Min-
vertisementInterval. RouteAdvertisementIntervalTimer.
9.2.1.2 Frequency of Route Origination 9.2.1.2 Frequency of Route Origination
The parameter MinASOriginationInterval determines the minimum amount The parameter MinASOriginationIntervalTimer determines the minimum
of time that must elapse between successive advertisements of UPDATE amount of time that must elapse between successive advertisements of
messages that report changes within the advertising BGP speaker's own UPDATE messages that report changes within the advertising BGP
autonomous systems. speaker's own autonomous systems.
9.2.2 Efficient Organization of Routing Information 9.2.2 Efficient Organization of Routing Information
Having selected the routing information which it will advertise, a Having selected the routing information which it will advertise, a
BGP speaker may avail itself of several methods to organize this BGP speaker may avail itself of several methods to organize this
information in an efficient manner. information in an efficient manner.
9.2.2.1 Information Reduction 9.2.2.1 Information Reduction
Information reduction may imply a reduction in granularity of policy Information reduction may imply a reduction in granularity of policy
skipping to change at page 74, line 47 skipping to change at page 84, line 21
listed individually as in the form of AS_SEQUENCEs. In practice listed individually as in the form of AS_SEQUENCEs. In practice
this is not likely to be a problem, since once an IP packet this is not likely to be a problem, since once an IP packet
arrives at the edge of a group of autonomous systems, the BGP arrives at the edge of a group of autonomous systems, the BGP
speaker at that point is likely to have more detailed path infor- speaker at that point is likely to have more detailed path infor-
mation and can distinguish individual paths to destinations. mation and can distinguish individual paths to destinations.
9.2.2.2 Aggregating Routing Information 9.2.2.2 Aggregating Routing Information
Aggregation is the process of combining the characteristics of sev- Aggregation is the process of combining the characteristics of sev-
eral different routes in such a way that a single route can be adver- eral different routes in such a way that a single route can be adver-
tised. Aggregation can occur as part of the decision process to tised. Aggregation can occur as part of the Decision Process to
reduce the amount of routing information that will be placed in the reduce the amount of routing information that will be placed in the
Adj-RIBs-Out. Adj-RIBs-Out.
Aggregation reduces the amount of information that a BGP speaker must Aggregation reduces the amount of information that a BGP speaker must
store and exchange with other BGP speakers. Routes can be aggregated store and exchange with other BGP speakers. Routes can be aggregated
by applying the following procedure separately to path attributes of by applying the following procedure separately to path attributes of
like type and to the Network Layer Reachability Information. the same type and to the Network Layer Reachability Information.
Routes that have different MULTI_EXIT_DISC attribute SHALL NOT be Routes that have different MULTI_EXIT_DISC attribute SHALL NOT be
aggregated. aggregated.
Path attributes that have different type codes can not be aggregated Path attributes that have different type codes can not be aggregated
together. Path attributes of the same type code may be aggregated, together. Path attributes of the same type code may be aggregated,
according to the following rules: according to the following rules:
NEXT_HOP: NEXT_HOP:
When aggregating routes that have different NEXT_HOP attribute, When aggregating routes that have different NEXT_HOP attribute,
the NEXT_HOP attribute of the aggregated route SHALL identify the NEXT_HOP attribute of the aggregated route SHALL identify
an interface on the BGP speaker that performs the aggregation. an interface on the BGP speaker that performs the aggregation.
ORIGIN attribute: ORIGIN attribute:
If at least one route among routes that are aggregated has ORI- If at least one route among routes that are aggregated has ORI-
GIN with the value INCOMPLETE, then the aggregated route MUST GIN with the value INCOMPLETE, then the aggregated route MUST
have the ORIGIN attribute with the value INCOMPLETE. Other- have the ORIGIN attribute with the value INCOMPLETE. Other-
wise, if at least one route among routes that are aggregated wise, if at least one route among routes that are aggregated
has ORIGIN with the value EGP, then the aggregated route MUST has ORIGIN with the value EGP, then the aggregated route MUST
have the origin attribute with the value EGP. In all other case have the ORIGIN attribute with the value EGP. In all other
the value of the ORIGIN attribute of the aggregated route is cases the value of the ORIGIN attribute of the aggregated route
IGP. is IGP.
AS_PATH attribute: AS_PATH attribute:
If routes to be aggregated have identical AS_PATH attributes, If routes to be aggregated have identical AS_PATH attributes,
then the aggregated route has the same AS_PATH attribute as then the aggregated route has the same AS_PATH attribute as
each individual route. each individual route.
For the purpose of aggregating AS_PATH attributes we model each For the purpose of aggregating AS_PATH attributes we model each
AS within the AS_PATH attribute as a tuple <type, value>, where AS within the AS_PATH attribute as a tuple <type, value>, where
"type" identifies a type of the path segment the AS belongs to "type" identifies a type of the path segment the AS belongs to
(e.g. AS_SEQUENCE, AS_SET), and "value" is the AS number. If (e.g. AS_SEQUENCE, AS_SET), and "value" is the AS number. If
skipping to change at page 76, line 52 skipping to change at page 86, line 26
fies the conditions and allows for more complex policy configu- fies the conditions and allows for more complex policy configu-
rations. rations.
ATOMIC_AGGREGATE: ATOMIC_AGGREGATE:
If at least one of the routes to be aggregated has If at least one of the routes to be aggregated has
ATOMIC_AGGREGATE path attribute, then the aggregated route ATOMIC_AGGREGATE path attribute, then the aggregated route
SHALL have this attribute as well. SHALL have this attribute as well.
AGGREGATOR: AGGREGATOR:
Any AGGREGATOR attributes from the routes to be aggregated MUST Any AGGREGATOR attributes from the routes to be aggregated MUST
NOT be included in the aggregated route. The BGP speaker NOT be included in the aggregated route. The BGP speaker per-
performing the route aggregation MAY attach a new AGGREGATOR forming the route aggregation MAY attach a new AGGREGATOR
attribute (see Section 5.1.7). attribute (see Section 5.1.7).
9.3 Route Selection Criteria 9.3 Route Selection Criteria
Generally speaking, additional rules for comparing routes among sev- Generally speaking, additional rules for comparing routes among sev-
eral alternatives are outside the scope of this document. There are eral alternatives are outside the scope of this document. There are
two exceptions: two exceptions:
- If the local AS appears in the AS path of the new route being - If the local AS appears in the AS path of the new route being
considered, then that new route can not be viewed as better than considered, then that new route can not be viewed as better than
any other route (provided that the speaker is configured to accept any other route (provided that the speaker is configured to accept
such routes). If such a route were ever used, a routing loop could such routes). If such a route were ever used, a routing loop could
result. result.
- In order to achieve successful distributed operation, only - In order to achieve successful distributed operation, only
routes with a likelihood of stability can be chosen. Thus, an AS routes with a likelihood of stability can be chosen. Thus, an AS
SHOULD avoid using unstable routes, and it SHOULD NOT make rapid SHOULD avoid using unstable routes, and it SHOULD NOT make rapid
spontaneous changes to its choice of route. Quantifying the terms spontaneous changes to its choice of route. Quantifying the terms
"unstable" and "rapid" in the previous sentence will require expe- "unstable" and "rapid" in the previous sentence will require expe-
rience, but the principle is clear. rience, but the principle is clear. Routes that are unstable can
be "penalized" (e.g., by using the procedures described in
Care must be taken to ensure that BGP speakers in the same AS do not [RFC2439]).
make inconsistent decisions.
9.4 Originating BGP routes 9.4 Originating BGP routes
A BGP speaker may originate BGP routes by injecting routing informa- A BGP speaker may originate BGP routes by injecting routing informa-
tion acquired by some other means (e.g. via an IGP) into BGP. A BGP tion acquired by some other means (e.g. via an IGP) into BGP. A BGP
speaker that originates BGP routes assigns the degree of preference speaker that originates BGP routes assigns the degree of preference
to these routes by passing them through the Decision Process (see (e.g., via CLI) to these routes by passing them through the Decision
Section 9.1). These routes MAY also be distributed to other BGP Process (see Section 9.1). These routes MAY also be distributed to
speakers within the local AS as part of the update process (see Sec- other BGP speakers within the local AS as part of the update process
tion 9.2). The decision whether to distribute non-BGP acquired routes (see Section 9.2). The decision whether to distribute non-BGP
within an AS via BGP or not depends on the environment within the AS acquired routes within an AS via BGP or not depends on the environ-
(e.g. type of IGP) and SHOULD be controlled via configuration. ment within the AS (e.g. type of IGP) and SHOULD be controlled via
configuration.
10 BGP Timers 10 BGP Timers
BGP employs five timers: ConnectRetry (see Section 8), Hold Time (see BGP employs five timers: ConnectRetryTimer (see Section 8), HoldTimer
Section 4.2), KeepAlive (see Section 8), MinASOriginationInterval (see Section 4.2), KeepAliveTimer (see Section 8), MinASOrigination-
(see Section 9.2.1.2), and MinRouteAdvertisementInterval (see Section IntervalTimer (see Section 9.2.1.2), and MinRouteAdvertisementInter-
9.2.1.1). valTimer (see Section 9.2.1.1).
The suggested default value for the ConnectRetry timer is 120 sec-
onds.
The suggested default value for the Hold Time is 90 seconds. Two optional timers MAY be supported: DelayOpenTimer, IdleHoldTimer
by BGP (see section 8). Section 8 describes their use. The full oper-
ation of these optional timers is outside the scope of this document.
The suggested default value for the KeepAlive timer is 1/3 of the ConnectRetryTime is a mandatory FSM attribute that stores the initial
Hold Time. value for the ConnectRetryTimer. The suggested default value for the
ConnectRetryTime is 120 seconds.
The suggested default value for the MinASOriginationInterval is 15 Holdtime is a mandatory FSM attribute that stores the initial value
for the HoldTimer. The suggested default value for the HoldTime is 90
seconds. seconds.
The suggested default value for the MinRouteAdvertisementInterval is During some portions of the state machine (see Section 8), the Hold-
30 seconds. Timer is set to a large value. The suggested default for this large
value is 4 minutes.
An implementation of BGP MUST allow the Hold Time timer to be config- The KeepaliveTime is a mandatory FSM attribute that stores the ini-
urable on a per peer basis, and MAY allow the other timers to be con- tial value for the KeepaliveTimer. The suggested default value for
figurable. the KeepaliveTime is 1/3 of the HoldTime.
The suggested default value for the MinASOriginationIntervalTimer is
15 seconds.
The suggested default value for the MinRouteAdvertisementInterval-
Timer on EBGP connections is 30 seconds.
The suggested default value for the MinRouteAdvertisementInterval-
Timer on IBGP connections is 5 seconds.
An implementation of BGP MUST allow the HoldTimer to be configurable
on a per peer basis, and MAY allow the other timers to be config-
urable.
To minimize the likelihood that the distribution of BGP messages by a To minimize the likelihood that the distribution of BGP messages by a
given BGP speaker will contain peaks, jitter SHOULD be applied to the given BGP speaker will contain peaks, jitter SHOULD be applied to the
timers associated with MinASOriginationInterval, KeepAlive, Min- timers associated with MinASOriginationIntervalTimer, KeepAliveTimer,
RouteAdvertisementInterval, and ConnectRetry. A given BGP speaker MAY MinRouteAdvertisementIntervalTimer, and ConnectRetryTimer. A given
apply the same jitter to each of these quantities regardless of the BGP speaker MAY apply the same jitter to each of these quantities
destinations to which the updates are being sent; that is, jitter regardless of the destinations to which the updates are being sent;
need not be configured on a "per peer" basis. that is, jitter need not be configured on a "per peer" basis.
The suggested default amount of jitter SHALL be determined by multi- The suggested default amount of jitter SHALL be determined by multi-
plying the base value of the appropriate timer by a random factor plying the base value of the appropriate timer by a random factor
which is uniformly distributed in the range from 0.75 to 1.0. A new which is uniformly distributed in the range from 0.75 to 1.0. A new
random value SHOULD be picked each time the timer is set. The range random value SHOULD be picked each time the timer is set. The range
of the jitter random value MAY be configurable. of the jitter random value MAY be configurable.
Appendix A. Comparison with RFC1771 Appendix A. Comparison with RFC1771
There are numerous editorial changes (too many to list here). There are numerous editorial changes (too many to list here).
skipping to change at page 79, line 34 skipping to change at page 89, line 22
UPDATE Message Error subcode 7 (AS Routing Loop) has been depre- UPDATE Message Error subcode 7 (AS Routing Loop) has been depre-
cated. cated.
OPEN Message Error subcode 5 (Authentication Failure) has been OPEN Message Error subcode 5 (Authentication Failure) has been
deprecated. deprecated.
Use of the Marker field for authentication has been deprecated. Use of the Marker field for authentication has been deprecated.
Implementations MUST support TCP MD5 [RFC2385] for authentication. Implementations MUST support TCP MD5 [RFC2385] for authentication.
Clarification of BGP FSM.
Appendix B. Comparison with RFC1267 Appendix B. Comparison with RFC1267
All the changes listed in Appendix A, plus the following. All the changes listed in Appendix A, plus the following.
BGP-4 is capable of operating in an environment where a set of reach- BGP-4 is capable of operating in an environment where a set of reach-
able destinations may be expressed via a single IP prefix. The con- able destinations may be expressed via a single IP prefix. The con-
cept of network classes, or subnetting is foreign to BGP-4. To cept of network classes, or subnetting is foreign to BGP-4. To
accommodate these capabilities BGP-4 changes semantics and encoding accommodate these capabilities BGP-4 changes semantics and encoding
associated with the AS_PATH attribute. New text has been added to associated with the AS_PATH attribute. New text has been added to
define semantics associated with IP prefixes. These abilities allow define semantics associated with IP prefixes. These abilities allow
skipping to change at page 80, line 4 skipping to change at page 89, line 40
cept of network classes, or subnetting is foreign to BGP-4. To cept of network classes, or subnetting is foreign to BGP-4. To
accommodate these capabilities BGP-4 changes semantics and encoding accommodate these capabilities BGP-4 changes semantics and encoding
associated with the AS_PATH attribute. New text has been added to associated with the AS_PATH attribute. New text has been added to
define semantics associated with IP prefixes. These abilities allow define semantics associated with IP prefixes. These abilities allow
BGP-4 to support the proposed supernetting scheme [9]. BGP-4 to support the proposed supernetting scheme [9].
To simplify configuration this version introduces a new attribute, To simplify configuration this version introduces a new attribute,
LOCAL_PREF, that facilitates route selection procedures. LOCAL_PREF, that facilitates route selection procedures.
The INTER_AS_METRIC attribute has been renamed to be MULTI_EXIT_DISC. The INTER_AS_METRIC attribute has been renamed to be MULTI_EXIT_DISC.
A new attribute, ATOMIC_AGGREGATE, has been introduced to insure that A new attribute, ATOMIC_AGGREGATE, has been introduced to insure that
certain aggregates are not de-aggregated. Another new attribute, certain aggregates are not de-aggregated. Another new attribute,
AGGREGATOR, can be added to aggregate routes in order to advertise AGGREGATOR, can be added to aggregate routes in order to advertise
which AS and which BGP speaker within that AS caused the aggregation. which AS and which BGP speaker within that AS caused the aggregation.
To insure that Hold Timers are symmetric, the Hold Time is now nego- To insure that Hold Timers are symmetric, the Hold Timer is now nego-
tiated on a per-connection basis. Hold Times of zero are now sup- tiated on a per-connection basis. Hold Timers of zero are now sup-
ported. ported.
Appendix C. Comparison with RFC 1163 Appendix C. Comparison with RFC 1163
All of the changes listed in Appendices A and B, plus the following. All of the changes listed in Appendices A and B, plus the following.
To detect and recover from BGP connection collision, a new field (BGP To detect and recover from BGP connection collision, a new field (BGP
Identifier) has been added to the OPEN message. New text (Section Identifier) has been added to the OPEN message. New text (Section
6.8) has been added to specify the procedure for detecting and recov- 6.8) has been added to specify the procedure for detecting and recov-
ering from collision. ering from collision.
skipping to change at page 84, line 28 skipping to change at page 94, line 21
more than once within the aggregated AS_PATH attribute, all, but more than once within the aggregated AS_PATH attribute, all, but
the last instance (rightmost occurrence) of that AS number SHOULD the last instance (rightmost occurrence) of that AS number SHOULD
be removed from the aggregated AS_PATH attribute. be removed from the aggregated AS_PATH attribute.
Security Considerations Security Considerations
The authentication mechanism that an implementation of BGP MUST sup- The authentication mechanism that an implementation of BGP MUST sup-
port is specified in [RFC2385]. The authentication provided by this port is specified in [RFC2385]. The authentication provided by this
mechanism could be done on a per peer basis. mechanism could be done on a per peer basis.
BGP vulnerabilities analysis is discussed in [XXX]. BGP vulnerabilities analysis is discussed in [BGP_VULN].
IANA Considerations IANA Considerations
All extensions to this protocol, including new message types and Path All new BGP message types, Path Attributes Type codes, Message Header
Attributes MUST only be made using the Standards Action process Error subcodes, OPEN Message Error subcodes, and UPDATE Message Error
defined in [RFC2434]. subcodes MUST only be made using the Standards Action process defined
in [RFC2434].
This document defines the following message types: OPEN, UPDATE,
KEEPALIVE, NOTIFICATION.
This document defines the following Path Attributes Type codes: ORI-
GIN, AS_PATH, NEXT_HOP, MULTI_EXIT_DISC, LOCAL_PREF, ATOMIC_AGGRE-
GATE, AGGREGATOR.
This document defines the following Message Header Error subcodes:
Connection Not Synchronized, Bad Message Length, Bad Message Type.
This document defines the following OPEN Message Error subcodes:
Unsupported Version Number, Bad Peer AS, Bad BGP Identifier, Unsup-
ported Optional Parameter, Unacceptable Hold Time.
This document defines the following UPDATE Message Error subcodes:
Malformed Attribute List, Unrecognized Well-known Attribute, Missing
Well-known Attribute, Attribute Flags Error, Attribute Length Error,
Invalid ORIGIN Attribute, Invalid NEXT_HOP Attribute, Optional
Attribute Error, Invalid Network Field, Malformed AS_PATH.
IPR Notice
The IETF has been notified of intellectual property rights claimed in
regard to some or all of the specification contained in this docu-
ment. For more information consult the online list of claimed rights.
The IETF takes no position regarding the validity or scope of any
intellectual property or other rights that might be claimed to per-
tain to the implementation or use of the technology described in this
document or the extent to which any license under such rights might
or might not be available; neither does it represent that it has made
any effort to identify any such rights. Information on the IETF's
procedures with respect to rights in standards-track and standards-
related documentation can be found in BCP-11. Copies of claims of
rights made available for publication and any assurances of licenses
to be made available, or the result of an attempt made to obtain a
general license or permission for the use of such proprietary rights
by implementors or users of this specification can be obtained from
the IETF Secretariat.
The IETF invites any interested party to bring to its attention any
copyrights, patents or patent applications, or other proprietary
rights which may cover technology that may be required to practice
this standard. Please address the information to the IETF Executive
Director.
Full Copyright Notice
Copyright (C) The Internet Society (2003). All Rights Reserved.
This document and translations of it may be copied and furnished to
others, and derivative works that comment on or otherwise explain it
or assist in its implementation may be prepared, copied, published
and distributed, in whole or in part, without restriction of any
kind, provided that the above copyright notice and this paragraph are
included on all such copies and derivative works. However, this doc-
ument itself may not be modified in any way, such as by removing the
copyright notice or references to the Internet Society or other
Internet organizations, except as needed for the purpose of develop-
ing Internet standards in which case the procedures for copyrights
defined in the Internet Standards process must be followed, or as
required to translate it into languages other than English.
The limited permissions granted above are perpetual and will not be
revoked by the Internet Society or its successors or assigns.
This document and the information contained herein is provided on an
"AS IS" basis and THE INTERNET SOCIETY AND THE INTERNET ENGINEERING
TASK FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING
BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION
HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF MER-
CHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE."
Normative References Normative References
[RFC791] Postel, J., "Internet Protocol - DARPA Internet Program Pro- [RFC791] Postel, J., "Internet Protocol - DARPA Internet Program Pro-
tocol Specification", RFC791, September 1981. tocol Specification", RFC791, September 1981.
[RFC793] Postel, J., "Transmission Control Protocol - DARPA Internet [RFC793] Postel, J., "Transmission Control Protocol - DARPA Internet
Program Protocol Specification", RFC793, September 1981. Program Protocol Specification", RFC793, September 1981.
[RFC2119] Bradner, S., "Key words for use in RFCs to Indicate [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
skipping to change at page 85, line 29 skipping to change at page 96, line 48
[RFC1092] Rekhter, Y., "EGP and Policy Based Routing in the New [RFC1092] Rekhter, Y., "EGP and Policy Based Routing in the New
NSFNET Backbone", RFC1092, February 1989. NSFNET Backbone", RFC1092, February 1989.
[RFC1093] Braun, H-W., "The NSFNET Routing Architecture", RFC1093, [RFC1093] Braun, H-W., "The NSFNET Routing Architecture", RFC1093,
February 1989. February 1989.
[RFC1772] Rekhter, Y., and P. Gross, "Application of the Border Gate- [RFC1772] Rekhter, Y., and P. Gross, "Application of the Border Gate-
way Protocol in the Internet", RFC1772, March 1995. way Protocol in the Internet", RFC1772, March 1995.
[RFC1518] Rekhter, Y., Li, T., "An Architecture for IP Address Allo- [RFC1518] Rekhter, Y., Li, T., "An Architecture for IP Address
cation with CIDR", RFC 1518, September 1993. Allocation with CIDR", RFC 1518, September 1993.
[RFC1519] Fuller, V., Li, T., Yu, J., and Varadhan, K., ""Classless [RFC1519] Fuller, V., Li, T., Yu, J., and Varadhan, K., ""Classless
Inter-Domain Routing (CIDR): an Address Assignment and Aggregation Inter-Domain Routing (CIDR): an Address Assignment and Aggregation
Strategy", RFC1519, September 1993. Strategy", RFC1519, September 1993.
[RFC1997] R. Chandra, P. Traina, T. Li, "BGP Communities Attribute", [RFC1997] R. Chandra, P. Traina, T. Li, "BGP Communities Attribute",
RFC 1997, August 1996. RFC 1997, August 1996.
[RFC2439] C. Villamizar, R. Chandra, R. Govindan, "BGP Route Flap [RFC2439] C. Villamizar, R. Chandra, R. Govindan, "BGP Route Flap
Damping", RFC2439, November 1998. Damping", RFC2439, November 1998.
[RFC2796] Bates, T., Chandra, R., Chen, E., "BGP Route Reflection - [RFC2796] Bates, T., Chandra, R., Chen, E., "BGP Route Reflection -
An Alternative to Full Mesh IBGP", RFC2796, April 2000. An Alternative to Full Mesh IBGP", RFC2796, April 2000.
[RFC2842] R. Chandra, J. Scudder, "Capabilities Advertisement with [RFC3392] R. Chandra, J. Scudder, "Capabilities Advertisement with
BGP-4", RFC2842. BGP-4", RFC2842.
[RFC2858] T. Bates, R. Chandra, D. Katz, Y. Rekhter, "Multiprotocol [RFC2858] T. Bates, R. Chandra, D. Katz, Y. Rekhter, "Multiprotocol
Extensions for BGP-4", RFC2858. Extensions for BGP-4", RFC2858.
[RFC2918] Chen, E., "Route Refresh Capability for BGP-4", RFC2918, [RFC2918] Chen, E., "Route Refresh Capability for BGP-4", RFC2918,
September 2000. September 2000.
[RFC3065] Traina, P, McPherson, D., Scudder, J., "Autonomous System [RFC3065] Traina, P, McPherson, D., Scudder, J., "Autonomous System
Confederations for BGP", RFC3065, February 2001. Confederations for BGP", RFC3065, February 2001.
[IS10747] "Information Processing Systems - Telecommunications and [IS10747] "Information Processing Systems - Telecommunications and
Information Exchange between Systems - Protocol for Exchange of Information Exchange between Systems - Protocol for Exchange of
Inter-domain Routeing Information among Intermediate Systems to Sup- Inter-domain Routeing Information among Intermediate Systems to Sup-
port Forwarding of ISO 8473 PDUs", ISO/IEC IS10747, 1993 port Forwarding of ISO 8473 PDUs", ISO/IEC IS10747, 1993
[XXX] Murphy, S., "BGP Security Vulnerabilities Analysis", draft- [BGP_VULN] Murphy, S., "BGP Security Vulnerabilities Analysis",
ietf-idr-bgp-vuln-00.txt, work in progress draft-ietf-idr-bgp-vuln-00.txt, work in progress
Editors' Addresses Editors' Addresses
Yakov Rekhter Yakov Rekhter
Juniper Networks Juniper Networks
email: yakov@juniper.net email: yakov@juniper.net
Tony Li Tony Li
Procket Networks, Inc. Procket Networks, Inc.
email: tli@procket.com email: tli@procket.com
 End of changes. 

This html diff was produced by rfcdiff 1.23, available from http://www.levkowetz.com/ietf/tools/rfcdiff/