<?xml version="1.0" encoding="US-ASCII"?>
<?xml-stylesheet type="text/xsl" href="rfc2629.xslt" ?>
<!-- generated by https://github.com/cabo/kramdown-rfc2629 version 1.2.6 -->
<!DOCTYPE rfc SYSTEM "rfc2629.dtd">
<?rfc toc="yes"?>
<?rfc sortrefs="yes"?>
<?rfc symrefs="yes"?>
<?rfc comments="yes"?>
<rfc category="std" docName="draft-chen-idr-bgp-sr-policy-cp-validity-04"
     ipr="trust200902">
  <front>
   <title abbrev="Validity of SR Policy Candidate Path">Validity of SR Policy Candidate Path</title>
   <author fullname="Ran Chen" initials="R." surname="Chen">
      <organization>ZTE Corporation</organization>
      <address>
        <postal>
          <street/>
          <!-- Reorder these if your country does things differently -->

         <city>Nanjing</city>
          <region/>
          <code/>
          <country>China</country>
        </postal>
        <email>chen.ran@zte.com.cn</email>
        <!-- uri and facsimile elements may also be added -->
     </address>
    </author>

	 <author fullname="Detao Zhao" initials="D." surname="Zhao">
      <organization>ZTE Corporation</organization>
      <address>
        <postal>
          <street/>
          <!-- Reorder these if your country does things differently -->

         <city>Nanjing</city>
          <region/>
          <code/>
          <country>China</country>
        </postal>
        <email>zhao.detao@zte.com.cn</email>
        <!-- uri and facsimile elements may also be added -->
     </address>
    </author>
	 <author fullname="Ketan Talaulikar" initials="K." surname="Talaulikar">
       <organization>Cisco Systems, Inc.</organization>
      <address>
        <email>ketant.ietf@gmail.com</email>
        <!-- uri and facsimile elements may also be added -->
     </address>
    </author>
	
	 <author fullname="Yisong Liu" initials="Y." surname="Liu">
      <organization>China Mobile</organization>
      <address>
        <postal>
          <street/>
          <!-- Reorder these if your country does things differently -->

         <city>Beijing</city>
          <region/>
          <code/>
          <country>China</country>
        </postal>
        <email>liuyisong@chinamobile.com</email>
        <!-- uri and facsimile elements may also be added -->
     </address>
    </author>
	
	 <author fullname="Changwang Lin" initials="L." surname="Changwang">
      <organization>New H3C Technologies</organization>
      <address>
        <postal>
          <street/>
          <!-- Reorder these if your country does things differently -->
         <city>Beijing</city>
          <region/>
          <code/>
          <country>China</country>
        </postal>
        <email>linchangwang.04414@h3c.com</email>
        <!-- uri and facsimile elements may also be added -->
     </address>
    </author>
    <date year="2025"/>
    <!-- If the month and year are both specified and are the current ones, xml2rfc will fill 
        in the current day for you. If only the current year is specified, xml2rfc will fill 
	 in the current day and month for you. If the year is not the current one, it is 
	 necessary to specify at least a month (xml2rfc assumes day="1" if not specified for the 
	 purpose of calculating the expiry date).  With drafts it is normally sufficient to 
	 specify just the year. -->

   <!-- Meta-data Declarations -->

   <area>Routing</area>
    <workgroup>Inter-Domain Routing</workgroup>
    <!-- WG name at the upperleft corner of the doc,
        IETF is fine for individual submissions.  
	 If this element is not present, the default is "Network Working Group",
        which is used by the RFC Editor as a nod to the history of the IETF. -->

   <keyword>Internet Draft</keyword>
    <!-- Keywords will be incorporated into HTML output
        files in a meta tag but they have no effect on text or nroff
        output. If you submit your draft to the RFC Editor, the
        keywords will be used for the search engine. -->
   
   <abstract>
	  <t>This document defines extensions to BGP to distribute the validity control parameters of a candidate path for an SR Policy.</t>
    </abstract>
  </front>
  <middle>
  
    <section numbered="true" toc="default">
      <name>Introduction</name>
	 <t>SR Policy architecture is specified in <xref target="RFC9256" format="default"></xref>. An SR Policy comprises one or more candidate paths(CP) of which at a given time one and only one may be active (i.e., installed in forwarding and usable for steering of traffic). Each CP in turn may have one or more SID-List of which one or more may be active; when multiple SID-List are active then traffic is load balanced over them.</t>
     <t><xref target="I-D.chen-spring-sr-policy-cp-validity"/> supplemented candidate path validity criterion in <xref target="RFC9256" format="default"></xref>. It defines two validity control parameters under candidate Path to control the validity judgment of candidate Path.</t>
	 <t>This document defines extensions to BGP to distribute the validity control parameters of a candidate path for an SR Policy.</t>
	   <section title="Requirements Language">
        <t>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 <xref target="RFC2119"/> <xref target="RFC8174"/> when, and only
        when, they appear in all capitals, as shown here.</t>
      </section>
	   </section>
   <section numbered="true" toc="default">
   <name>Carrying CP Validity Sub-TLV in BGP</name>
    <t>As defined in <xref target="I-D.ietf-idr-sr-policy-safi" format="default"/>, a new SAFI is defined (the SR Policy SAFI with codepoint 73) as well as a new NLRI. The NLRI contains the SR Policy candidate path and, according to <xref target="I-D.ietf-idr-sr-policy-safi" format="default"/>, the content of the SR Policy Candidate Path is encoded in the Tunnel Encapsulation Attribute defined in <xref target="RFC9012" format="default"></xref> using a new Tunnel-Type called SR Policy Type with codepoint 15. This document defines CP Validity Sub-TLV to carry the validity control parameters of a candidate path.</t>
	<t>The new SR Policy encoding structure with CP Validity Sub-TLV is expressed as below:</t>
		<artwork><![CDATA[
   SR Policy SAFI NLRI: <Distinguisher, Policy-Color, Endpoint>
      Attributes:
         Tunnel Encaps Attribute (23)
            Tunnel Type: SR Policy (15)
                Binding SID
                SRv6 Binding SID
                Preference
                Priority
                Policy Name
                Policy Candidate Path Name
                Explicit NULL Label Policy (ENLP)
                CP Validity 
                Segment List
                    Weight
                    Segment
                    Segment
                    ...
                ...
		    ]]></artwork>     
   </section>
    <section numbered="true" toc="default">
   <name>CP Validity Sub-TLV</name>
   <t>The format of the CP Validity Sub-TLV is defined as follows:</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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|    Type       |    Length     | valid SL count|    Reserved   |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                     valid SL weight                           |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
             Figure 1: CP Validity Sub-TLV
           ]]></artwork>
	  <t>where:</t>
	  <t>Type: to be assigned by IANA.</t>
	  <t>Length: the total length of the value field not including Type and Length fields. The total length MUST be 6.</t>
	  <t>valid SL count: 1-octet field which indicates the minimum number of valid segment Lists under the active candidate path. When the number of valid segment Lists under candidate path is greater than or equal to this field, the candidate path is considered valid. 0 indicates no requirement for SL count.
	  0xff indicates that the candidate path is considered valid only if all the segment Lists are valid.</t>
	  <t>valid SL weight: 4-octet field which indicates the minimum value of the sum of the weights of the valid segment List under the active candidate Path. When the sum of the weights of the valid segment Lists under the candidate path is greater than or equal to this field, the candidate Path is considered valid. 0 indicates no requirement for weight.0xffffffff indicates that the candidate path is considered valid only if all the segment Lists are valid.</t>
    </section>
	
     <section numbered="true" toc="default">
      <name>Operations</name>
	 <t>The document does not bring new operation beyond the description of operations defined in <xref target="I-D.ietf-idr-sr-policy-safi" format="default"/>.  The existing operations defined in <xref target="I-D.ietf-idr-sr-policy-safi" format="default"/> can apply to this document directly.</t>
     <t>Typically, but not limit to, the SR policies carrying the validity control parameters of the candidate path are configured by a controller.</t>
	 <t>After configuration, the SR policies carrying the validity control parameters of the candidate path will be advertised by BGP update messages. The operation of advertisement is the same as defined in <xref target="I-D.ietf-idr-sr-policy-safi" format="default"/>, as well as the reception.</t>
	   </section>
    
   <section anchor="IANA" numbered="true" toc="default">
      <name>IANA Considerations</name>
	  <t>This document defines a new sub-TLV in the registry "BGP Tunnel Encapsulation Attribute sub-TLVs" to be assigned by IANA:</t>
		<artwork><![CDATA[
   Value   Description               Reference
  ------- ------------------------- --------------
    TBD    CP Validity Sub-TLV       This document

		    ]]></artwork>    
	 </section>
	 
	 <section anchor="Security" numbered="true" toc="default">
      <name>Security Considerations</name>
     <t>The security considerations of BGP <xref target="RFC4271" format="default"></xref> and BGP SR policy <xref target="I-D.ietf-idr-sr-policy-safi" format="default"/> apply to the extensions described in this document as well. It does not introduce additional security issues compared to existing SR policy extensions. The CP Validity information is critical to determining the validity of the CP, and a wrong CP Validity information may cause unexpected forwarding actions and results.</t>
	 <t>Implementations need to make sure that the CP Validity information is correct to avoid unexpected forwarding actions and results. Additionally, the distribution of CP validity information from the controller to the ingress router needs to be protected. The security considereations in <xref target="I-D.ietf-idr-sr-policy-safi" format="default"/> apply to this distribution procedure.</t>
    </section>
	 
	  <section anchor="Acknowledgements" numbered="true" toc="default">
      <name>Acknowledgements</name>
      <t>TBD.</t>
    </section>
    <!-- Possibly a 'Contributors' section ... -->
  </middle>
  <!--  *****BACK MATTER ***** -->

 <back>
    <!-- References split into informative and normative -->

   <!-- There are 2 ways to insert reference entries from the citation libraries:
    1. define an ENTITY at the top, and use "ampersand character"RFC2629; here (as shown)
    2. simply use a PI "less than character"?rfc include="reference.RFC.2119.xml"?> here
       (for I-Ds: include="reference.I-D.narten-iana-considerations-rfc2434bis.xml")

    Both are cited textually in the same manner: by using xref elements.
    If you use the PI option, xml2rfc will, by default, try to find included files in the same
    directory as the including file. You can also define the XML_LIBRARY environment variable
    with a value containing a set of directories to search.  These can be either in the local
    filing system or remote ones accessed by http (http://domain/dir/... ).-->

  <references title="Normative References">
        <!--?rfc include="http://xml.resource.org/public/rfc/bibxml/reference.RFC.2119.xml"?-->
      <?rfc include='reference.RFC.2119'?>
	  <?rfc include='reference.RFC.4271'?>
	  <?rfc include='reference.RFC.9256'?>
	  <?rfc include='reference.RFC.8174'?>
	  <?rfc include='reference.RFC.9012'?>
	  <?rfc include='reference.I-D.chen-spring-sr-policy-cp-validity'?>
	  <?rfc include='reference.I-D.ietf-idr-sr-policy-safi'?>
      </references>
       
    <!-- Change Log

v00 2006-03-15  EBD   Initial version

v01 2006-04-03  EBD   Moved PI location back to position 1 -
                     v3.1 of XMLmind is better with them at this location.
v02 2007-03-07  AH    removed extraneous nested_list attribute,
                     other minor corrections
v03 2007-03-09  EBD   Added comments on null IANA sections and fixed heading capitalization.
                     Modified comments around figure to reflect non-implementation of
                     figure indent control.  Put in reference using anchor="DOMINATION".
                     Fixed up the date specification comments to reflect current truth.
v04 2007-03-09 AH     Major changes: shortened discussion of PIs,
                     added discussion of rfc include.
v05 2007-03-10 EBD    Added preamble to C program example to tell about ABNF and alternative 
                     images. Removed meta-characters from comments (causes problems).

v06 2010-04-01 TT     Changed ipr attribute values to latest ones. Changed date to
                     year only, to be consistent with the comments. Updated the 
                     IANA guidelines reference from the I-D to the finished RFC.
v07 2020-01-21 HL    Converted the template to use XML schema version 3.
    -->
 </back>
</rfc>
