RFC 4271 BGP-4
b) AS_PATH (Type Code 2):
AS_PATH is a well-known mandatory attribute that is composed
of a sequence of AS path segments. Each AS path segment is
represented by a triple
.
The path segment type is a 1-octet length field with the
following values defined:
Value Segment Type
1 AS_SET: unordered set of ASes a route in the
UPDATE message has traversed
2 AS_SEQUENCE: ordered set of ASes a route in
the UPDATE message has traversed
The path segment length is a 1-octet length field,
containing the number of ASes (not the number of octets) in
the path segment value field.
The path segment value field contains one or more AS
numbers, each encoded as a 2-octet length field.
Usage of this attribute is defined in 5.1.2.