<?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="no"?>
<?rfc comments="yes"?>
<?rfc inline="yes"?>
<?rfc compact="yes"?>
<?rfc subcompact="no"?>
<rfc category="std" docName="draft-li-rtgwg-enhanced-ti-lfa-06"
     ipr="trust200902" updates="">
  <front>
    <title abbrev="Enhanced TI-LFA">Enhanced Topology Independent Loop-free
    Alternate Fast Re-route</title>

    <author fullname="Cheng Li" initials="C." surname="Li">
      <organization>Huawei Technologies</organization>

      <address>
        <postal>
          <street>Huawei Campus, No. 156 Beiqing Rd.</street>

          <city>Beijing</city>

          <region/>

          <code>100095</code>

          <country>China</country>
        </postal>

        <phone/>

        <facsimile/>

        <email>c.l@huawei.com</email>

        <uri/>
      </address>
    </author>

    <author fullname="Zhibo Hu" initials="Z." surname="Hu">
      <organization>Huawei Technologies</organization>

      <address>
        <postal>
          <street>Huawei Campus, No. 156 Beiqing Rd.</street>

          <city>Beijing</city>

          <region/>

          <code>100095</code>

          <country>China</country>
        </postal>

        <phone/>

        <facsimile/>

        <email>huzhibo@huawei.com</email>

        <uri/>
      </address>
    </author>

    <author fullname="Yongqing Zhu" initials="Y." surname="Zhu">
      <organization>China Telecom</organization>

      <address>
        <postal>
          <street/>

          <city/>

          <region/>

          <code/>

          <country/>
        </postal>

        <phone/>

        <facsimile/>

        <email>zhuyq8@chinatelecom.cn</email>

        <uri/>
      </address>
    </author>

    <author fullname="Shraddha Hegde" initials="S." surname="Hegde">
      <organization>Juniper Networks Inc.</organization>

      <address>
        <postal>
          <street/>

          <city/>

          <region/>

          <code/>

          <country>India</country>
        </postal>

        <phone/>

        <facsimile/>

        <email>shraddha@juniper.net</email>

        <uri/>
      </address>
    </author>

    <date day="22" month="April" year="2022"/>

    <area>Routing Area</area>

    <workgroup>RTGWG Working Group</workgroup>

    <abstract>
      <t>Topology Independent Loop-free Alternate Fast Re-route (TI-LFA) aims
      at providing protection of node and adjacency segments within the
      Segment Routing (SR) framework. A key aspect of TI-LFA is the FRR path
      selection approach establishing protection over the expected
      post-convergence paths from the point of local repair. However, the
      TI-LFA FRR path may skip the node even if it is specified in the SID
      list to be traveled.</t>

      <t>This document defines Enhanced TI-LFA(TI-LFA+) by adding a No-bypass
      indicator for segments to ensure that the FRR route will not bypass the
      specific node, such as firewall. Also, this document defines No-bypass
      flag and No-FRR flag in SRH to indicate not to bypass nodes and not to
      perform FRR on all the nodes along the SRv6 path, respectively.</t>
    </abstract>
  </front>

  <middle>
    <section title="Introduction">
      <t>Segment Routing <xref target="RFC8402"/> enables to steer packets by
      explicitly encoding instructions in the data packets at the source node
      to support services like traffic engineer. Relying on SR, <xref
      target="I-D.ietf-rtgwg-segment-routing-ti-lfa"/> defines Topology
      Independent Loop-free Alternate Fast Re-route (TI-LFA), a local repair
      mechanism for IGP shortest path that capable of restoring end-to-end
      connectivity in the case of a sudden directly connected failure of a
      network component.</t>

      <t/>

      <t>TI-LFA supports to establish a loop free backup path over the
      expected post-convergence paths from the point of local repair
      irrespective of the topologies used in the network, which provides a
      major improvment compared to LFA <xref target="RFC5286"/>, and remote
      LFA <xref target="RFC7490"/> which cannot be applicable in some
      topologies <xref target="RFC6571"/>.</t>

      <t>However, the TI-LFA path may skip the node that the active SID points
      to when protecting [Adjacency, Node] segment lists. For instance, the
      node that a adjacency SID points to is a very important node and can not
      be skipped, such as a firewall node. When the link between the local
      repair node and firewall node fails, the packets should be steered back
      to the firewall and then forwarding. But in TI-LFA, if the next SID in
      the SID list is a node SID, the TI-LFA FRR path MAY bypass the node that
      the active segment points to. Also, if the firewall node is down, the
      packets should be dropped instead for fast reroute to bypass the node.
      Bypassing nodes like firewall in FRR brings issues of network security
      and reliability.</t>

      <t>To enhance the security and reliability of networks, this document
      defines an Enhanced Topology Independent Loop-free Alternate Fast
      Re-route (TI-LFA+) based on TI-LFA by adding a No-bypass flag for
      segments to explicitly specify what node can not be bypassed. Also, this
      document defines No-bypass flag and No-FRR flag in SRH to indicate not
      to bypass nodes and not to perform FRR on all the nodes along the SRv6
      path, respectively.</t>
    </section>

    <section title="Terminology">
      <t>This document makes use of the terms defined in <xref
      target="I-D.ietf-rtgwg-segment-routing-ti-lfa"/> and <xref
      target="RFC8402"/>. The reader is assumed to be familiar with the
      terminology defined in <xref
      target="I-D.ietf-rtgwg-segment-routing-ti-lfa"/> and <xref
      target="RFC8402"/>.</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 title="Overview of Enhanced TI-LFA">
      <t>Enhanced Topology Independent Loop-free Alternate Fast Re-route
      (TI-LFA+) is an enhancement of TI-LFA to explicitly indicate whether a
      node that segment points to can not be bypassed in FRR scenarios.</t>

      <t>TI-LFA+ will not change the main process and algorithm of TI-LFA.
      Instead, in TI-LFA+, when generating repair SID list for a SID, the node
      should consider whether the SID endpoint can be baseed or not, which is
      explicitly encoded in IGP messages. If the node that segment points to
      can not be bypassed, then the repair SID MUST lead the packets to that
      node. This document defines a No-bypass flag for segments in IS-IS and
      OSPF. Details will be discussed in section 4.</t>

      <t>A node should advertise two kinds of segment to meet various service
      policy requirements.</t>

      <t><list style="symbols">
          <t>Bypassing capable segment with No-bypass flag unset</t>

          <t>No-bypassing segment with No-bypass flag set.</t>
        </list>A controller or control plane should choose specific segment
      according to the service policy.</t>

      <t>[Editors' note] If the TI-LFA result is generated based on Locator
      route instead of SIDs, then the No-bypass Flag can be applied to the
      Locator.</t>

      <t>Also, this document defines No-bypass flag and No-FRR flag in SRH to
      indicate not to bypass nodes and not to perform FRR on all the nodes
      along the SRv6 path, respectively. Details will be discussed in section
      5.</t>
    </section>

    <section title="IGP Protocol Extensions">
      <t/>

      <section title="IS-IS">
        <t/>

        <t><xref target="RFC8667"/> describes the necessary IS-IS extensions
        that need to be introduced for Segment Routing.<xref
        target="I-D.ietf-lsr-isis-srv6-extensions"/> defines the IS-IS
        extensions required to support Segment Routing over an IPv6 data
        plane. This documment defines a No-bypass flag in flag filed of the
        following IS-IS sub-TLV/TLV.</t>

        <t/>

        <t><list style="symbols">
            <t>Prefix Segment Identifier sub-TLV (Prefix-SID sub-TLV) <xref
            target="RFC8667"/></t>

            <t>Adjacency Segment Identifier sub- TLV (Adj-SID sub-TLV).<xref
            target="RFC8667"/></t>

            <t>Locator entry in SRv6 Locator TLV <xref
            target="I-D.ietf-lsr-isis-srv6-extensions"/></t>
          </list>The following figures are included here for reference and
        will be deleted in the future version.</t>

        <t><figure>
            <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    |     Flags     |   Algorithm   |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                        SID/Index/Label (variable)             |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

    0  1  2  3  4  5  6  7
   +--+--+--+--+--+--+--+--+
   |R | N| P| E| V| L|NB|  |
   +--+--+--+--+--+--+--+--+

             Figure 1. Prefix-SID sub-TLV and No-bypass Flag
]]></artwork>
          </figure></t>

        <t><figure>
            <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    |     Flags     |     Weight    |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                         SID/Label/Index (variable)            |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

    0  1  2  3  4  5  6  7
   +--+--+--+--+--+--+--+--+
   |F | B| V| L| S|NB|  |  |
   +--+--+--+--+--+--+--+--+
             Figure 2. Adj-SID sub-TLV and No-bypass Flag
]]></artwork>
          </figure></t>

        <t><figure>
            <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
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                          Metric                               |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |   Flags       |  Algorithm    |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |  Loc Size     | Locator (variable)...
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |  Sub-tlv-len  |         Sub-TLVs (variable) . . .             |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

    0  1  2  3  4  5  6  7
   +--+--+--+--+--+--+--+--+
   |D |NB|  |  |  |  |  |  |
   +--+--+--+--+--+--+--+--+
             Figure 3. SRv6 Locator Entry and No-bypass Flag
]]></artwork>
          </figure></t>

        <t>If the No-bypass(NB) flag is set, means the node that the
        SID/Label/Locator points to can not be bypassed. Oterwise, the node
        can be bypassed.</t>
      </section>

      <section title="OSPF">
        <t><xref target="RFC8665"/> describes the necessary OSPF extensions
        that need to be introduced for Segment Routing.<xref
        target="I-D.ietf-lsr-ospfv3-srv6-extensions"/> defines the OSPF
        extensions required to support Segment Routing over an IPv6 data
        plane. This documment defines a No-bypass flag in flag filed of the
        following OSPF sub-TLV/TLV.</t>

        <t/>

        <t><list style="symbols">
            <t>Prefix SID Sub-TLV <xref target="RFC8665"/></t>

            <t>Adj-SID sub-TLV <xref target="RFC8665"/></t>

            <t>SRv6 Node SID TLV <xref
            target="I-D.ietf-lsr-ospfv3-srv6-extensions"/></t>

            <t>SRv6 SID Link Attribute Sub-TLV <xref
            target="I-D.ietf-lsr-ospfv3-srv6-extensions"/></t>
          </list>The following figures are included here for reference and
        will be deleted in the future version.</t>

        <t><figure>
            <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            |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |      Flags    |   Reserved    |      MT-ID    |    Algorithm  |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                     SID/Index/Label (variable)                |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+


     0  1  2  3  4  5  6  7
   +--+--+--+--+--+--+--+--+
   |  |NP|M |E |V |L |NB|  |
   +--+--+--+--+--+--+--+--+

             Figure 4. Prefix-SID sub-TLV and No-bypass Flag
]]></artwork>
          </figure></t>

        <t><figure>
            <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             |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |     Flags     |    Reserved   |   MT-ID       |  Weight       |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                   SID/Label/Index (variable)                  |
   +---------------------------------------------------------------+


    0  1  2  3  4  5  6  7
   +--+--+--+--+--+--+--+--+
   |B | V| L| G| P|NB|  |  |
   +--+--+--+--+--+--+--+--+

             Figure 5. Adj-SID sub-TLV and No-bypass Flag
]]></artwork>
          </figure></t>

        <t><figure>
            <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               |
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |   Reserved    | Function-Flags|           Function Code       |
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |   Reserved                    |  SID Flags    |  SID-size     |
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |   SID (variable - 32 bit aligned) ...
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |    Sub-TLVs (variable) . . .
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+


    0  1  2  3  4  5  6  7
   +--+--+--+--+--+--+--+--+
   |D |NB|  |  |  |  |  |  |
   +--+--+--+--+--+--+--+--+
             Figure 6. SRv6 Node SID TLV and No-bypass Flag
]]></artwork>
          </figure></t>

        <t><figure>
            <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               |
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |   Reserved    | Function-Flags|           Function Code       |
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |   Reserved                    |  SID Flags    |  SID-size     |
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |   SID (variable - 32 bit aligned) ...
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |    Sub-TLVs (variable) . . .
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+


     0  1  2  3  4  5  6  7
   +--+--+--+--+--+--+--+--+
   |NB|  |  |  |  |  |  |  |
   +--+--+--+--+--+--+--+--+
             Figure 7. SRv6 Adj-SID TLV and No-bypass Flag
]]></artwork>
          </figure></t>

        <t>If the No-bypass(NB) flag is set, means the node that the
        SID/Label/Locator points to can not be bypassed. Oterwise, the node
        can be bypassed.</t>
      </section>
    </section>

    <section title="Flags in SRH">
      <t>This section describes two flags in SRH.</t>

      <t/>

      <section title="No-bypass Flag in SRH">
        <t>This document defines a No-bypass Flag in SRH <xref
        target="RFC8754"/>.</t>

        <t><figure>
            <artwork><![CDATA[
     0  1  2  3  4  5  6  7
   +--+--+--+--+--+--+--+--+
   |NB|  |  |  |  |  |  |  |
   +--+--+--+--+--+--+--+--+          

]]></artwork>
          </figure></t>

        <t><list style="symbols">
            <t>NB Flag: No-Bypass flag, when the flag is set, the repair
            segment endpoint nodes MUST NOT bypass any nodes when link or node
            failures occur. When a link is down, the packet MUST be forwarded
            to the next segment endpoint node through the repair path. When
            the node identified by the active SID in IPv6 destination address
            is down, the SID can not be skipped, and the traffic MUST be
            forwarded to the node.</t>
          </list></t>

        <t>The flag can be set when the SID list containing service SIDs like
        firewall SID, so that the traffic will not bypass the service
        nodes.</t>

        <t/>
      </section>

      <section title="No-FRR Flag in SRH">
        <t>This document defines a No-FRR Flag in SRH <xref
        target="RFC8754"/>.</t>

        <t><figure>
            <artwork><![CDATA[
     0  1  2  3  4  5  6  7
   +--+--+--+--+--+--+--+--+
   |  |NF|  |  |  |  |  |  |
   +--+--+--+--+--+--+--+--+          

]]></artwork>
          </figure><list style="symbols">
            <t>NF Flag: No-FRR flag, when the flag is set, the FRR is disable
            for the packet, thus the packet will not be protected by the Local
            protection mechanism, such as TI-LFA.</t>
          </list></t>

        <t>The flag can be set when the SID list containing service SIDs like
        firewall SID, so that the traffic will not bypass the service nodes.
        In this case, E2E protection mechanism should be deployed.</t>

        <t/>
      </section>
    </section>

    <section anchor="IANA" title="IANA Considerations">
      <t>TBD.</t>
    </section>

    <section anchor="Security" title="Security Considerations">
      <t>TBD.</t>
    </section>
  </middle>

  <back>
    <references title="Normative References">
      <?rfc include="reference.RFC.2119"?>

      <?rfc include='reference.RFC.5286'?>

      <?rfc include='reference.RFC.8174'?>

      <?rfc include='reference.RFC.7490'?>

      <?rfc include="reference.RFC.6571"?>

      <?rfc include='reference.I-D.ietf-rtgwg-segment-routing-ti-lfa'?>

      <?rfc include='reference.RFC.8754'?>
    </references>

    <references title="Informative References">
      <?rfc include='reference.RFC.4657'?>

      <?rfc include="reference.RFC.8253"?>

      <?rfc include='reference.RFC.8402'?>

      <?rfc include='reference.RFC.8667'
?>

      <?rfc include='reference.RFC.8665'
?>

      <?rfc include='reference.I-D.ietf-lsr-ospfv3-srv6-extensions'?>

      <?rfc include='reference.I-D.ietf-lsr-isis-srv6-extensions'?>

      <?rfc ?>
    </references>
  </back>
</rfc>
