CPC H04L 45/566 (2013.01) [H04L 45/122 (2013.01); H04L 45/17 (2022.05); H04L 45/34 (2013.01)] | 10 Claims |
1. A packet encapsulation method, comprising:
determining a segment routing-traffic engineering (SR-TE) path;
generating, according to a segment identifier (SID) of each node in the SR-TE path, an SID list, wherein each node supports a plurality of unified-SID encapsulation types (UETs) corresponding to SIDs of different lengths, and in the SID list, a SID of at least a node serving as an intermediate node of the SR-TE path is the SID having the non-longest length in the plurality of SIDs corresponding to the node;
forming a segment routing header (SRH) from the SID list; and
encapsulating an initial packet with the SRH to obtain a final packet,
wherein each SID having the non-longest length in the SID list is a SID compressed from an original SID having the longest length, and
wherein the generating, according to an SID of each node in the SR-TE path, an SID list comprises: carrying, in the SID of at least one intermediate node, a Flag indicating a length of a next SID of the SID of the intermediate node in the SID list.
|