rfc-9774

Deprecation of AS_SET and AS_CONFED_SET in BGP

W. Kumari, K. Sriram, L. Hannachi, J. Haas
date2025-05 streamIETF areartg wgidr statusPROPOSED STANDARD pages13 canonicalhttps://www.rfc-editor.org/rfc/rfc9774 doi10.17487/RFC9774
BCP 172 (i.e., RFC 6472) recommends not using AS_SET and AS_CONFED_SET AS_PATH segment types in the Border Gateway Protocol (BGP). This document advances that recommendation to a standards requirement in BGP; it prohibits the use of the AS_SET and AS_CONFED_SET path segment types in the AS_PATH. This is done to simplify the design and implementation of BGP and to make the semantics of the originator of a BGP route clearer. This will also simplify the design, implementation, and deployment of various BGP security mechanisms. This document updates RFC 4271 by deprecating the origination of BGP routes with AS_SET (Type 1 AS_PATH segment) and updates RFC 5065 by deprecating the origination of BGP routes with AS_CONFED_SET (Type 4 AS_PATH segment). Finally, it obsoletes RFC 6472.

obsoletes

updates

Extracted elements (21)

design-rationale §1

AS_SETs are being prohibited because they blur the semantics of the origin AS for aggregated prefixes, which prevents authentication of route origin in RPKI-based security technologies and can cause reachability problems. Analysis of historical Internet routing data shows AS_SET aggregation is very seldom used in practice.

bgp, routing, security

design-rationale §5.1

Consistent brief aggregation (truncating the AS_PATH at the desired origin AS rather than generating an AS_SET) is recommended because brief aggregation without it can yield an unstable origin AS that varies depending on which contributing routes are present, breaking RPKI-ROV.

bgp, routing

design-rationale §6.2

Not advertising the aggregate prefix back to contributing ASes avoids data-plane forwarding loops that arise when brief aggregation is used, since AS_PATH loop detection no longer prevents contributing ASes from installing the less-specific aggregate route.

bgp, routing

design-rationale §1

When AS_SET aggregation does occur in practice, it is often used incorrectly: the most common case is a single AS in the AS_SET, the same AS often appears in both the AS_SEQUENCE and the AS_SET, and reserved AS numbers appear with some frequency.

bgp, routing

interoperability-note §3

An explicit operator configuration override is permitted for the prohibition on advertising AS_SET/AS_CONFED_SET, to accommodate transition phases where legacy peers or aggregation policies require continued use.

bgp, routing

interoperability-note §1

This document updates RFC 4271 by deprecating AS_SET (Type 1) origination and RFC 5065 by deprecating AS_CONFED_SET (Type 4) origination; it also obsoletes RFC 6472 (BCP 172), advancing that BCP recommendation to a standards-track prohibition.

bgp, routing

normative-requirement §6.2 SHOULD NOT

An aggregate prefix SHOULD NOT be announced to the contributing ASes; instead, more specific prefixes SHOULD be announced to each contributing AS, excluding any learned from that contributing AS.

bgp, routing

normative-requirement §3 MUST NOT

BGP speakers MUST NOT advertise BGP UPDATE messages containing AS_SETs or AS_CONFED_SETs in the AS_PATH, unless explicitly configured by a network operator to do otherwise (e.g., during a transition phase).

bgp, routing, security

normative-requirement §5.2 SHOULD

If the resulting AS_PATH is truncated from the otherwise expected result of BGP AS_PATH aggregation, the ATOMIC_AGGREGATE Path Attribute SHOULD be attached, consistent with RFC 4271 Section 5.1.6.

bgp, routing

normative-requirement §6.1 MUST

Network operators MUST use consistent brief aggregation as described in Section 5.2; in consistent brief aggregation, AGGREGATOR and ATOMIC_AGGREGATE Path Attributes are included but the AS_PATH does not have AS_SET or AS_CONFED_SET path segment types.

bgp, routing

normative-requirement §6.3 MUST

Per RFC 4632 Rule #2, a router generating an aggregate route MUST discard packets that match the aggregate route but not any of the more-specific routes (i.e., the next hop for the aggregate route should be the null destination).

bgp, routing

normative-requirement §5.2 MUST

To ensure a consistent BGP origin AS for aggregate routes, the implementation MUST be configured to truncate the AS_PATH after the right-most instance of the desired origin AS for the aggregate. This is called 'consistent brief' BGP aggregation.

bgp, routing

normative-requirement §3 MUST

Upon reception of BGP UPDATE messages containing AS_SETs or AS_CONFED_SETs in the AS_PATH or AS4_PATH, BGP speakers MUST use the 'treat-as-withdraw' error handling behavior per RFC 7606.

bgp, routing

protocol-element §1

AS_CONFED_SET (Type 4 AS_PATH segment) is an unordered set of Member AS Numbers in the local confederation that contributing prefixes have traversed, used within a confederation during aggregation. This document deprecates its origination.

bgp, routing

protocol-element §1

AS_SET (Type 1 AS_PATH segment) is an unordered set of Autonomous Systems that contributing prefixes in an aggregate have traversed, created by a router performing route aggregation. This document deprecates its origination.

bgp, routing

protocol-element §5

Brief aggregation refers to BGP AS_PATH aggregation per RFC 4271 Section 9.2.2.2 where any resulting AS_SETs are discarded and the ATOMIC_AGGREGATE attribute is attached; the resulting AS_PATH is the longest leading common sequence of tuples from contributing routes.

bgp, routing

protocol-element §5.2

Consistent brief aggregation is a form of brief aggregation where the AS_PATH is truncated after the right-most instance of the desired origin AS, ensuring a stable and unambiguous origin AS for RPKI-ROV purposes and avoiding AS_SET generation.

bgp, routing

protocol-element §5

The ATOMIC_AGGREGATE Path Attribute is attached to an aggregate BGP route when AS_SETs are dropped or the AS_PATH is truncated, signaling that the route was aggregated and some AS path information may have been omitted.

bgp, routing

security-consideration §5.1

Brief aggregation without consistent origin AS control can result in unpredictable origin ASes, requiring resource holders to register ROAs for each potential origin AS and complicating RPKI-ROV validation for aggregate prefixes.

bgp, routing, security

security-consideration §7

Deprecating AS_SET and AS_CONFED_SET simplifies BGP and reduces the attack surface; removing related code from implementations is beneficial. New BGP security technologies such as RPKI, BGPsec, and ASPA benefit greatly when AS_SETs are not used.

bgp, routing, security

security-consideration §4

RPKI-ROV never allows a route with AS_SET to be considered Valid; BGPsec does not support AS_SETs; and ASPA-based AS_PATH verification always considers a route with AS_SET as Invalid and ineligible for route selection.

bgp, routing, security, pkix