<?xml version="1.0" encoding="US-ASCII"?>
<!DOCTYPE rfc SYSTEM "rfc2629.dtd">
<?rfc toc="yes"?>
<?rfc tocompact="yes"?>
<?rfc tocdepth="3"?>
<?rfc tocindent="yes"?>
<?rfc symrefs="yes"?>
<?rfc sortrefs="yes"?>
<?rfc comments="yes"?>
<?rfc inline="yes"?>
<?rfc compact="yes"?>
<?rfc subcompact="no"?>
<rfc category="std"
     docName="draft-chen-spring-srmpls-frr-ex-01"
     ipr="trust200902">
  <front>
    <title abbrev="SRMPLS FRR Extension">SR-MPLS FRR Extension</title>
 


     <author initials="H" surname="Chen" fullname="Huaimo Chen">
      <organization>Futurewei</organization>
      <address>
        <postal>
          <street></street>
          <city>Boston, MA</city>
          <region></region>
          <code></code>
          <country>USA</country>
        </postal>
        <email>Huaimo.chen@futurewei.com</email>
      </address>
    </author>

   <author fullname="Zhibo Hu" initials="Z. " surname="Hu">
      <organization>Huawei Technologies</organization>
      <address>
        <postal>
          <street>Huawei Bld., No.156 Beiqing Rd.</street>
          <city>Beijing</city>
          <code>100095</code>
          <country>China</country>
        </postal>
        <email>huzhibo@huawei.com</email>
      </address>
    </author>
<!--
    <author fullname="Chris Bowers" initials="C. " surname="Bowers">
      <organization>Juniper Networks</organization>
      <address>
        <postal>
          <street>1194 N. Mathilda Ave.</street>
          <city>Sunnyvale, CA</city>
          <code>94089</code>
          <country>USA</country>
        </postal>
        <email>cbowers@juniper.net</email>
      </address>
    </author>

    <author fullname="Yongqing" initials="Y. " surname="Zhu">
      <organization>China Telecom</organization>
      <address>
        <postal>
          <street>109, West Zhongshan Road, Tianhe District</street>
          <city>Guangzhou</city>
          <code>510000</code>
          <country>China</country>
        </postal>
        <email>zhuyq8@chinatelecom.cn</email>
      </address>
    </author>
-->
  <author initials="A" fullname="Aijun Wang" surname="Wang">
   <organization>China Telecom</organization>
   <address>
    <postal>
     <street>Beiqijia Town, Changping District</street>
     <city>Beijing</city>
     <region />
     <code>102209</code>
     <country>China</country>
    </postal>
    <email>wangaj3@chinatelecom.cn</email>
   </address>
  </author>
	
	<author fullname="Yisong" initials="Y. " surname="Liu">
      <organization>China Mobile</organization>
      <address>
        <postal>
          <street></street>
          <city></city>
          <code>510000</code>
          <country>China</country>
        </postal>
        <email>liuyisong@chinamobile.com</email>
      </address>
    </author>
	
  <author fullname="Gyan S. Mishra" initials="G" surname="Mishra">
   <organization>Verizon Inc.</organization>
   <address>
    <postal>
     <street>13101 Columbia Pike</street>
     <city>Silver Spring</city>
     <code>MD 20904</code>
     <country>USA</country>
    </postal>
    <phone>301 502-1347</phone>
    <email>gyan.s.mishra@verizon.com</email>
   </address>
  </author>

    <date year="2023"/>

    <abstract>
      <t>
	  The current SR FRR such as TI-LFA provides fast re-route protection
          for the failure of a node on an SR-MPLS path by the neighbor
          upstream node as point of local repair (PLR) of the failed node.
 
	  However, once the IGP converges,
	  the SR FRR is no longer sufficient to forward traffic of the path 
          around the failure, since the non-neighbor upstream node
	  of the failed node will no longer have a route to the failed node.

	  This document describes a simple mechanism to extend the 
          fast re-route protection 
          for the failure on an SR-MPLS path after the IGP converges.

          The mechanism protects the node SID, adjacency SID and 
          binding SID of the failed node on the path.
      </t>

      <t/>
    </abstract>

    <note title="Requirements Language">
      <t>The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
      "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
      document are to be interpreted as described in <xref
      target="RFC2119"/> <xref target="RFC8174"/>
      when, and only when, they appear in all capitals, as shown here.</t>
    </note>
  </front>

  <middle>
    <section title="Introduction">
      <t><xref target="I-D.ietf-rtgwg-segment-routing-ti-lfa"/> describes 
	  an SR FRR mechanism that provides fast re-route protection for
 	  the failure of a node on an SR-TE path by the neighbor
          upstream node as point of local repair (PLR) of the failed node.
 
	  However, once the IGP converges,
	  the SR FRR is no longer sufficient to forward traffic of the path 
          around the failure, since the non-neighbor upstream node
	  of the failed node will no longer have a route to the failed 
          node and drop the traffic.</t>

       <t> 
          <xref target="I-D.ietf-spring-segment-protection-sr-te-paths"/> 
          proposes a solution in which
          a hold-down timer is configured on every node in a network.
          After the IGP converges on a node failure, 
          when a node is going to delete the route to the failed node, 
          instead of programming a route delete, 
          it programs a tunnel/path to the node
          consisting of the Node SID of the
          nearside neighbor of the failed node
          followed by the original path in the packet.
          The modified path
          will be in force until the hold-down timer expires.

        <!-- This solution seems complex. -->
       </t>
	  
       <t>
	  This document describes
          a simple mechanism to extend the fast re-route protection 
          for the failure on an SR-MPLS path after the IGP converges.
          The mechanism protects the node SID, adjacency SID and 
          binding SID of the failed node on the path.</t>
    </section>

    <section title="Example SR-MPLS FRR Extension">  
       <t>This section illustrates the extension to SR-MPLS FRR
          for the failure on SR-MPLS paths after the IGP converges
          through examples.

          It shows the procedure on every related node on each path
          without any failure, with a failure  
          before and after the IGP converges on the failure.</t>

        <t><xref target="topo-w-sr-path"/> shows an example topology
          with two SR-MPLS paths: Path 1 and Path 2 for explaining the
          extension. They go through the same nodes and links, but
          represented differently. The former does not have any 
          binding SID (BSID).
          The latter has a BSID of node N (BSID-N).

         <figure
            anchor="topo-w-sr-path"
            title="Example Topology with SR-MPLS Paths">
            <artwork><![CDATA[
               [ P1 ]-----[ P3 ]-----[ N  ]-----[ Q1 ]   
              /  |   \   /  |   \   /  |   \   /  |   \    
             /   |    \ /   |    \ /   |    \ /   |    \   
[CE1]------[A]   |     X    |     X    |     X    |    [C]-----[CE2]
             \   |    / \   |    / \   |    / \   |    /   
              \  |   /   \  |   /   \  |   /   \  |   /    
               [ P2 ]-----[ P4 ]-----[ N1 ]-----[ Q2 ]   

Path 1:A->P1->N->Q1->C, indicated at A by {SID-P1,SID-N,SID-Q1,SID-C}
Path 2:A->P1->N->Q1->C, indicated at A by {SID-P1,SID-N,BSID-N} and
                       BSID-N associated with SID list {SID-Q1,SID-C}
]]></artwork>
          </figure>  
        SR-MPLS Path 1: A->P1->N->Q1->C  
        is indicated at node A by node SID of P1 (SID-P1), node SID of N (SID-N),
        node SID of Q1 (SID-Q1) and node SID of C (SID-C). 
        SR-MPLS Path 2
        is indicated at node A by {SID-P1,SID-N,BSID-N}, 
        where BSID-N (binding SID of N)
        is associated with SID list {SID-Q1,SID-C}.
       </t>

      <section anchor="path-with-no-bsid"  
               title="SR-MPLS Path with no BSID">

      <section anchor="no-bsid-without-failure"  
               title="Without any Failure">
       <t><xref target="sr-path-no-failure"/> shows the 
          result of executing procedure on each related node 
          of SR-MPLS path 1 without any failure. 

         <figure
            anchor="sr-path-no-failure"
            title="No BSID Without any Failure">
            <artwork><![CDATA[
     1.{SID-P1,SID-N,SID-Q1,SID-C}Pkt 
            |  2.{SID-N,SID-Q1,SID-C}Pkt 
            |         |   3.{SID-N,SID-Q1,SID-C}Pkt
            |         |          |   4.{SID-Q1,SID-C}Pkt
            |         |          |          | 
            |         v          v          v
            |  [ P1 ]-----[ P3 ]-----[ N  ]-----[ Q1 ]   
            v /  |   \   /  |   \   /  |   \   /  |   \5.{SID-C}Pkt    
     Pkt     /   |    \ /   |    \ /   |    \ /   |    \   
[CE1]------[A]   |     X    |     X    |     X    |    [C]-----[CE2]
             \   |    / \   |    / \   |    / \   |    /   6.Pkt
              \  |   /   \  |   /   \  |   /   \  |   /
               [ P2 ]-----[ P4 ]-----[ N1 ]-----[ Q2 ]  

Path 1:A->P1->N->Q1->C, indicated at A by {SID-P1,SID-N,SID-Q1,SID-C}
]]></artwork>
          </figure>  

          The results from nodes A, P1, P3, N, Q1 and C 
          are as follows.

          <list style="hanging" hangIndent="4">
            <t hangText="1.">
               Node A as the ingress of the path adds 
               SID-P1, SID-N, SID-Q1, and SID-C 
               into a packet (Pkt) received from CE1 and sends the packet 
               with the SIDs to node P1. 
               The packet sent to P1 is represented by
               "1.{SID-P1,SID-N,SID-Q1,SID-C}Pkt".
            </t>

            <t hangText="2.">
               Node P1 pops its SID-P1 from the packet received,
               sends the packet with top SID (SID-N) to P3 
               along the IGP shortest path to N 
               according to its FIB entry for SID-N.
               The packet sent to P3 is represented by
               "2.{SID-N,SID-Q1,SID-C}Pkt".
            </t>

            <t hangText="3.">
               Node P3 sends the packet with top SID (SID-N) to N
               along the IGP shortest path to N.
               The packet sent to N is represented by
               "3.{SID-N,SID-Q1,SID-C}Pkt".
            </t>

            <t hangText="4.">
               Node N pops its SID-N from the packet received,
               sends the packet with top SID (SID-Q1) to Q1 
               along the IGP shortest path to Q1 
               according to its FIB entry for SID-Q1.
               The packet sent to Q1 is represented by
               "4.{SID-Q1,SID-C}Pkt".
            </t>

            <t hangText="5.">
               Node Q1 pops its SID-Q1 from the packet received,
               sends the packet with top SID (SID-C) to C 
               along the IGP shortest path to C.
               The packet sent to C is represented by
               "5.{SID-C}Pkt".
            </t>

            <t hangText="6.">
               Node C pops its SID-C and gets the packet without any SIDs, 
               which is represented by
               "6.Pkt".
            </t>
          </list>
        </t>
      </section>

      <section anchor="no-bsid-before-convergence"  
               title="Before IGP Converges on Failure">
       <t><xref target="sr-path-n-fail-1"/> shows the 
          result of executing procedure on each related node 
          of SR-MPLS path 1 with no BSID
          when node N failed and 
          before the IGP converges on the failure. 

         <figure
            anchor="sr-path-n-fail-1"
            title="Path with no BSID when N failed and before IGP converges">
            <artwork><![CDATA[
 1.{SID-P1,SID-N,SID-Q1,SID-C}Pkt 
            | 
            |     2.{SID-N,SID-Q1,SID-C}Pkt 
            |         |
            |         v                
            |  [ P1 ]-----[ P3 ]     [ N  ]     [ Q1 ]   
            v /  |   \   /  |   \3.{SID-Q1,    /  |   \5.{SID-C}Pkt    
     Pkt     /   |    \ /   |    \  SID-C}Pkt /   |    \   
[CE1]------[A]   |     X    |     X    |     X    |    [C]-----[CE2]
             \   |    / \   |    / \   |    / \   |    /   6.Pkt
              \  |   /   \  |   /   \  |   /4.{SID-Q1,SID-C}Pkt
               [ P2 ]-----[ P4 ]-----[ N1 ]-----[ Q2 ]  

Path 1:A->P1->N->Q1->C, indicated at A by {SID-P1,SID-N,SID-Q1,SID-C}
]]></artwork>
          </figure>  

          The results from nodes A, P1, Q1 and C are the same as
          those described in <xref target="no-bsid-without-failure"/>.

          The results from neighbor upstream node P3 of N and node N1
          are as follows.

          <list style="hanging" hangIndent="4">
            <t hangText="3.">After detecting the failure of N,
               the neighbor upstream node P3 of N pops SID-N 
               from the packet received,
               re-routes the packet to node Q1 via node N1 without
               going through failed N.
               The packet sent to N1 is represented by
              "3.{SID-Q1,SID-C}Pkt".
            </t>
            <t hangText="4.">Node N1 
               sends the packet to Q1 according to the top SID (SID-Q1) 
               in the packet.
               The packet sent to Q1 is represented by
              "4.{SID-Q1,SID-C}Pkt".
            </t>
          </list>
        </t>
      </section> 

      <section anchor="no-bsid-after-convergence"  
               title="After IGP Converges on Failure">
       <t><xref target="sr-path-n-fail-2"/> shows the 
          result of executing procedure on each related node 
          on SR-MPLS path 1 with no BSID
          when node N failed and 
          after the IGP converges on the failure. 

         <figure
            anchor="sr-path-n-fail-2"
            title="Path with no BSID when N failed and after IGP converges">
            <artwork><![CDATA[
            1.{SID-P1,SID-N,SID-Q1,SID-C}Pkt 
            |     
            |  [ P1 ]-----[ P3 ]     [ N  ]     [ Q1 ]   
            v /  |   \2.{SID-Q1,SID-C}Pkt      /  |   \5.{SID-C}Pkt    
     Pkt     /   |    \ /   |    \            /   |    \   
[CE1]------[A]   |     X    |     \          /    |    [C]-----[CE2]
             \   |    / \   |      \        /     |    /   6.Pkt
              \  |   /   \  |       \      /4.{SID-Q1,SID-C}Pkt
               [ P2 ]-----[ P4 ]-----[ N1 ]-----[ Q2 ]  
                                 ^
                                 |
                                 3.{SID-Q1,SID-C}Pkt

Path 1:A->P1->N->Q1->C, indicated at A by {SID-P1,SID-N,SID-Q1,SID-C}
]]></artwork>
          </figure>  

          The results from nodes A, N1, Q1 and C are the same as
          those described above in <xref target="no-bsid-before-convergence"/>.

          The results from nodes P1 and P4 
          are as follows.

          <list style="hanging" hangIndent="4">
            <t hangText="2.">Since non-neighbor upstream
               node P1 of N on 
               the SR path does not have a FIB entry for SID-N as the top 
               SID of the packet, node P1
               pops SID-N from the packet, and 
               sends the packet to P4 according to the top SID (SID-Q1) 
               in the packet
               along the IGP shortest path to Q1.
               The packet sent to P4 is represented by
              "2.{SID-Q1,SID-C}Pkt".
            </t>
            <t hangText="3.">Node P4 sends the packet to N1 according to 
               the top SID (SID-Q1) in the packet received.
               The packet sent to N1 is represented by
              "3.{SID-Q1,SID-C}Pkt".
            </t>
          </list>
        </t>
      </section>
      </section>
      <!-- SR-MPLS Path with no BSID -->


      <section anchor="path-with-bsid"  
               title="SR-MPLS Path with BSID">
      <section anchor="bsid-without-failure"  
               title="Without any Failure">
       <t><xref target="sr-path-no-failure-bsid"/> shows the 
          result of executing procedure on each related node 
          of SR-MPLS path 2 with BSID-N without any failure. 

         <figure
            anchor="sr-path-no-failure-bsid"
            title="Path with BSID Without any Failure">
            <artwork><![CDATA[
     1.{SID-P1,SID-N,BSID-N}Pkt 
            |  2.{SID-N,BSID-N}Pkt 
            |         |   3.{SID-N,BSID-N}Pkt
            |         |          |   4.{SID-Q1,SID-C}Pkt
            |         |          |          | 
            |         v          v          v
            |  [ P1 ]-----[ P3 ]-----[ N  ]-----[ Q1 ]   
            v /  |   \   /  |   \   /  |   \   /  |   \5.{SID-C}Pkt    
     Pkt     /   |    \ /   |    \ /   |    \ /   |    \   
[CE1]------[A]   |     X    |     X    |     X    |    [C]-----[CE2]
             \   |    / \   |    / \   |    / \   |    /   6.Pkt
              \  |   /   \  |   /   \  |   /   \  |   /
               [ P2 ]-----[ P4 ]-----[ N1 ]-----[ Q2 ]  

Path 2:A->P1->N->Q1->C, indicated at A by {SID-P1,SID-N,BSID-N} and
                       BSID-N associated with SID list {SID-Q1,SID-C}
]]></artwork>
          </figure>  

          The results from nodes A, P1, P3, and N
          are as follows.

          <list style="hanging" hangIndent="4">
            <t hangText="1.">
               Node A as the ingress of the path adds 
               SID-P1, SID-N, and BSID-N 
               into a packet (Pkt) received from CE1 and sends the packet 
               with the SIDs to node P1. 
               The packet sent to P1 is represented by
               "1.{SID-P1,SID-N,BSID-N}Pkt".
            </t>

            <t hangText="2.">
               Node P1 pops its SID-P1 from the packet received,
               sends the packet with top SID (SID-N) to P3 
               along the IGP shortest path to N 
               according to its FIB entry for SID-N.
               The packet sent to P3 is represented by
               "2.{SID-N,BSID-N}Pkt".
            </t>

            <t hangText="3.">
               Node P3 sends the packet with top SID (SID-N) to N
               along the IGP shortest path to N.
               The packet sent to N is represented by
               "3.{SID-N,BSID-N}Pkt".
            </t>

            <t hangText="4.">
               Node N pops its SID-N from the packet received,
               replaces its BSID-N with SID list {SID-Q1,SID-C}, and
               sends the packet with top SID (SID-Q1) to Q1 
               along the IGP shortest path to Q1 
               according to its FIB entry for SID-Q1.
               The packet sent to Q1 is represented by
               "4.{SID-Q1,SID-C}Pkt".
            </t>
          </list>
          The results from nodes Q1 and C are the same as
          those described in <xref target="no-bsid-without-failure"/>.
        </t>
      </section>
<!-- Without any Failure  -->

      <section anchor="bsid-before-convergence"  
               title="Before IGP Converges on Failure">
       <t><xref target="sr-path-n-fail-1-bsid"/> shows the 
          result of executing procedure on each related node 
          of SR-MPLS path 2 with BSID-N
          when node N failed and 
          before the IGP converges on the failure. 

         <figure
            anchor="sr-path-n-fail-1-bsid"
            title="Path with BSID-N when N failed and before IGP converges">
            <artwork><![CDATA[
 1.{SID-P1,SID-N,BSID-N}Pkt 
            | 
            |     2.{SID-N,BSID-N}Pkt 
            |         |
            |         v                
            |  [ P1 ]-----[ P3 ]     [ N  ]     [ Q1 ]   
            v /  |   \   /  |   \3.{SID-Q1,    /  |   \5.{SID-C}Pkt    
     Pkt     /   |    \ /   |    \  SID-C}Pkt /   |    \   
[CE1]------[A]   |     X    |     X    |     X    |    [C]-----[CE2]
             \   |    / \   |    / \   |    / \   |    /   6.Pkt
              \  |   /   \  |   /   \  |   /4.{SID-Q1,SID-C}Pkt
               [ P2 ]-----[ P4 ]-----[ N1 ]-----[ Q2 ]  

Path 2:A->P1->N->Q1->C, indicated at A by {SID-P1,SID-N,BSID-N} and
                       BSID-N associated with SID list {SID-Q1,SID-C}
]]></artwork>
          </figure>  

          The results from nodes A, P1, Q1 and C are the same as
          those described in <xref target="bsid-without-failure"/>.

          The results from neighbor upstream node P3 of N and node N1
          are as follows.

          <list style="hanging" hangIndent="4">
            <t hangText="3.">After detecting the failure of N,
               the neighbor upstream node P3 of N pops SID-N 
               from the packet received,
               replaces BSID-N in the packet with SID list {SID-Q1,SID-C}, 
               and re-routes the packet to node Q1 via node N1 without
               going through failed N.
               The packet sent to N1 is represented by
              "3.{SID-Q1,SID-C}Pkt".
            </t>
            <t hangText="4.">Node N1 
               sends the packet to Q1 according to the top SID (SID-Q1) 
               in the packet.
               The packet sent to Q1 is represented by
              "4.{SID-Q1,SID-C}Pkt".
            </t>
          </list>
        </t>
      </section> 
<!-- Before IGP Converges on Failure  -->

      <section anchor="bsid-after-convergence"  
               title="After IGP Converges on Failure">
       <t><xref target="sr-path-n-fail-2-bsid"/> shows the 
          result of executing procedure on each related node 
          on SR-MPLS path 2 with BSID-N
          when node N failed and 
          after the IGP converges on the failure. 

         <figure
            anchor="sr-path-n-fail-2-bsid"
            title="Path with BSID-N when N failed and after IGP converges">
            <artwork><![CDATA[
            1.{SID-P1,SID-N,BSID-N}Pkt 
            |     
            |  [ P1 ]-----[ P3 ]     [ N  ]     [ Q1 ]   
            v /  |   \2.{SID-Q1,SID-C}Pkt      /  |   \5.{SID-C}Pkt    
     Pkt     /   |    \ /   |    \            /   |    \   
[CE1]------[A]   |     X    |     \          /    |    [C]-----[CE2]
             \   |    / \   |      \        /     |    /   6.Pkt
              \  |   /   \  |       \      /4.{SID-Q1,SID-C}Pkt
               [ P2 ]-----[ P4 ]-----[ N1 ]-----[ Q2 ]  
                                 ^
                                 |
                                 3.{SID-Q1,SID-C}Pkt

Path 2:A->P1->N->Q1->C, indicated at A by {SID-P1,SID-N,BSID-N} and
                       BSID-N associated with SID list {SID-Q1,SID-C}
]]></artwork>
          </figure>  

          The results from nodes A, Q1 and C are the same as
          those described above in <xref target="bsid-before-convergence"/>.
          The results from nodes P4 and N1 are the same as
          those described above in <xref target="no-bsid-after-convergence"/>.

          The result from node P1  
          is as follows.

          <list style="hanging" hangIndent="4">
            <t hangText="2.">Since non-neighbor upstream
               node P1 of N on 
               the SR path does not have a FIB entry for SID-N as the top 
               SID of the packet, node P1
               pops SID-N from the packet, 
               replaces BSID-N in the packet with SID list {SID-Q1,SID-C}
               and 
               sends the packet to P4 according to the top SID (SID-Q1) 
               in the packet
               along the IGP shortest path to Q1.
               The packet sent to P4 is represented by
              "2.{SID-Q1,SID-C}Pkt".
            </t>
          </list>
        </t>
      </section> 
<!-- After IGP Converges on Failure -->
      </section> 
<!-- Path with BSID -->
    </section>


    <section title="Procedures">
      <t>This section presents the procedures on a neighbor upstream node and
         a non-neighbor upstream node of 
         node N on an SR MPLS path.</t>

   <section title="Procedure on Non-neighbor Upstream Node">
    <t>For an SR-MPLS path with the node SID of node N (SID-N), 
       suppose that node X is an non-neighbor upstream node of node N 
       along the path, wherein SID-N follows 
       the node SID of node X (SID-X) 
       or the adjacency SID to node X in the packet 
       to be transported by the path. 

       For example, SR-MPLS Path 1 and Path 2 
       in <xref target="topo-w-sr-path"/> 
       are from A to P1 to N to Q1 to C.  
       Node P1 is the non-neighbor upstream node of N.
 
       At ingress node A of the path, 
       node A adds the SIDs in the SID list 
       into the packet to be transported by the path.
    </t>

    <t>Without any failure 
       or from the failure of node N to IGP convergence on the failure,
       the non-neighbor upstream node (such as P1) of node N pops 
       its SID from the packet if any and 
       sends the packet to the next hop node toward node N 
       along the IGP shortest path to N. 
    </t>

    <t>After node N failed and from the IGP convergence on the failure 
       to global reroute, 
       the non-neighbor upstream node (such as P1) of node N 
       pops its SID (such as SID-P1) from the packet if any, 
       pops SID-N from the packet 
<!-- if top SID in the packet is SID-N -->
       and does one of the following:
       <list style="hanging" hangIndent="4">
         <t hangText="a.">
            If the current top SID in the 
            packet is a node SID of a node named Nx, 
            sends the packet toward Nx along the IGP shortest 
            path to Nx.
          </t>
         <t hangText="b.">
            If the current top SID in the 
            packet is an adjacency SID of node N, 
            obtains the remote node of the adjacency from the adjacency SID,
            replaces the adjacency SID with the node SID of the remote node, 
            and sends the packet toward the remote node along the IGP 
            shortest path to the remote node.
         </t>
         <t hangText="c.">
            If the current top SID in the 
            packet is a Binding SID (BSID) of node N, 
            replaces the BSID in the packet with the SID list 
            associated with the BSID, and
            does a. or b. 
            according to the current top SID in the packet
            (i.e., does a. if it is a node SID;
             does b. if it is an adjacency SID of N).
            Note: Distributing the information about the BSID of N
            (including the BSID, the SID list, the ID of N) 
            to upstream nodes of N
            is out of scope of this document.
<!--
            In another option, if the first SID in the list is the 
            adjacency SID of node N, the upstream node of node N 
            obtains the remote node of the adjacency from the adjacency 
            SID and replaces the adjacency SID in the list with the 
            node SID of the remote node. The upstream node 
            replaces the BSID in the packet with the list and 
            sends the packet towards the top SID in the packet along 
            the IGP shortest path to the top SID.
-->
         </t>
       </list>
     </t>

   </section> 
<!-- Procedure on Non-neighbor Upstream Node -->


   <section title="Procedure on Neighbor Upstream Node">
    <t>Suppose that node Y is the neighbor upstream node of node N 
       on an SR-MPLS path. 
       Without any failure,
       node Y sends the packet received from the path 
       to node N according to the top SID in the packet.

       For example, SR-MPLS Path 1 and Path 2 
       in <xref target="topo-w-sr-path"/> 
       are from A to P1 to N to Q1 to C.  
       Node P3 is the neighbor upstream node of N 
       suppose that the shortest path from P1 to N is from P1 to P3 to N.

       When node Y detects the failure of node N,
       node Y pops SID-N from the packet 
       if SID-N is the top SID of the packet,
       and does one of the following:
       <list style="hanging" hangIndent="4">
         <t hangText="a.">
            If the current top SID in the packet is node SID of node Nx,
            sends the packet toward node Nx without going through failed N
       (i.e., {SID-Nx,...} in the packet would be {RL(Q),SID-Nx,...},
       where RL(Q) is the repair list redirecting the packet to node Q,
       whose path to SID-Nx is not affected by the failure).
         </t>

         <t hangText="b.">
            If the current top SID in the packet is an adjacency SID of N,
            gets remote node R of the adjacency from the adjacency SID,
            replaces the top SID in the packet with node SID of R, and 
            sends the packet to node R according to the top SID 
            in the packet 
            without going through failed N
       (i.e., {adj(N-R),...} in the
       packet would be {RL(Q),SID-R,...}, where RL(Q) is the repair list
       redirecting the packet to node Q, whose path to SID-R is not
       affected by the failure).</t>

          <t hangText="c.">
            If the current top SID in the packet is a BSID of N,
            replaces the BSID with the SID list associated with the BSID,
            and does a. or b. 
            according to the current top SID in the packet
            (i.e., does a. if it is a node SID;
             does b. if it is an adjacency SID of N).
          </t>
       </list> 
     </t>
   </section>
<!-- Procedure on Neighbor Upstream Node-->

<!--
      <section title="Integrated Procedures">
        <t>A procedure running on a node that forwards the packet
           to be transported by a SR-MPLS path in different cases 
           is called an integrated procedure. 
           The node is an neighbor node or a upstream node.
           The cases include normal case without any failure,
           or a node failure. 
        </t>
        <t>Suppose that Packet = the packet received by node X. 
           An integrated procedure running on node X is 
           described in Pseudo code as shown in 
           <xref target="integrated-proc"/>. 

<figure anchor="integrated-proc" 
        title="Integrated Procedure">
  <artwork> <![CDATA[IF (next hop interface to top SID in Packet failed){//X: N's neighbor
   IF (the top SID in Packet is node SID of N) {
      Pops the top SID from Packet; // pops node SID of failed N
      IF (the top SID in Packet is BSID of N) {
         Replace BSID with SID list associated with BSID;}
   }
   IF (top SID in Packet is Adjacency SID of failed N) {
      Gets remote node R of the adjacency from the adjacency SID;
      Replace top SID in Packet with node SID of R;} 
   Sends Packet to node having the top SID in Packet without going N;
} ELSE { // X as upstream node of failed N
   IF (top SID in Packet is node SID of node X) {
      Pops top SID from Packet; }
   IF (no FIB entry for top SID in Packet){//IGP converges on failure
      Pops top SID from Packet; // pops node SID of failed N
      IF (top SID in Packet is node SID of Nx){//next SID is node SID
         Sends Packet using FIB entry for top SID in Packet;
      } ELSE IF (top SID in Packet is an adjacency SID of N){
         Gets remote node R of the adjacency from the adjacency SID;
         Replaces the adjacency SID in Packet with the node SID of R;
         Sends Packet using FIB entry for top SID in Packet;
      } ELSE IF (top SID in Packet is a BSID of N) {
         Replaces BSDI with SID list associated with BSID;
         IF (top SID in Packet is Adjacency SID of failed N) {
            Gets remote node R of the adjacency from adjacency SID;
            Replace top SID in Packet with node SID of R;}
         Send Packet using FIB entry for top SID in Packet.
      }
   } ELSE{//Normal case,N works & there is FIB entry for N's node SID
      Sends Packet using FIB entry for top SID in Packet;
   }
}]]></artwork>
</figure> 
</t>

      </section>
-->
<!-- Integrated Procedures -->

    </section>  
<!-- Procedures -->


    <section anchor="Security" title="Security Considerations">
      <t>TBD.</t>
    </section>

    <section anchor="IANA" title="IANA Considerations">
      <t>No requirements for IANA.</t>
    </section>

  </middle>
  <back>

    <references title="Normative References">
      <?rfc include="reference.RFC.2119"?>
      <!-- <?rfc include="reference.RFC.7356"?> -->
      <!-- <?rfc include="reference.RFC.8402"?> -->
      <!-- <?rfc include="reference.RFC.8667"?> -->
      <?rfc include="reference.RFC.8174"?>

    </references>

    <references title="Informative References">
      <?rfc include="reference.I-D.ietf-rtgwg-segment-routing-ti-lfa"?>
      <?rfc include="reference.I-D.ietf-spring-segment-protection-sr-te-paths"?>
    </references>

    <section numbered="false" toc="include" removeInRFC="false" pn="section-appendix.a">
      <name slugifiedName="name-acknowledgments">Acknowledgments</name>
      <t>The authors would like to thank people
      for their comments to this work.</t>
    </section>

<!-- Appendix -->
<!--
    <section numbered="false" toc="include" removeInRFC="false" pn="section-appendix.b">
      <name slugifiedName="name-ti-lfa">
        Procedure on Neighbor Upstream Node in TI-LFA</name>

    <t>Suppose that node Y is the neighbor upstream node of node N 
       on an SR-MPLS path. 
       Without any failure,
       node Y sends the packet received from the path 
       to node N according to the top SID in the packet.

       For example, SR-MPLS Path 1 and Path 2 
       in <xref target="topo-w-sr-path"/> 
       are from A to P1 to N to Q1 to C.  
       Node P3 is the neighbor upstream node of N 
       suppose that the shortest path from P1 to N is from P1 to P3 to N.

       When node Y detects the failure of node N,
       node Y pops SID-N from the packet 
       if SID-N is the top SID of the packet,
       and does one of the following:
       <list style="hanging" hangIndent="4">
         <t hangText="a.">
            If the current top SID in the packet is node SID of node Nx,
            sends the packet toward node Nx without going through failed N
            (i.e., [SID-Nx,...] in the packet would be [RL(Q),SID-Nx,...],
             where RL(Q) is the repair list redirecting the packet to 
             node Q, whose path to SID-Nx is not affected by the failure).
         </t>

         <t hangText="b.">
            If the current top SID in the packet is an adjacency SID of N,
            gets remote node R of the adjacency from the adjacency SID,
            replaces the top SID in the packet with node SID of R, and 
            sends the packet to node R according to the top SID 
            in the packet 
            without going through failed N 
            (i.e., [adj(N-R),...] in the packet would be [RL(Q),SID-R,...],
             where RL(Q) is the repair list redirecting the packet to 
             node Q, whose path to SID-R is not affected by the failure).</t>

          <t hangText="c.">
            If the current top SID in the packet is a BSID of N,
            replaces the BSID with the SID list associated with the BSID,
            and does a. or b. 
            according to the current top SID in the packet
            (i.e., does a. if it is a node SID;
             does b. if it is an adjacency SID of N).
          </t>
       </list> 
     </t>
   </section>
-->
<!-- Procedure on Neighbor Upstream Node-->


  </back>
</rfc>
