<?xml version='1.0' encoding='utf-8'?>
<!DOCTYPE rfc [
  <!ENTITY nbsp    "&#160;">
  <!ENTITY zwsp   "&#8203;">
  <!ENTITY nbhy   "&#8209;">
  <!ENTITY wj     "&#8288;">
]>
<?xml-stylesheet type="text/xsl" href="rfc2629.xslt" ?>
<!-- generated by https://github.com/cabo/kramdown-rfc version 1.6.35 (Ruby 3.0.2) -->
<rfc xmlns:xi="http://www.w3.org/2001/XInclude" ipr="trust200902" docName="draft-yu-traffic-shaping-01" category="info" consensus="true" submissionType="IETF" tocInclude="true" sortRefs="true" symRefs="true" version="3">
  <!-- xml2rfc v2v3 conversion 3.17.3 -->
  <front>
    <title abbrev="IPv6 Carries Traffic Shaping Mechanism">Carrying Traffic Shaping Mechanism in IPv6 Extension Header</title>
    <seriesInfo name="Internet-Draft" value="draft-yu-traffic-shaping-01"/>
    <author fullname="Haisheng Yu">
      <organization>China Internet Network Information Center</organization>
      <address>
        <email>yuhaisheng1@gmail.com</email>
      </address>
    </author>

  <author fullname="Kaicheng Zhang">
      <organization>University of Electronic Science and Technology of China</organization>
      <address>
        <email>457642057@qq.com</email>
      </address>
    </author>
    <date year="2026" month="February" day="15"/>
    <keyword>next generation</keyword>
    <keyword>unicorn</keyword>
    <keyword>sparkling distributed ledger</keyword>
    <abstract>
      <?line 43?>

<t>Starting from the traffic shaping mechanism, one of the core technologies of network deterministic assurance, we summarize the characteristics of different traffic scheduling and shaping methods and propose a solution design for IPv6 to carry these traffic scheduling and shaping methods, taking into account deterministic and security factors. At the same time, the network scope of practical applications is becoming larger and larger, and the demand for deterministic network services will no longer be restricted to LANs, but will require deterministic forwarding beyond LAN boundaries, extending the deterministic assurance capability previously provided in LANs to WANs through network layer technologies.</t>
    </abstract>
    <note removeInRFC="true">
      <name>About This Document</name>
      <t>
        The latest revision of this draft can be found at <eref target="https://z-Endeavor.github.io/Internet-Draft/draft-ietf-traffic-shaping.html"/>.
        Status information for this document may be found at <eref target="https://datatracker.ietf.org/doc/draft-ietf-traffic-shaping/"/>.
      </t>
      <t>Source for this draft and an issue tracker can be found at
        <eref target="https://github.com/z-Endeavor/Internet-Draft"/>.</t>
    </note>
  </front>
  <middle>
    <?line 48?>

<section anchor="introduction">
      <name>Introduction</name>
      <t>Time Sensitive Network (TSN) is a network that guarantees the quality of service for delay-sensitive flows, achieving low latency, low jitter and zero packet loss. Time-sensitive streams can be divided into periodic time-sensitive streams (PTS), such as cyclic control instructions in the plant, synchronization information, and non-periodic/sporadic time-sensitive streams (STS), such as event alarm information.</t>
      <t>For periodic time-sensitive flows, traffic synchronous scheduling shaping mechanisms are generally used, requiring precise nanosecond clock synchronization of network-wide devices. Current mechanisms studied include Time-Triggered Ethernet (TTE), Time-Aware Shaping (TAS), Cyclic Queuing and Forwarding (CQF) and Credit-Based Shaping (CBS).</t>
      <t>Scheduling and shaping mechanisms are two quality of service assurance mechanisms in the switch. Scheduling refers to queue scheduling, which is generally implemented at the outgoing port of the switch and consists of three parts: entering the queue, selecting the sending queue according to the scheduling algorithm, and exiting the transmission; shaping refers to traffic shaping, which prevents congestion within the switch or at the next hop by limiting the forwarding rate of the port.</t>
      <t>"IPv6 Hop-by-Hop Options Processing Procedures" <xref target="HbH-UPDT"/> further specifies the procedures for how IPv6 Hop-by-Hop options are processed to make their processing even more practical and increase their use in the Internet. In that context, it makes sense to consider Hop-by-Hop Options to transport the information that is relevant to carry traffic shaping mechanism.</t>
      <t>Since the asynchronous scheduling and shaping mechanism cannot guarantee that the worst delay of the packet meets a certain threshold, it can only guarantee that the average delay of the packet is comparable to the synchronous method, and the delay jitter is relatively large, and the delay-sensitive stream is prone to packet loss in the case of network congestion, the current asynchronous mechanism is not mature, and in order to better elucidate the nature of the delay-sensitive network, this document of using the synchronous mechanism to transmit periodic time-sensitive stream (PTS) is mainly discussed.</t>
      <t>For the traffic shaping mechanism, one of the core technologies of network deterministic assurance, we summarize the characteristics of different traffic scheduling and shaping methods and propose a solution design for IPv6 to carry these traffic scheduling and shaping methods, taking into account deterministic and security factors. At the same time, the network scope of practical applications is becoming larger and larger, and the demand for deterministic network services will no longer be restricted to LANs, but will require deterministic forwarding beyond LAN boundaries, extending the deterministic assurance capability previously provided in LANs to WANs through network layer technologies.</t>
      <t>This document gives a description of the design of the IPv6 carrying traffic shaping mechanism and specifies the technical requirements and security specifications of the IPv6 carrying traffic shaping mechanism. This document applies to deterministic data communication of IPv6 networks that have implemented traffic synchronous scheduling shaping mechanism.</t>
    </section>
    <section anchor="conventions-and-definitions">
      <name>Conventions and Definitions</name>
      <t>The key words "<bcp14>MUST</bcp14>", "<bcp14>MUST NOT</bcp14>", "<bcp14>REQUIRED</bcp14>", "<bcp14>SHALL</bcp14>", "<bcp14>SHALL
NOT</bcp14>", "<bcp14>SHOULD</bcp14>", "<bcp14>SHOULD NOT</bcp14>", "<bcp14>RECOMMENDED</bcp14>", "<bcp14>NOT RECOMMENDED</bcp14>",
"<bcp14>MAY</bcp14>", and "<bcp14>OPTIONAL</bcp14>" in this document are to be interpreted as
described in BCP 14 <xref target="RFC2119"/> <xref target="RFC8174"/> when, and only when, they
appear in all capitals, as shown here.</t>
      <?line -18?>

</section>
    <section anchor="abbreviations-in-this-document">
      <name>Abbreviations in This Document</name>
      <t>TSN    Time Sensitive Network
PTS    Periodic Time-sensitive Streams
TTE    Time-Triggered Ethernet
TAS    Time-Aware Shaping
CQF    Cyclic Queuing and Forwarding
CBS    Credit-Based Shaping</t>
    </section>
    <section anchor="network-communication-system">
      <name>Network Communication System</name>
      <t>Based on the premise of deterministic requirements, this document only considers the design of synchronization schemes where the network uses synchronization mechanisms to transmit PTS, while requiring accurate nanosecond time synchronization of devices within the entire network communication scenario.</t>
      <section anchor="general-model-of-network-transmission">
        <name>General Model of Network Transmission</name>
        <t>An applicable time-sensitive traffic shaping network communication model is given in Figure 1 and illustrates the network elements in it.</t>
      </section>
      <section anchor="network-node-description">
        <name>Network Node Description</name>
        <t>It is expected to be deployed in a variety of IPv6 devices and situations. Therefore, It is important to specify IPv6 node requirements will allow traffic shaping mechanisms to work well and interoperate over IPv6 in a large number of situations and deployments.</t>
      </section>
      <section anchor="network-communication-process">
        <name>Network Communication Process</name>
        <t>Figure 2 gives the communication flow of the network system.</t>
        <ul spacing="normal">
          <li>Collect the corresponding network topology information, traffic period, traffic size, end-to-end delay jitter requirement information and corresponding security requirements from various deterministic services, complete the centralized user configuration, and send it down to the network controller through the network user interface (UNI).</li>
          <li>The network controller receives the network deterministic and security requirements and calculates the route scheduling control information for the traffic according to the corresponding algorithm. If the calculation is successful, the gating list is automatically synthesized and sent down through the southbound interface, and then the packet start time is returned to the sender; if the calculation fails, the orchestrator is told that the sender flow is not available for scheduling.</li>
          <li>Centralized collaborative scheduling of switches to achieve traffic scheduling shaping and complete deterministic transmission by planning routes or dividing time slots, etc.</li>
        </ul>
      </section>
    </section>
    <section anchor="definition-of-carrying-traffic-shaping-mechanism">
      <name>Definition of Carrying Traffic Shaping Mechanism</name>
      <t>Carrying traffic shaping mechanism in IPv6 extension header is in the form of a field on the extended header that specifies the basic traffic scheduling shaping protocol interface options for resolving the semantics of the scheduling shaping mechanism in the packet, allowing the network determinism to be transmitted through the extended header as well as for the adaptation of the upper layer protocols and network functions for use. This field information can be examined and processed by each node of the packet transmission path.</t>
      <t>The requirements for the use of scheduling shaping include the scheduling shaping technical solution options and the control information necessary of specific solution. The definition format consists of four fields, including options, flag bits, fill bit length, and control information. The definition format is shown in Figure 1. The technical scheme here mainly specifies the synchronous scheduling and shaping mechanism option, and the asynchronous scheduling and shaping mechanism information is not transmitted through this design.</t>
      <artwork><![CDATA[
    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
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |Options|F| FBL |                                               |
   +-+-+-+-+-+-+-+-+                                               +
   |                                                               |
   ~             Control Information (variable length)             ~
   |                                                               |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
       Figure 1: Definition of Carrying Traffic Shaping Mechanism
]]></artwork>
      <t>where</t>
      <ul spacing="normal">
        <li>Options: 4-bits. Indicating the synchronous traffic scheduling shaping technology scheme used.</li>
        <li>F: 1-bit. Used as a flag bit to record whether the protocol content has reached its maximum length.</li>
        <li>FBL: 3-bit. The number of bits used to record the padding at the end of the protocol is 0 to 7 bits to ensure that the total length of the definition content is an integer multiple of 8 bits.</li>
        <li>Control Information: Variable length. Used to carry the network control information necessary for the use of a specific scheduling and shaping mechanism, in a format and content determined by the specific scheduling and shaping mechanism.</li>
      </ul>
      <t>The F identifiers is a flag bit. The value of this field specifies:</t>
      <ul spacing="normal">
        <li>0 - the length of the protocol content has not exceeded the maximum value and the information has been read completely.</li>
        <li>1 - the length of the protocol content exceeds the maximum value and needs to be read further.</li>
      </ul>
      <t>FBL indicates Fill Bit Length which is for compatibility with subsequent adaptations in the IPv6 extension header. The actual length of the control information is obtained by parsing the length of the padding bits to facilitate the reading and processing of the network control device. The padding method is to set all the padding bits at the end to 0.</t>
      <t>The Control Information contains standard control frame format of each specific scheduling shaping mechanism, which is used to ensure the integrity of the control information to complete the standard adaptation to various network devices.</t>
    </section>
    <section anchor="specification-in-hop-by-hop-options">
      <name>Specification in Hop-by-Hop Options</name>
      <section anchor="format-in-hop-by-hop-option">
        <name>Format in Hop-by-Hop Option</name>
        <t>The definition of carrying traffic shaping mechanism shall conform to the relevant specifications in <xref target="RFC8200"/> for extended headers. The content in Section 3 should be placed in a Hop-by-Hop option header in the extended header to carry information that will not be inserted or removed and that can be examined or processed by each node in the packet transmission path until the packet reaches the node identified in the destination address field of the IPv6 header(or in the case of multicast, each of a group of nodes).</t>
        <t>The definition populates one or more sub-options of the TLV encoding format into the option field of the hop-by-hop option header, where the TLV encoding format is shown in Figure 2.</t>
        <artwork><![CDATA[
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+- - - - - - - - -
|  Option Type  |  Opt Data Len |  Option Data
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+- - - - - - - - -
          Figure 2: TLV Encoding Format
]]></artwork>
        <t>where</t>
        <ul spacing="normal">
          <li>Option Type: 8-bit identifier of the type of option.</li>
          <li>Opt Data Len: 8-bit unsigned integer. Length of the Option Data field of this option, in octets.</li>
          <li>Option Data: Variable-length field. Option-Type-specific data.</li>
        </ul>
        <t>In the definition above, some specific instructions are required:</t>
        <t>The Option Type identifiers are internally encoded such that their highest-order 2 bits specify the action that must be taken if the processing IPv6 node does not recognize the Option Type. Actions are selected by the controller in the network, refer to <xref target="RFC8200"/> for specific action definitions.</t>
        <t>The third-highest-order bit of the Option Type specifies whether or not the Option Data of that option can change en route to the packet’s final destination. The option data is changed during packet forwarding with traffice shaping information so that this bit needs to be set to 1.</t>
        <t>The low-order 5 bits of the Option Type should not conflict with the Option Type field already defined by IPv6.</t>
        <t>Option Data is used to carry the definition content of Section 3.</t>
        <t>In addition, the length of the protocol defined in Section 3 exceeds the maximum length of an option, the F identifiers should be set to 1 and the protocol will continue to be stored in the next option. The protocol content in Section 3 is split into at most two options.</t>
      </section>
      <section anchor="hop-by-hop-processing-definition">
        <name>Hop-by-Hop processing definition</name>
        <t>HBH Processing draft should define the HBH processing.</t>
      </section>
    </section>
    <section anchor="security-considerations">
      <name>Security Considerations</name>
      <t>Security issues with IPv6 Hop-by-Hop options are well known and have been documented in several places, including <xref target="RFC6398"/>, <xref target="RFC6192"/>, and <xref target="RFC9098"/>. Security Considerations in IPv6 are composed of a number of different pieces. These are mainly required to provide the three characteristics of replay protection, integrity and confidentiality.</t>
      <section anchor="replay-protection">
        <name>Replay Protection</name>
        <t>Replay Protection requires ensuring the uniqueness of each IP packet to ensure that the information cannot be reused in the event that it is intercepted and copied.</t>
        <ul spacing="normal">
          <li>It should be ensured that access cannot be regained using the same packets to prevent attackers from intercepting deciphered information and then impersonating illegal access.</li>
          <li>A secret key based on algorithm independent exchange should be set at the host side by the customer and the service provider, and when each packet is transmitted, a checksum is generated based on the secret key and the packet, and the checksum is recalculated and compared at the data receiving side.</li>
          <li>Authentication data should be included in the transmission to protect the fields that cannot be changed during IP packet transmission.</li>
          <li>The cache data should be cleared and guaranteed to be unrecoverable.</li>
        </ul>
      </section>
      <section anchor="integrity">
        <name>Integrity</name>
        <t>Integrity of data is to prevent data from being tampered with during transmission and to ensure that the outgoing and incoming data are identical.</t>
        <ul spacing="normal">
          <li>Two-way authentication mechanism for shared data information components should be provided.</li>
          <li>Encrypted transmission channels should be used to prevent data from being eavesdropped during network transmission.</li>
          <li>Should have the ability to test the integrity of the data and provide the corresponding recovery control measures.</li>
        </ul>
      </section>
      <section anchor="confidentiality">
        <name>Confidentiality</name>
        <t>Confidentiality is used to prevent attackers from accessing packet headers or content, ensuring that information cannot be read during transmission, even if IP packets are intercepted.</t>
        <ul spacing="normal">
          <li>Encryption policy of terminal data should be established to ensure the confidentiality of sensitive data output and shared at the terminal.</li>
          <li>A cryptographic checksum should be generated for each packet, and the receiver should calculate the checksum before opening the packet; if the packet is tampered with and the checksum does not match, the packet is discarded.</li>
        </ul>
      </section>
    </section>
    <section anchor="iana-considerations">
      <name>IANA Considerations</name>
      <t>This document has no IANA actions.</t>
    </section>
  </middle>
  <back>
    <references>
      <name>References</name>
      <references>
        <name>Normative References</name>
        <reference anchor="RFC2119">
          <front>
            <title>Key words for use in RFCs to Indicate Requirement Levels</title>
            <author fullname="S. Bradner" initials="S." surname="Bradner"/>
            <date month="March" year="1997"/>
            <abstract>
              <t>In many standards track documents several words are used to signify the requirements in the specification.  These words are often capitalized.  This document defines these words as they should be interpreted in IETF documents.  This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
            </abstract>
          </front>
          <seriesInfo name="BCP" value="14"/>
          <seriesInfo name="RFC" value="2119"/>
          <seriesInfo name="DOI" value="10.17487/RFC2119"/>
        </reference>
        <reference anchor="RFC8174">
          <front>
            <title>Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words</title>
            <author fullname="B. Leiba" initials="B." surname="Leiba"/>
            <date month="May" year="2017"/>
            <abstract>
              <t>RFC 2119 specifies common key words that may be used in protocol specifications.  This document aims to reduce the ambiguity by clarifying that only UPPERCASE usage of the key words have the defined special meanings.</t>
            </abstract>
          </front>
          <seriesInfo name="BCP" value="14"/>
          <seriesInfo name="RFC" value="8174"/>
          <seriesInfo name="DOI" value="10.17487/RFC8174"/>
        </reference>
        <reference anchor="HbH-UPDT">
          <front>
            <title>IPv6 Hop-by-Hop Options Processing Procedures</title>
            <author fullname="Bob Hinden" initials="R. M." surname="Hinden">
              <organization>Check Point Software</organization>
            </author>
            <author fullname="Gorry Fairhurst" initials="G." surname="Fairhurst">
              <organization>University of Aberdeen</organization>
            </author>
            <date day="2" month="June" year="2021"/>
            <abstract>
              <t>   This document specifies procedures for how IPv6 Hop-by-Hop options
   are processed.  It modifies the procedures specified in the IPv6
   Protocol Specification (RFC8200) to make processing of IPv6 Hop-by-
   Hop options practical with the goal of making IPv6 Hop-by-Hop options
   useful to deploy and use in the Internet.  When published, this
   document updates RFC8200.

              </t>
            </abstract>
          </front>
          <seriesInfo name="Internet-Draft" value="draft-hinden-6man-hbh-processing-01"/>
        </reference>
        <reference anchor="RFC8200">
          <front>
            <title>Internet Protocol, Version 6 (IPv6) Specification</title>
            <author fullname="S. Deering" initials="S." surname="Deering"/>
            <author fullname="R. Hinden" initials="R." surname="Hinden"/>
            <date month="July" year="2017"/>
            <abstract>
              <t>This document specifies version 6 of the Internet Protocol (IPv6).  It obsoletes RFC 2460.</t>
            </abstract>
          </front>
          <seriesInfo name="STD" value="86"/>
          <seriesInfo name="RFC" value="8200"/>
          <seriesInfo name="DOI" value="10.17487/RFC8200"/>
        </reference>
      </references>
      <references>
        <name>Informative References</name>
        <reference anchor="RFC5409">
          <front>
            <title>Using the Boneh-Franklin and Boneh-Boyen Identity-Based Encryption Algorithms with the Cryptographic Message Syntax (CMS)</title>
            <author fullname="L. Martin" initials="L." surname="Martin"/>
            <author fullname="M. Schertler" initials="M." surname="Schertler"/>
            <date month="January" year="2009"/>
            <abstract>
              <t>This document describes the conventions for using the Boneh-Franklin (BF) and Boneh-Boyen (BB1) identity-based encryption algorithms in the Cryptographic Message Syntax (CMS) to encrypt content-encryption keys.  Object identifiers and the convention for encoding a recipient's identity are also defined.  This memo provides information for the Internet community.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="5409"/>
          <seriesInfo name="DOI" value="10.17487/RFC5409"/>
        </reference>
        <reference anchor="RFC6398">
          <front>
            <title>IP Router Alert Considerations and Usage</title>
            <author fullname="F. Le Faucheur" initials="F." role="editor" surname="Le Faucheur"/>
            <date month="October" year="2011"/>
            <abstract>
              <t>The IP Router Alert Option is an IP option that alerts transit routers to more closely examine the contents of an IP packet.  The Resource reSerVation Protocol (RSVP), Pragmatic General Multicast (PGM), the Internet Group Management Protocol (IGMP), Multicast Listener Discovery (MLD), Multicast Router Discovery (MRD), and General Internet Signaling Transport (GIST) are some of the protocols that make use of the IP Router Alert Option.  This document discusses security aspects and usage guidelines around the use of the current IP Router Alert Option, thereby updating RFC 2113 and RFC 2711.  Specifically, it provides recommendations against using the Router Alert in the end-to-end open Internet and identifies controlled environments where protocols depending on Router Alert can be used safely.  It also provides recommendations about protection approaches for service providers.  Finally, it provides brief guidelines for Router Alert implementation on routers.  This memo documents an Internet Best Current Practice.</t>
            </abstract>
          </front>
          <seriesInfo name="BCP" value="168"/>
          <seriesInfo name="RFC" value="6398"/>
          <seriesInfo name="DOI" value="10.17487/RFC6398"/>
        </reference>
        <reference anchor="RFC6192">
          <front>
            <title>Protecting the Router Control Plane</title>
            <author fullname="D. Dugal" initials="D." surname="Dugal"/>
            <author fullname="C. Pignataro" initials="C." surname="Pignataro"/>
            <author fullname="R. Dunn" initials="R." surname="Dunn"/>
            <date month="March" year="2011"/>
            <abstract>
              <t>This memo provides a method for protecting a router's control plane from undesired or malicious traffic. In this approach, all legitimate router control plane traffic is identified. Once legitimate traffic has been identified, a filter is deployed in the router's forwarding plane. That filter prevents traffic not specifically identified as legitimate from reaching the router's control plane, or rate-limits such traffic to an acceptable level.</t>
              <t>Note that the filters described in this memo are applied only to traffic that is destined for the router, and not to all traffic that is passing through the router. This document is not an Internet Standards Track specification; it is published for informational purposes.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="6192"/>
          <seriesInfo name="DOI" value="10.17487/RFC6192"/>
        </reference>
        <reference anchor="RFC9098">
          <front>
            <title>Operational Implications of IPv6 Packets with Extension Headers</title>
            <author fullname="F. Gont" initials="F." surname="Gont"/>
            <author fullname="N. Hilliard" initials="N." surname="Hilliard"/>
            <author fullname="G. Doering" initials="G." surname="Doering"/>
            <author fullname="W. Kumari" initials="W." surname="Kumari"/>
            <author fullname="G. Huston" initials="G." surname="Huston"/>
            <author fullname="W. Liu" initials="W." surname="Liu"/>
            <date month="September" year="2021"/>
            <abstract>
              <t>This document summarizes the operational implications of IPv6 extension headers specified in the IPv6 protocol specification (RFC 8200) and attempts to analyze reasons why packets with IPv6 extension headers are often dropped in the public Internet.</t>
            </abstract>
          </front>
          <seriesInfo name="RFC" value="9098"/>
          <seriesInfo name="DOI" value="10.17487/RFC9098"/>
        </reference>
      </references>
    </references>
    <?line 233?>

<section numbered="false" anchor="acknowledgments">
      <name>Acknowledgments</name>
      <t>TODO acknowledge.</t>
    </section>
  </back>
  

</rfc>
