STAMP Extensions for DetNet
Xiao Min
ZTE Corp.
Nanjing
China
+86 18061680168
xiao.min2@zte.com.cn
Shaofu Peng
ZTE Corp.
Nanjing
China
peng.shaofu@zte.com.cn
Xiaoming He
China Telecom
Guangzhou
China
hexm4@chinatelecom.cn
2024
Routing
IPPM Working Group
Request for Comments
RFC
Internet Draft
I-D
Deterministic Networking (DetNet) provides a capability for the delivery of data flows with extremely low packet loss rates and bounded end-to-end delivery latency. The enabler to DetNet is a proper queue scheduling mechanism, such as timeslot based queueing and forwarding mechanism, which requires every router along the DetNet path to collect the basic timeslot mapping relationship between itself and its adjacent router. This document defines two Simple Two-Way Active Measurement Protocol (STAMP) TLVs, to acquire the basic timeslot mapping relationship between the local router and its adjacent router.

Introduction
Deterministic Networking (DetNet) provides a capability for the delivery of data flows with extremely low packet loss rates and bounded end-to-end delivery latency. DetNet is for networks that are under a single administrative control or within a closed group of administrative control. [RFC8578] presents the DetNet use cases and [RFC8655] provides the overall architecture for DetNet.
[I-D.peng-detnet-packet-timeslot-mechanism] specifies a queue scheduling mechanism that can be used for DetNet. To make the TQF mechanism work, it's required for every hop router along the DetNet path to collect the basic timeslot mapping relationship between itself and its adjacent router. The basic timeslot mapping relationship is not related to any individual flow, but to a network topological properties (such as the beginning time of the period configured by each node, link propagation delay, etc).
The Simple Two-Way Active Measurement Protocol (STAMP) provides a capability for the measurement of various performance metrics in IP networks. [RFC8762] defines the STAMP base functionalities and [RFC8972] specifies the use of optional STAMP extensions that use Type-Length-Value (TLV) encoding.
STAMP test packets are transmitted along an IP path between a Session-Sender and a Session-Reflector. The IP path can be either a single-hop path or a multi-hop path, depending on the application scenario of STAMP.
This document defines two STAMP TLVs, to acquire the timeslot mapping relationship between the local router and its adjacent router, i.e., the mapping direction is from the local router to its adjacent router.

Conventions

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.

Abbreviations
DetNet: Deterministic Networking
OP: Orchestration Period
OPL: Orchestration Period Length
STAMP: Simple Two-Way Active Measurement Protocol
TLV: Type-Length-Value
TQF: Timeslot based Queueing and Forwarding

TLVs for DetNet

Timeslot Mapping TLV
The Timeslot Mapping TLV enables collection of the mapping relationship of timeslots between the Session-Sender and the Session-Reflector. The timeslot mapping is based on a specific orchestration period at both the Session-Sender and the Session-Reflector, and the timeslot mapping may be different among different orchestration periods.

Timeslot Mapping TLV

 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|STAMP TLV Flags|   Type=TBD1   |         Length=20             |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|               Orchestration Period Length (OPL)               |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|   Session-Sender Slot Length  |     Session-Sender Slot X     |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                Session-Sender Trans-Deviation E               |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Session-Reflector Slot Length |   Session-Reflector Slot Y    |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|Reflector's Slot Remaining Time|  Return Code  |   Reserved    |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

The fields are defined as follows:
- STAMP TLV Flags: The STAMP TLV Flags follow the procedures described in [RFC8972].
- Type: Type (value TBD1) for the Timeslot Mapping TLV.
- Length: A two-octet field, set equal to the length of the Value field in octets. The length is 20 octets.
- Orchestration Period Length: A four-octet field that characterizes the orchestration period in microsecond at the Session-Sender. The Session-Reflector uses this period as a key to match the TQF scheduling instance.
- Session-Sender Slot Length: A two-octet field that characterizes the Session-Sender timeslot in microsecond.
- Session-Sender Slot X: A two-octet field that characterizes the Session-Sender timeslot number (X) for which the Session-Sender queries the mapping relationship.
- Session-Sender Trans-Deviation E: A four-octet field that characterizes the time difference in microsecond between the begin of timeslot (X) and the time sending the STAMP packet, i.e., E = sending time - X.begin. This field may be zero, positive, or negative.
- Session-Reflector Slot Length: A two-octet field that characterizes the Session-Reflector timeslot in microsecond.
- Session-Reflector Slot Y: A two-octet field that characterizes the Session-Reflector timeslot number (Y) for which the Session-Reflector responds the mapping relationship.
- Reflector's Slot Remaining Time: A two-octet field that characterizes the time difference in microsecond between the end of timeslot (X) of Session-Sender and the end of timeslot (Y) of Session-Reflector, where the end of timeslot (X) equals to the time receiving the STAMP packet plus Session-Sender Slot Length and minus time difference (E). This field may be zero, positive, or negative.
- Return Code: A one-octet field that identifies the OPL matching result at the Session-Reflector. It MUST be zeroed by the Session-Sender on transmit and ignored by the Session-Reflector on receipt. The Session-Reflector MUST fill it with values defined as follows.
  - 0x01: TQF instance for the specific OPL is supported
  - 0x02: TQF instance for the specific OPL is not supported
  - All other values are reserved for future use.
- Reserved: A one-octet field that MUST be zeroed on transmission and ignored on receipt.
The STAMP Session-Sender that includes the Timeslot Mapping TLV sets the value of the OPL field based on which the timeslot mapping is queried. Also, the Session-Sender sets the values of the Session-Sender Slot Length field, the Session-Sender Slot X field and the Session-Sender Trans-Deviation E field within the designated orchestration period.
The STAMP Session-Reflector that received the test packet with the Timeslot Mapping TLV MUST include the Timeslot Mapping TLV in the reflected test packet. The Session-Reflector MUST set the values of the OPL, Session-Sender Slot Length, Session-Sender Slot X, and Session-Sender Trans-Deviation E fields equal to the values of the corresponding fields from the test packet it has received. Also, the Session-Reflector MUST set the values of the Session-Reflector Slot Length field, the Session-Reflector Slot Y field, and the Reflector's Slot Remaining Time field within the designated orchestration period. The Session-Reflector Slot Y is determined by the expected time receiving the STAMP packet, which equals to the real time receiving the STAMP packet plus Session-Sender Slot Length and minus time difference E. Besides, the Session-Reflector MUST set the value of the Return Code field to reflect the operational result.
By the received Timeslot Mapping TLV in the reflected test packet, the Session-Sender can acquire the mapping relationship between the timeslot number (X) at the Session-Sender and the timeslot number (Y) at the Session-Reflector, as well as Y's remaining time. In addition, the Session-Sender can figure out the mapping relationship between any other timeslot number (I) at the Session-Sender and the timeslot number (J) at the Session-Reflector, by some calculations on the TLV fields' values. The mathematical formula to derive the timeslot mapping relationship between the Session-Sender's timeslot (I) and the Session-Reflector's timeslot (J) is outside the scope of this document and may refer to [I-D.peng-detnet-packet-timeslot-mechanism].

Orchestration Period Mapping TLV
The Orchestration Period Mapping TLV is an alternative to the Timeslot Mapping TLV, it also enables collection of the mapping relationship of timeslots between the Session-Sender and the Session-Reflector. The difference between the two TLVs is that the Timeslot Mapping TLV is used when the timeslot number (X) is provisioned at the Session-Sender, and the Orchestration Period Mapping TLV is used when the timeslot number (X) is not provisioned at the Session-Sender.

Orchestration Period Mapping TLV

 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|STAMP TLV Flags|   Type=TBD2   |         Length=16             |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|               Orchestration Period Length (OPL)               |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                Session-Sender Trans-Deviation E               |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|   Session-Sender Slot Length  | Session-Reflector Slot Length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Reflector's OP Remaining Time |  Return Code  |   Reserved    |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

The fields are defined as follows:
- STAMP TLV Flags: The STAMP TLV Flags follow the procedures described in [RFC8972].
- Type: Type (value TBD2) for the Orchestration Period Mapping TLV.
- Length: A two-octet field, set equal to the length of the Value field in octets. The length is 16 octets.
- Orchestration Period Length: A four-octet field that characterizes the orchestration period in microsecond at the Session-Sender. The Session-Reflector uses this period as a key to match the Timeslot based Queueing and Forwarding (TQF) scheduling instance.
- Session-Sender Trans-Deviation E: A four-octet field that characterizes the time difference in microsecond between the begin of orchestration period and the time sending the STAMP packet, i.e., E = sending time - OP.begin. This field may be zero, positive, or negative.
- Session-Sender Slot Length: A two-octet field that characterizes the Session-Sender timeslot in microsecond.
- Session-Reflector Slot Length: A two-octet field that characterizes the Session-Reflector timeslot in microsecond.
- Reflector's OP Remaining Time: A two-octet field that characterizes the time difference in microsecond between the end of the orchestration period of Session-Sender and the end of orchestration period of Session-Reflector, where the end of the orchestration period of Session-Sender equal to the time receiving the STAMP packet minus time difference E. This field may be zero, positive, or negative.
- Return Code: A one-octet field that identifies the OPL matching result at the Session-Reflector. It MUST be zeroed by the Session-Sender on transmit and ignored by the Session-Reflector on receipt. The Session-Reflector MUST fill it with values defined as follows.
  - 0x01: TQF instance for the specific OPL is supported
  - 0x02: TQF instance for the specific OPL is not supported
  - All other values are reserved for future use.
- Reserved: A one-octet field that MUST be zeroed on transmission and ignored on receipt.
The STAMP Session-Sender that includes the Orchestration Period Mapping TLV sets the value of the OPL field based on which the timeslot mapping is queried. Also, the Session-Sender sets the values of the Session-Sender Slot Length field and the Session-Sender Trans-Deviation E field within the designated orchestration period.
The STAMP Session-Reflector that received the test packet with the Orchestration Period Mapping TLV MUST include the Orchestration Period Mapping TLV in the reflected test packet. The Session-Reflector MUST set the values of the OPL, Session-Sender Slot Length, and Session-Sender Trans-Deviation E fields equal to the values of the corresponding fields from the test packet it has received. Also, the Session-Reflector MUST set the values of the Session-Reflector Slot Length field and the Reflector's OP Remaining Time field within the designated orchestration period. Besides, the Session-Reflector MUST set the value of the Return Code field to reflect the operational result.
By the received Orchestration Period Mapping TLV in the reflected test packet, the Session-Sender can figure out the mapping relationship between any timeslot number (I) at the Session-Sender and the timeslot number (J) at the Session-Reflector, by some calculations on the TLV fields' values. The mathematical formula to derive the timeslot mapping relationship between the Session-Sender's timeslot (I) and the Session-Reflector's timeslot (J) is outside the scope of this document and may refer to [I-D.peng-detnet-packet-timeslot-mechanism].

Security Considerations
Security issues discussed in [RFC8762], [RFC8972], and [RFC9503] apply to this document.
Basic validation checks can be performed to mitigate the potential attacks, for example, the Orchestration Period Length field of the Timeslot Mapping TLV and the Orchestration Period Mapping TLV is larger than the Session-Sender Slot Length field of the two TLVs in the received STAMP packets at the Session-Reflector.
The usage of STAMP extensions defined in this document is intended for deployment between two neighbouring nodes in a single network administrative domain. As such, the Session-Sender and Session-Reflector can be configured to check the source address while the received STAMP packet carries the extensions defined in this document, and if it's determined the source address doesn't belong to its adjacent nodes, the received STAMP packet MUST be dropped with a notification sent to the network management system.

IANA Considerations
From the "STAMP TLV Types" registry in the "Simple Two-way Active Measurement Protocol (STAMP) TLV Types" namespace, two new values for the Timeslot Mapping TLV and the Orchestration Period Mapping TLV are requested from IANA as follows:

   +=======+=======================================+===========+
   | Value | Description                           | Reference |
   +=======+=======================================+===========+
   | TBD1  | Timeslot Mapping                      |This draft |
   +-------+---------------------------------------+-----------+
   | TBD2  | Orchestration Period Mapping          |This draft |
   +-------+---------------------------------------+-----------+

Acknowledgements
TBD.

Normative References

Informative References
[RFC8578]
[RFC8655]
[I-D.peng-detnet-packet-timeslot-mechanism]
[RFC8762]
[RFC8972]
[RFC2119]
[RFC8174]
[RFC9503]