<?xml version="1.0" encoding="US-ASCII"?>
<!DOCTYPE rfc SYSTEM "rfc2629.dtd" [

<!ENTITY rfc793 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.0793.xml">
<!ENTITY rfc2119 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.2119.xml">
<!ENTITY rfc2328 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.2328.xml">
<!ENTITY rfc5246 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.5246.xml">
<!ENTITY rfc5340 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.5340.xml">
<!ENTITY rfc7981 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.7981.xml">
<!ENTITY rfc8174 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.8174.xml">
<!ENTITY rfc9000 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.9000.xml">

]>
<?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-li-lsr-liveness-00"
     ipr="trust200902" consensus="true">
  <front>
    <title abbrev="Node Liveness Protocol">
      Node Liveness Protocol
    </title>
    <author fullname="Tony Li," initials="Tony." surname="Li">
      <organization>Juniper Networks</organization>
      <address>
	<postal>
          <street>1133 Innovation Way</street>
          <city>Sunnyvale</city>
          <region>California</region>
          <code>94089</code>
          <country>USA</country>
	</postal>
	<phone></phone>
	<email>tony.li@tony.li</email>
      </address>
    </author>
    <date month="Jan" year="2022" day="18"/>
    <area>Routing Area</area>
    <workgroup>LSR Working Group</workgroup>
    <keyword>ISIS</keyword>
    <keyword>Draft</keyword>
    <abstract>
      <t>
	Prompt notification of the loss of node liveness or
	reachability is useful for restoring services in tunneled
	topologies. IGP summarization precludes remote nodes from
	directly observing the status of remote nodes. This document
	proposes a service that, in conjunction with the IGP, provides
	prompt notifications without impacting IGP summarization.
      </t>
    </abstract>
  </front>
  <middle>
    <section title="Introduction">
      <t>
	Overlay services are increasingly common and are implemented
	by creating tunnels over a physical infrastructure. The
	failure of one of the tunnel endpoints implies that the
	traffic towards that endpoint will be lost until the other
	endpoint recognizes the situation and takes remedial
	action. Prompt notification of the failure of the other
	endpoint is useful in minimizing the duration of the outage.
      </t>
      <t>
	Some network designs have come to rely on examining the IGP's
	Link State Database (LSDB) to determine node liveness and,
	through the IGP SPF computation, the node's
	reachability. However, if the network is to scale, some form
	of summarization must be employed, resulting in this
	information no longer being directly available. This document
	proposes a protocol that will provide prompt notificaion of
	changes in node liveness, even in networks that employ IGP
	summarization.
      </t>
      <t>
	The service itself runs on OSPF <xref target="RFC2328"/> <xref
	target="RFC5340"/> Area Border Routers (ABRs) or IS-IS <xref
	target="ISO10589"/> L1-L2 routers. For brevity, we will use
	the term 'ABRs' for both cases.
      </t>
      <t>
	This service uses a simple, hierarchical publish-subscribe
	architecture. Clients are nodes within non-backbone OSPF areas
	or L1 IS-IS area. They register with their local ABRs.  The
	ABRs are fully meshed, with the exception that ABRs of the
	same area need not interact. Notifications initiated by an ABR
	flow to other ABRs and from there to client nodes.
      </t>
      <t>
	The availability of this service is advertised as part of the
	IGP, so that discovery of the service is automatic. Clients
	can automatically detect their local ABRs and ABRs can detect
	each other and automatically form the necessary hierarchy.
      </t>
      <t>
	The protocol runs on top of TCP <xref target="RFC0793"/> and/or
	QUIC <xref target="RFC9000"/> for reliability. Security is
	provided by conventional transport protocol mechanisms, such
	as TLS <xref target="RFC5246"/>.
      </t>
      <t>
	Node liveness should not be confused with service liveness. If
	a node is alive, then a service may or may not be up. This
	protocol only tries to convey node liveness.
      </t>
    </section>
    <section anchor="ReqLang" 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 <xref target="RFC2119">BCP 14</xref>
	<xref target="RFC8174"/>
	when, and only when, they appear in all capitals, as shown here.
      </t>
    </section>

    <section title="Node Liveness Capability Advertisement">
      <t>
	The Node Liveness Protocol is run by ABRs and is advertised in
	the IGP for connections by clients and other
	ABRs. Advertisements are done both into the backbone (L2) and
	into non-backbone (L1) areas. The advertisements into the
	backbone allow ABRs to automatically mesh. The advertisements
	into the non-backbone areas allow clients to automatically
	determine where the service is available.
      </t>
      <section title="Node Liveness Advertisement in IS-IS">
	<t>
	  An ABR advertises the IS-IS Node Liveness sub-TLV as part of
	  the IS-IS Router Capability TLV <xref
	  target="RFC7981"/>. This is injected into the ABRs L1 and L2
	  LSP. The format of the IS-IS Node Liveness sub-TLV is:
	</t>
        <figure align="left">
          <artwork align="left"><![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    |      TPI      |     Port      |
  +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  |    Number     |
  +-+-+-+-+-+-+-+-+
  ]]></artwork>
        </figure>

        <t>
	  <list>
            <t>Type: TBD1</t>

            <t>Length: n * 3 octets</t>

            <t>TPI: Transport Protocol Identifier, 1 octet
	    <list style="hanging" hangIndent="4">
	      <t> 0: TCP </t>
	      <t> 1: QUIC </t>
	    </list>
	    </t>

	    <t>Port Number: Transport protocol port number, 2 octets </t>
	  </list>
	</t>

	<t>
	  The advertisement of this capability indicates that the node
	  is providing the Node Liveness service on the designated
	  port using the designated protocol. The TPI indicates the
	  transport protocol to be used and the Port Number indicates
	  the associated port to be used.  The TPI and Port Number
	  pair may be included multiple times to indicate that
	  multiple protocols and port numbers are available. The
	  length of the sub-TLV can be used to determine the number of
	  TPI and Port Number pairs.
	</t>
      </section>
      <section title="Node Liveness Advertisement in OSPF">
	<t>
	  The availabilty of the Node Liveness service is provided by
	  the OSPF Node Liveness Sub-TLV.  The OSPF Node Liveness
	  Sub-TLV is used by both OSPFv2 and OSPFv3. The semantics are
	  the same as the IS-IS Node Liveness Sub-TLV. The format of
	  the OSPF Node Liveness Sub-TLV is:
	</t>
        <figure align="left">
          <artwork align="left"><![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            |
  +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  |      TPI      |          Port Number          |
  +-+-+-+-+-+-+-+-++-+-+-+-+-+-+-+-++-+-+-+-+-+-+-+
  ]]></artwork>
        </figure>

        <t>
	  <list>
            <t>Type: TBD2</t>

            <t>Length: n * 3 octets</t>

            <t>TPI: Transport Protocol Identifier, 1 octet
	    <list style="hanging" hangIndent="4">
	      <t> 0: TCP </t>
	      <t> 1: QUIC </t>
	    </list>
	    </t>

	    <t>Port Number: Transport protocol port number, 2 octets </t>
	  </list>
	</t>
	<t>
	  The TPI and Port Number fields are used in the same way as
	  for IS-IS.
	</t>
      </section>
    </section>

    <section title="Node Liveness Protocol">

      <section title="Messages">
	<t>
	  The Node Liveness Protocol sends messages in a stream inside
	  of the selected transport protocol. The protocol uses two
	  message types: Registration Messages and Notification
	  Messages.
	</t>
      </section>

      <section title="Client actions">
	<t>
	  The client may determine the set of ABRs that it wishes to
	  communicate with by examination of its LSDB. The client
	  SHOULD open connections to at least two ABRs for
	  redundancy. If the client cannot open two connections, then
	  the management system should be informed.
	</t>
	<t>
	  The client MAY send Registration Messages on each of its ABR
	  connections. A client MAY register for any number of
	  prefixes, but it is expected that a client will send a
	  registration for each of the tunnel endpoints that it will
	  correspond with. A client may register for a host (a /32 or
	  /128 prefix) or a shorter prefix. A client MUST NOT send
	  overlapping registrations.
	</t>
	<t>
	  Clients never send Notification Messages and never recive
	  Registration Messages.
	</t>
	<t>
	  The actions of the client on receiving a Notification
	  Message are out of scope for this document.
	</t>
      </section>
      <section title="ABR actions">
	<t>
	  Each ABR MUST advertise the availability of the Node
	  Liveness service into the backbone (L2) area and into any
	  non-backbone (L1) areas.
	</t>
	<t>
	  Each ABR MUST have a single connection to each other ABR
	  that is part of a different non-backbone (L1) area. To
	  prevent duplicate connections, only one ABR should
	  initiate the connection. For IS-IS, the node with the lowest
	  system ID should initiate the connection. For OSPFv4, the
	  node with the lowest IPv4 router ID should initiate the
	  connection. For OSPFv3, the node with the lowest IPv6 router
	  ID should initiate the connection.
	</t>
	<t>
	  Each ABR may receive Registration Messages, each containing
	  a prefix. These are retained in a Registration Database
	  (RDB) along with its associated connection information. If a
	  transport connection closes, then all registrations
	  associated with the connection should be removed from the
	  RDB. If an ABR receives a Registration Message requesting a
	  prefix be unregistered, then the prefix should be removed
	  from the RDB for that connection.
	</t>
	<t>
	  If an ABR receives a Registration Message for a prefix that
	  is being injected by a non-attached area, then it should
	  determine the set of ABRs that are advertising that prefix
	  or less specifics and register with those ABRs for that
	  prefix.
	</t>
	<t>
	  Each ABR should monitor its IGP LSDB for changes in node
	  liveness. If an ABR sees an addition to the LSDB, then it is
	  considered an Up Event for that node. If an ABR sees a
	  LSP/LSA time out or become unreachable, then it is
	  considered a Down Event for that node. Up Events and Down
	  Events for non-host prefixes are out of scope for this
	  document.
	</t>
	<t>
	  If an ABR receives a Notification Message with an Up Event
	  for a prefix, then it is considered an Up Event for the
	  prefix.  If an ABR receives a Notification Message with a
	  Down Event for a prefix, then it is considered a Down Event
	  for the prefix.
	</t>
	<t>
	  If an ABR observes an Up Event for a host, it examines its
	  RDB for registrations for that node or for any less specific
	  prefixes. If there are any, then the ABR sends a
	  Notification Message with an Up Event for that host to each
	  node that registered.
	</t>
	<t>
	  Similarly, if an ABR observes a Down Event for a host, it
	  examines its RDB for registrations for that node or for any
	  less specific prefixes. If there are any, then the ABR sends
	  a Notification Message with a Down Event for that host to each
	  node that registered.
	</t>
      </section>

      <section title="Registration Messages">
	<t>
	  A Registration Message has the following format:
	</t>

        <figure align="left">
          <artwork align="left"><![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    |              AFI              |
  +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  |R|  Reserved   |  Prefix len   |         Prefix ...  
  +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  ]]></artwork>
        </figure>

        <t>
	  <list>
            <t>Type: 1 (Registration Message), 1 octet</t>

            <t>Length: 4 + number of octets of prefix, 1 octet</t>

	    <t>AFI: Address Family Identifier <xref target="afireg"/>, 2 octets</t>

            <t>R: 1 bit
	    <list style="hanging" hangIndent="4">
	      <t>0: Register</t>
	      <t>1: Unregister</t>
	    </list>
	    </t>
	    <t>Reserved: must be zero and ignored on receipt, 7 bits</t>

	    <t>
	      Prefix len: number of significant bits in the
	      prefix, 1 octet
	    </t>

	    <t>Prefix: The prefix to register/unregister, n octets </t>
	  </list>
	</t>
      </section>

      <section title="Notification Messages">
	<t>
	  A Notification Message has the following format:
	</t>

        <figure align="left">
          <artwork align="left"><![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    |              AFI              |
  +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  |U|  Reserved   |  Prefix len   |         Prefix ...  
  +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
  ]]></artwork>
        </figure>

        <t>
	  <list>
            <t>Type: 2 (Notification Message), 1 octet</t>

            <t>Length: 3 + number of octets of prefix, 1 octet</t>

	    <t>AFI: Address Family Identifier <xref target="afireg"/>, 2 octets</t>

            <t>U: 1 bit
	    <list style="hanging" hangIndent="4">
	      <t>0: Up Event</t>
	      <t>1: Down Event</t>
	    </list>
	    </t>
	    <t>Reserved: must be zero and ignored on receipt, 7 bits</t>

	    <t>
	      Prefix len: number of significant bits in the
	      prefix, 1 octet
	    </t>
	    
	    <t>Prefix: The prefix to register/unregister, n octets </t>
	  </list>
	</t>
      </section>
    </section>

    <section title="IANA Considerations">
      <section title="IS-IS">
      <t>
	This document requests the following code points from the
	"IS-IS Sub-TLVs for IS-IS Router CAPABILITY TLV" registry.
	<list>
	  <t>Type: TBD 1</t>
	  <t>Description: IS-IS Node Liveness sub-TLV</t>
	  <t>Reference: This document</t>
	</list>
      </t>
      </section>
      <section title="OSPF">
      <t>
	This document requests the following code points from the
	"OSPF Router Information (RI) TLVs" registry:
	<list>
	  <t>Type: TBD 2</t>
	  <t>Description: OSPF Node Liveness Sub-TLV</t>
	  <t>Reference: This document</t>
	</list>
      </t>
      </section>
    </section>

    <section anchor="Security" title="Security Considerations">
      <t>
	This document creates no new security issues. Security of
	transport protocol connections are addressed by the use of
	conventional transport protocol security techniques, such as
	TLS. IGP advertisements are not expected to have privacy, so
	the advertisement of the service is not a security issue.
      </t>
    </section>
  </middle>
  <back>
    <references title="Normative References">
      &rfc793;
      &rfc2119;
      &rfc2328;
      &rfc5246;
      &rfc5340;
      &rfc7981;
      &rfc8174;
      &rfc9000;
      <reference anchor="ISO10589" target="ISO/IEC 10589:2002">
	<front>
	  <title>
	    Intermediate system to Intermediate system routing information exchange protocol for use in conjunction with the Protocol for providing the Connectionless-mode Network Service (ISO 8473)
	  </title>
	  <author fullname="ISO" initials="" surname="ISO">
	    <organization>IANA</organization>
	  </author>
	  <date month="August" year="1987"/>
	</front>
      </reference>
      <reference anchor="afireg"
		 target="https://www.iana.org/assignments/address-family-numbers/address-family-numbers.xhtml#address-family-numbers-2">
	<front>
	  <title>Address Family Numbers</title>
	  <author fullname="IANA" initials="" surname="IANA">
	    <organization>IANA</organization>
	  </author>
	  <date month="November" year="1988"/>
	</front>
      </reference>
    </references>
  </back>
</rfc>

