4.2.2. Generating Updates
When communicating with an OLD BGP speaker, a NEW speaker MUST send
the AS path information in the AS_PATH attribute encoded with 2-octet
AS numbers. The NEW speaker MUST also send the AS path information
in the AS4_PATH attribute (encoded with 4-octet AS numbers), except
for the case where the entire AS path information is composed of 2-
octet AS numbers only. In this case, the NEW speaker SHOULD NOT send
the AS4_PATH attribute.
In the AS_PATH attribute encoded with 2-octet AS numbers, non-
mappable 4-octet AS numbers are represented by the well-known 2-octet
AS number, AS_TRANS. This will preserve the path length property of
the AS path information and also help in updating the AS path
information received on a NEW BGP speaker from an OLD speaker, as
explained in the next section.
The NEW speaker constructs the AS4_PATH attribute from the
information carried in the AS_PATH attribute. In the case where the
AS_PATH attribute contains either AS_CONFED_SEQUENCE or AS_CONFED_SET
path segments, the NEW speaker, when constructing the AS4_PATH
attribute from the AS_PATH attribute, MUST exclude such path
segments. The AS4_PATH attribute will be carried across a series of
OLD BGP speakers without modification and will help preserve the
truly 4-octet AS numbers in the AS path information.
Similarly, if the NEW speaker has to send the AGGREGATOR attribute,
and if the aggregating Autonomous System's AS number is truly 4-
octets, then the speaker constructs the AS4_AGGREGATOR attributes by
taking the attribute length and attribute value from the AGGREGATOR
attribute and placing them into the attribute length and attribute
value of the AS4_AGGREGATOR attribute, and sets the AS number field
in the existing AGGREGATOR attribute to the reserved AS number,
AS_TRANS. Note that if the AS number is 2-octets only, then the
AS4_AGGREGATOR attribute SHOULD NOT be sent.