- Home
- RFC 9774
RFC 9774: Deprecation of AS_SET and AS_CONFED_SET in BGP
- W. Kumari,
- K. Sriram,
- L. Hannachi,
- J. Haas
Abstract
BCP 172 (i.e., RFC 6472) recommends not using AS_
Status of This Memo
This is an Internet Standards Track document.¶
This document is a product of the Internet Engineering Task Force (IETF). It represents the consensus of the IETF community. It has received public review and has been approved for publication by the Internet Engineering Steering Group (IESG). Further information on Internet Standards is available in Section 2 of RFC 7841.¶
Information about the current status of this document, any
errata, and how to provide feedback on it may be obtained at
https://
Copyright Notice
Copyright (c) 2025 IETF Trust and the persons identified as the document authors. All rights reserved.¶
This document is subject to BCP 78 and the IETF Trust's Legal
Provisions Relating to IETF Documents
(https://
1. Introduction
[BCP172] recommends not
using AS_
The AS_
The AS_
By performing aggregation, a router is combining multiple BGP routes
for more specific destinations into a new route for a less specific
destination (see [RFC4271], Section 9.1.2.2). Aggregation
may blur the semantics of the origin AS for the prefix being announced by
producing an AS_
From analysis of historical Internet routing data, it is apparent that
aggregation that involves AS_
2. Requirements Language
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all capitals, as shown here.¶
3. Updates to the Requirements of RFCs 4271 and 5065
Unless explicitly configured by a network operator to do otherwise (e.g., during a transition phase), BGP speakers:¶
-
MUST NOT advertise BGP UPDATE messages containing AS_
SETs or AS_ CONFED_ SETs and¶ -
MUST use the "treat
-as -withdraw" error handling behavior per [RFC7606] upon reception of BGP UPDATE messages containing AS_ SETs or AS_ CONFED_ SETs in the AS_ PATH or AS4_ PATH [RFC6793].¶
Per the above specifications, this document updates [RFC4271] and [RFC5065]
by deprecating AS_
4. Treatment of Routes with AS_SET in RPKI-Based BGP Security
Resource Public Key Infrastructure (RPKI) [RFC6480] uses X.509
extensions for IP addresses and AS identifiers [RFC3779].
RPKI-ROV [RFC6811] [RFC6907]
is a BGP security technology that never allows a route with AS_
5. BGP AS_PATH "Brief" Aggregation
Sections 9.1.4 and 9.2.2.2 of [RFC4271]
describe BGP aggregation procedures. Appendix F.6 of [RFC4271] describes a generally less utilized
"Complex AS_
[RFC4271], Section 5.1.6
describes the ATOMIC_
When a BGP speaker aggregates several routes for the purpose of advertisement to a particular peer, the AS_
PATH of the aggregated route normally includes an AS_ SET formed from the set of ASes from which the aggregate was formed. In many cases, the network administrator can determine if the aggregate can safely be advertised without the AS_ SET, and without forming route loops.¶ If an aggregate excludes at least some of the AS numbers present in the AS_
PATH of the routes that are aggregated as a result of dropping the AS_ SET, the aggregated route, when advertised to the peer, SHOULD include the ATOMIC_ AGGREGATE attribute.¶
When BGP AS_
[D]etermine the longest leading sequence of tuples (as defined above) common to all the AS_
PATH attributes of the routes to be aggregated. Make this sequence the leading sequence of the aggregated AS_ PATH attribute.¶
The ATOMIC_
5.1. Issues with "Brief" AS_PATH Aggregation and RPKI-ROV
While brief AS_
- Depending on the contributing routes to the aggregate route, the resulting origin AS may vary.¶
- The presence of expected contributing routes may be unpredictable due to route availability from BGP neighbors.¶
- In the presence of such varying origin ASes, it would be necessary
for the resource holder to register ROAs [RFC9582] for each potential origin AS that
may result from the expected aggregated AS_
PATHs .¶
5.2. Recommendations to Mitigate Unpredictable AS_PATH Origins for RPKI-ROV Purposes
To ensure a consistent BGP origin AS is announced for
aggregate BGP routes for implementations of "brief" BGP aggregation, the
implementation MUST be configured to truncate the AS_
This form of brief aggregation is referred to as "consistent brief" BGP aggregation.¶
If the resulting AS_
6. Operational Considerations
This section provides advice to operators regarding deployment and configuration.¶
6.1. Implementing Consistent Brief Aggregation
When aggregating prefixes, network operators MUST use
consistent brief aggregation as described in
Section 5.2.
In consistent brief aggregation, the AGGREGATOR and ATOMIC_
6.2. Not Advertising Aggregate Routes to Contributing ASes
An aggregate prefix SHOULD NOT be announced to the contributing ASes. Instead, more specific prefixes (from the aggregate) SHOULD be announced to each contributing AS, excluding any that were learned from the contributing AS in consideration. See Appendix A for an example of this filtering policy.¶
6.3. Mitigating Forwarding Loops
When both less specific and more specific destinations are present, it's possible to create forwarding loops between networks, as discussed in Section 5.1 of [RFC4632].¶
As a reminder, Rule #2 in Section 5.1 of [RFC4632] requires that BGP implementations performing aggregation discard packets that match the aggregate route but do not match any of the more specific routes.¶
Further discussion of forwarding loops and their relationship to
AS_
7. Security Considerations
This document deprecates the use of aggregation techniques that create
AS_
8. IANA Considerations
This document has no IANA actions.¶
9. References
9.1. Normative References
- [BCP172]
-
Best Current Practice 172, <https://
www >..rfc -editor .org /info /bcp172
At the time of writing, this BCP comprises the following:Kumari, W. and K. Sriram, "Recommendation for Not Using AS_SET and AS_ , BCP 172, RFC 6472, DOI 10CONFED_ SET in BGP" .17487 , , <https:///RFC6472 www >..rfc -editor .org /info /rfc6472 - [RFC2119]
-
Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, DOI 10
.17487 , , <https:///RFC2119 www >..rfc -editor .org /info /rfc2119 - [RFC4271]
-
Rekhter, Y., Ed., Li, T., Ed., and S. Hares, Ed., "A Border Gateway Protocol 4 (BGP-4)", RFC 4271, DOI 10
.17487 , , <https:///RFC4271 www >..rfc -editor .org /info /rfc4271 - [RFC4632]
-
Fuller, V. and T. Li, "Classless Inter-domain Routing (CIDR): The Internet Address Assignment and Aggregation Plan", BCP 122, RFC 4632, DOI 10
.17487 , , <https:///RFC4632 www >..rfc -editor .org /info /rfc4632 - [RFC5065]
-
Traina, P., McPherson, D., and J. Scudder, "Autonomous System Confederations for BGP", RFC 5065, DOI 10
.17487 , , <https:///RFC5065 www >..rfc -editor .org /info /rfc5065 - [RFC6793]
-
Vohra, Q. and E. Chen, "BGP Support for Four-Octet Autonomous System (AS) Number Space", RFC 6793, DOI 10
.17487 , , <https:///RFC6793 www >..rfc -editor .org /info /rfc6793 - [RFC7606]
-
Chen, E., Ed., Scudder, J., Ed., Mohapatra, P., and K. Patel, "Revised Error Handling for BGP UPDATE Messages", RFC 7606, DOI 10
.17487 , , <https:///RFC7606 www >..rfc -editor .org /info /rfc7606 - [RFC8174]
-
Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words", BCP 14, RFC 8174, DOI 10
.17487 , , <https:///RFC8174 www >..rfc -editor .org /info /rfc8174
9.2. Informative References
- [Analysis]
-
"Detailed analysis of AS_
SETs in BGP updates" , commit ef3f4a9, , <https://github >..com /ksriram25 /IETF /blob /main /Detailed -AS_ SET -analysis .txt - [ASPA
-VERIFICATION] -
Azimov, A., Bogomazov, E., Bush, R., Patel, K., Snijders, J., and K. Sriram, "BGP AS_
PATH Verification Based on Autonomous System Provider Authorization (ASPA) Objects" , Work in Progress, Internet-Draft, draft-ietf , , <https://-sidrops -aspa -verification -22 datatracker >..ietf .org /doc /html /draft -ietf -sidrops -aspa -verification -22 - [IANA-SP-ASN]
-
IANA, "Special-Purpose Autonomous System (AS) Numbers", <https://
www >..iana .org /assignments /iana -as -numbers -special -registry - [RFC3779]
-
Lynn, C., Kent, S., and K. Seo, "X.509 Extensions for IP Addresses and AS Identifiers", RFC 3779, DOI 10
.17487 , , <https:///RFC3779 www >..rfc -editor .org /info /rfc3779 - [RFC6480]
-
Lepinski, M. and S. Kent, "An Infrastructure to Support Secure Internet Routing", RFC 6480, DOI 10
.17487 , , <https:///RFC6480 www >..rfc -editor .org /info /rfc6480 - [RFC6811]
-
Mohapatra, P., Scudder, J., Ward, D., Bush, R., and R. Austein, "BGP Prefix Origin Validation", RFC 6811, DOI 10
.17487 , , <https:///RFC6811 www >..rfc -editor .org /info /rfc6811 - [RFC6907]
-
Manderson, T., Sriram, K., and R. White, "Use Cases and Interpretations of Resource Public Key Infrastructure (RPKI) Objects for Issuers and Relying Parties", RFC 6907, DOI 10
.17487 , , <https:///RFC6907 www >..rfc -editor .org /info /rfc6907 - [RFC8205]
-
Lepinski, M., Ed. and K. Sriram, Ed., "BGPsec Protocol Specification", RFC 8205, DOI 10
.17487 , , <https:///RFC8205 www >..rfc -editor .org /info /rfc8205 - [RFC9319]
-
Gilad, Y., Goldberg, S., Sriram, K., Snijders, J., and B. Maddison, "The Use of maxLength in the Resource Public Key Infrastructure (RPKI)", BCP 185, RFC 9319, DOI 10
.17487 , , <https:///RFC9319 www >..rfc -editor .org /info /rfc9319 - [RFC9582]
-
Snijders, J., Maddison, B., Lepinski, M., Kong, D., and S. Kent, "A Profile for Route Origin Authorizations (ROAs)", RFC 9582, DOI 10
.17487 , , <https:///RFC9582 www >..rfc -editor .org /info /rfc9582
Appendix A. Example of Route Filtering for Aggregate Routes and Their Contributors
The illustration presented below shows how an AS_
( ) ( ) ( ) ( )
( AS64501 ) ( AS64502 ) ( AS64503 ) ( AS64504 )
( ) ( ) ( ) ( )
p1/24 p2/24 p3/24 p4/24
| | | |
| +--> ( ) <--+ |
| ( AS64505 ) |
+----------------> ( ) <----------------+
p/22
|
V
AS 64501 AS 64502
========================== ==========================
p1/24 AS_PATH "" p1/24 AS_PATH "64505 64501"
p2/24 AS_PATH "64505 64502" p2/24 AS_PATH ""
p3/24 AS_PATH "64505 64503" p3/24 AS_PATH "64505 64503"
p4/24 AS_PATH "64505 64504" p4/24 AS_PATH "64505 64504"
AS 64503 AS 64504
========================== ==========================
p1/24 AS_PATH "64505 64501" p1/24 AS_PATH "64505 64501"
p2/24 AS_PATH "64505 64502" p2/24 AS_PATH "64505 64502"
p3/24 AS_PATH "" p3/24 AS_PATH "64505 64503"
p4/24 AS_PATH "64505 64504" p4/24 AS_PATH ""
AS 64505
==========================
p/22 AS_PATH "" AGGREGATOR 64505 ATOMIC_AGGREGATE
p1/24 AS_PATH "64501"
p2/24 AS_PATH "64502"
p3/24 AS_PATH "64503"
p4/24 AS_PATH "64504"Appendix B. Examples of Consistent and Inconsistent BGP Origin AS Generated by Brief Aggregation
The examples below illustrate how brief aggregation may result in an inconsistent origin AS.¶
AS 64500 aggregates more specific routes into 192.0.2.0/24.¶
Consider the following scenarios where brief aggregation is done by AS 64500 and what the resultant origin ASes would be.¶
Routes:
R1 - 192.0.2.0/26 AS_PATH "64501"
R2 - 192.0.2.64/26 AS_PATH "64502"
R3 - 192.0.2.128/26 AS_PATH "64504 64502"
R4 - 192.0.2.192/26 AS_PATH "64504 64501"
( ) ( )
( AS64501 ) ( AS64502 )
( ) ( )
192.0.2.0/26 192.0.2.192/26 192.0.2.128/26 192.0.2.64/26
| | | |
| | | |
| \/ \/ |
| ( ) |
| ( AS64504 ) |
| ( ) |
| | | |
| R4 | | R3 |
| | | |
| \/ \/ |
| R1 ( ) R2 |
+------------------->( AS64500 )<-------------+
( )
|
| (announcing
| aggregate 192.0.2.0/24)
\/
B.1. Scenario 1: First one route, then another, each with a fully disjoint AS_PATH
Receive R1. Aggregate 192.0.2.0/24 AS_
Alternate "bug?": Aggregate 192.0.2.0/24 AS_
(Note: AS numbers within square brackets represent an AS_
Receive R2. Aggregate 192.0.2.0/24 AS_
If brief aggregation is in use, the AS_
The resulting AS_
B.2. Scenario 2: First one route, then another, and the AS_PATHs overlap at the origin AS
Receive R1. Aggregate 192.0.2.0/24 AS_
Receive R4. Aggregate 192.0.2.0/24 AS_
If brief aggregation is in use, the AS_
The resulting AS_
B.3. Scenario 3: First one route, then another, and the AS_PATHs overlap at the neighbor AS
Receive R3. Aggregate 192.0.2.0/24 AS_
Receive R4. Aggregate 192.0.2.0/24 AS_
If brief aggregation is in use, the AS_
The resulting AS_
B.4. Achieving Consistent Origin AS During Aggregation
In the three scenarios above, the aggregating AS 64500 is using brief aggregation. This results in inconsistent origin ASes as the contributing routes are learned. This motivates the "consistent brief" BGP aggregation mentioned in Section 5.2 and discussed further with examples below.¶
The trivial solution to addressing the issue is to simply discard all of the ASes for the contributing routes. In simple BGP aggregation topologies, this is likely the correct thing to do. The AS originating the aggregate, 192.0.2.0/24 in this example, is likely the resource holder for the route in question. In such a case, simply originating the route to its BGP upstream neighbors in the Internet with its own AS, 64500, means that a consistent ROA could be registered in the RPKI for this prefix. This satisfies the need for a consistent (unambiguous) origin AS.¶
If the contributing ASes are themselves multihomed to the Internet outside of their connections to AS 64500, then additional ROAs would need to be created for each of the more specific prefixes.¶
In more complex proxy aggregation scenarios, there may be a desire
to permit some stable (i.e., common) portion of the contributing AS_
Appendix C. Discussion on Forwarding Loops and AS_SETs
Although BGP-4 was designed to carry Classless Inter-Domain Routing (CIDR) routes, [RFC4271] does not discuss the installation of "discard" or "null" routes when implementing its aggregation procedures. Implementations could originate an aggregate prefix without a covering route for a more specific prefix (subsumed by the aggregate prefix) present in the local routing table.¶
When aggregating more specific routes according to
the aggregation procedures of [RFC4271], the aggregating BGP
speaker will place contributing routes into the generated AS_
When brief aggregation methods are used, a BGP speaker may receive a
route containing a less specific destination covering a local more specific
destination and install it in its routing table since it is not
prevented from doing so by BGP AS_
- Rule #2 in Section 5.1 of [RFC4632]:¶
A router that generates an aggregate route for multiple, more-specific routes must discard packets that match the aggregate route, but not any of the more-specific routes. In other words, the "next hop" for the aggregate route should be the null destination.¶
- Not advertising aggregate routes to contributing ASes as specified in Section 6.2 of this document (also see Appendix A).¶
Acknowledgements
The authors would like to thank Alvaro Retana, John Scudder, Ketan Talaulikar, Keyur Patel, Susan Hares, Claudio Jeker, Nick Hilliard, Robert Raszuk, John Heasley, Job Snijders, Jared Mauch, Jakob Heitz, Tony Przygienda, Douglas Montgomery, Randy Bush, Curtis Villamizar, Danny McPherson, Chris Morrow, Tom Petch, Ilya Varlashkin, Enke Chen, Tony Li, Florian Weimer, John Leslie, Paul Jakma, Rob Austein, Russ Housley, Sandra Murphy, Steven M. Bellovin, Steve Kent, Steve Padgett, and Alfred Hoenes for comments and suggestions. The comments and suggestions received from the IESG reviewers are also much appreciated.¶