<?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-bonica-intarea-eping-00" ipr="trust200902">
  <front>
    <title abbrev="Extended Ping (eping)">Extended Ping (eping)</title>

    <author fullname="Ron Bonica" initials="R." surname="Bonica">
      <organization>Juniper Networks</organization>

      <address>
        <postal>
          <street>2251 Corporate Park Drive</street>

          <city>Herndon</city>

          <code>20171</code>

          <region>Virginia</region>

          <country>USA</country>
        </postal>

        <email>rbonica@juniper.net</email>
      </address>
    </author>

    <author fullname="Reji Thomas" initials="R." surname="Thomas">
      <organization>Juniper Networks</organization>

      <address>
        <postal>
          <street>Elnath-Exora Business Park Survey</street>

          <city>Bangalore</city>

          <region>Kanata</region>

          <code>560103</code>

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

        <email>rejithomas@juniper.net</email>
      </address>
    </author>

    <date day="23" month="June" year="2016"/>

    <area>Internet</area>

    <workgroup>INTAREA</workgroup>

    <keyword>Ping</keyword>

    <keyword>ICMP</keyword>

    <abstract>
      <t>This document describes a new diagnostic tool called Extended Ping
      (eping). Network operators execute eping to determine whether a remote
      interface is active. In this respect, eping is similar to ping. Eping
      differs from ping in that it does not require network reachability
      between itself and remote interface whose status is being queried.</t>

      <t>Eping relies on two new ICMP messages, called Extended Echo and
      Extended Echo Reply. Both ICMP messages are defined herein.</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">RFC 2119</xref>.</t>
    </note>
  </front>

  <middle>
    <section title="Problem Statement">
      <t>Network operators use <xref target="RFC2151">ping</xref> to determine
      whether a remote interface is alive. Ping sends an <xref
      target="RFC0792">ICMP </xref> <xref target="RFC4443"> </xref> Echo
      message to the interface being probed and waits for an ICMP Echo Reply.
      If ping receives the expected ICMP Echo Reply, it reports that interface
      is alive.</t>

      <t>In order for the Echo message to reach the probed interface, the
      probed interface must be addressed appropriately. IP addresses are
      scoped as follows:</t>

      <t><list style="symbols">
          <t><xref target="RFC4291">Global</xref></t>

          <t><xref target="RFC1918">Private </xref> <xref
          target="RFC4193"/></t>

          <t><xref target="RFC3927"> Link-local </xref> <xref
          target="RFC4291"/></t>
        </list></t>

      <t>Global addresses are the most widely scoped. A globally addressed
      interface can be reached from any node on the Internet. By contrast,
      link-local addresses are the least widely scoped. An interface whose
      only address is link-local can be reached from on-link interfaces
      only.</t>

      <t>Network operators seek to decrease their dependence on widely-scoped
      interface addressing. For example:</t>

      <t><list style="symbols">
          <t>The operator of an IPv4 network currently assigns global
          addresses to all interfaces. In order to conserve scarce IPv4
          address space, this operator seeks to renumber selected interfaces
          with private addresses.</t>

          <t>The operator of an IPv4 network currently assigns private
          addresses to all interfaces. In order to achieve operational
          efficiencies, this operator seeks to leave selected interfaces
          unnumbered.</t>

          <t>The operator of an IPv6 network currently assigns global
          addresses to all interfaces. In order to achieve operational
          efficiencies, this operator seeks to allow selected interfaces to be
          automatically configured with link-local addresses.</t>
        </list></t>

      <t>When a network operator renumbers an interface, replacing a more
      widely-scoped address with a less widely-scope address, the operator
      also reduces the number of nodes from which ping can probe the
      interface. Furthermore, when a network operator removes all addresses
      from an interface, leaving it unnumbered, the operator makes that
      interface totally inaccessible to ping. Therefore, many network
      operators who rely on ping remain dependant upon widely-scoped interface
      addressing.</t>

      <t>This document describes a new diagnostic tool called Extended Ping
      (eping). Network operators use eping to determine whether a remote
      interface is active. In this respect, eping is similar to ping. Eping
      differs from ping in that it does not require reachability between the
      probing node and the probed interface. Or, said another way, eping does
      not require reachability between the node upon which it executes and the
      interface whose status is being queried.</t>

      <t>Eping relies on two new ICMP messages, called Extended Echo and
      Extended Echo Reply. The Extended Echo message makes a semantic
      distinction between the destination interface and the probed interface.
      The destination interface is the interface to which the Extended Echo
      message is delivered. It must be reachable from the probing node. The
      probed interface is the interface whose status is being queried. It does
      not need to be reachable from the probing node. However, the destination
      and probed interfaces must be local to one another (i.e., the same node
      must support both interfaces).</t>

      <t>Because the Extended Echo message makes a distinction between the
      destination and probed interfaces, eping can probe every interface on a
      node if it can reach any node on the node. In many cases, this allows
      network operators to decrease their dependence on widely-scoped
      interface addressing.</t>

      <t>This document is divided into sections, with <xref
      target="ExtendedEcho"/> describing the Extended Echo message and <xref
      target="ExtenedEchoReply"/> describing the Extended Echo Reply message.
      <xref target="proc"/> describes how the probed node processes the
      Extended Echo message and <xref target="application"/> describes the
      eping application.</t>
    </section>

    <section anchor="ExtendedEcho" title="ICMP Extended Echo">
      <t>The ICMP Extended Echo message is applicable to both ICMPv4 and
      ICMPv6. Like any ICMP message, the ICMP Extended Echo message is
      encapsulated in an IP header. The ICMPv4 version of the Extended Echo
      message is encapsulated in an IPv4 header, while the ICMPv6 version is
      encapsulated in an IPv6 header.</t>

      <t><xref target="ICMPEchoFIG"/> depicts the ICMP Extended Echo
      message.</t>

      <t><figure align="center" anchor="ICMPEchoFIG"
          title="ICMP Extened Echo Message">
          <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      |     Code      |          Checksum             |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |           Identifier          |        Sequence Number        |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |   ICMP Extensions ........
       
 

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

      <t/>

      <t>IP Source Address: Identifies an interface on the probing node.</t>

      <t>IP Destination Address: Identifies the destination interface (i.e.,
      the interface to which this message will be delivered).</t>

      <t>Type: Extended Echo (TBD. Value to be assigned by IANA.)</t>

      <t>Code: 0</t>

      <t>Checksum: For ICMPv4, see RFC 792. For ICMPv6, see RFC 4443.</t>

      <t>Identifier: An identifier to aid in matching Extended Echo Replies to
      this Extended Echo Request. May be zero.</t>

      <t>Sequence Number: A sequence number to aid in matching Extended Echo
      Replies to this Extended Echo Request. May be zero.</t>

      <t>If the destination interface is different from the probed interface,
      the Extended Echo message MUST include ICMP Extensions. ICMP Extensions
      MUST include the <xref target="RFC4884">ICMP Extension Structure
      Header</xref> and the <xref target="IntIdObj">Interface Identification
      Object</xref>.</t>

      <t>If the Extended Echo message does not include the Interface
      Identification Object, the destination and probed interfaces are
      understood to be the same.</t>

      <section anchor="IntIdObj" title="Interface Identification Object">
        <t>The Interface Identification Object identifies the probed
        interface. It includes an ICMP Object Header (RFC 4884) and at least
        one sub-TLV.</t>

        <t>The ICMP Object Header contains Class-Num and C-Type fields. The
        Class-Num field MUST be set to Interface Identification Class (value
        to be assigned by IANA). The C-Type indicates how the probed interface
        is identified. The C-Type value MUST be one of the following:</t>

        <t><list style="symbols">
            <t>By Address (value to be assigned by IANA)</t>

            <t>By ifName (value to be assigned by IANA)</t>

            <t>By ifIndex (value to be assigned by IANA)</t>
          </list></t>

        <t>See <xref target="RFC2863"/> for a definition of the IfName and
        IfIndex.</t>

        <t>If C-type equals "By Address", the Identification Object payload
        MUST be an Interface IP Address Sub-Object. If C-type equals "By
        ifName", the Identification Object payload MUST be an Interface IP
        Name Sub-Object. Both of these are defined in <xref
        target="RFC5837"/>. If C-type equals "By ifIndex, the Identification
        Object payload MUST be a 32-bit ifIndex.</t>

        <t>If the probed interface is identified by address, its address
        family does not need to be the same as that of the destination
        address. For example, the probed interface can be identified by its
        Ethernet address while the destination address is identified by an
        IPv4 address.</t>

        <t>By default, implementations SHOULD NOT support probing by ifName.
        See <xref target="security"/> for details.</t>
      </section>
    </section>

    <section anchor="ExtenedEchoReply" title="ICMP Extended Echo Reply">
      <t>The ICMP Extended Echo Reply message is applicable to both ICMPv4 and
      ICMPv6. Like any ICMP message, the ICMP Extended Echo Reply message is
      encapsulated in an IP header. The ICMPv4 version of the Extended Echo
      Reply message is encapsulated in an IPv4 header, while the ICMPv6
      version is encapsulated in an IPv6 header.</t>

      <t><xref target="ICMPEchoReplyFIG"/> depicts the ICMP Extended Echo
      Reply message.</t>

      <t><figure align="center" anchor="ICMPEchoReplyFIG"
          title="ICMP Extened Echo Reply Message">
          <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      |     Code      |          Checksum             |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |           Identifier          |        Sequence Number        |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |   ICMP Extensions ........ 

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

      <t>IP source address: Identifies the interface to which the
      corresponding ICMP Extended Echo message was sent</t>

      <t>IP destination address: Identifies the interface from which the
      corresponding ICMP Extended Echo message was sent</t>

      <t>Type: Extended Echo Reply (TBD. Value to be assigned by IANA.)</t>

      <t>Code: Indicates operational status of probed interface. Defined
      values are:</t>

      <t><list style="symbols">
          <t>Inactive (value to be assigned by IANA)</t>

          <t>Active (value to be assigned by IANA)</t>

          <t>Interface_does_not_exist (value to be assigned by IANA)</t>

          <t>Query_not_supported (value to be assigned by IANA)</t>
        </list></t>

      <t>Checksum: For ICMPv4, see RFC 792. For ICMPv6, see RFC 4443.</t>

      <t>Identifier: An identifier to aid in matching Extended Echo Replies to
      this Extended Echo Request. May be zero.</t>

      <t>Sequence Number: A sequence number to aid in matching Extended Echo
      Replies to this Extended Echo Request. May be zero.</t>

      <t>ICMP Extensions: ICMP Extensions are optional. Currently, no
      extensions are specified for the ICMP Extended Echo Reply message.
      However, ICMP Extensions may be defined in the future to carry
      additional OAM information.</t>
    </section>

    <section anchor="proc"
             title="ICMP Extended Echo and Extended Echo Reply Processing">
      <t>When a node receives an ICMPv4 Extended Echo, it MUST format an ICMP
      Extended Echo Reply as follows:</t>

      <t><list style="symbols">
          <t>Don't Fragment flag (DF) is 1</t>

          <t>More Fragments flag is 0</t>

          <t>Fragment Offset is 0</t>

          <t>TTL is 255</t>

          <t>Protocol is ICMP</t>
        </list></t>

      <t>When a node receives an ICMPv6 Extended Echo, it MUST format an
      ICMPv6 Extended Echo Reply as follows:</t>

      <t><list style="symbols">
          <t>Hop Limit is 255</t>

          <t>Next Header is ICMPv6</t>

          <t>Flow Label is 0</t>
        </list></t>

      <t>In either case, the responding node MUST:</t>

      <t><list style="symbols">
          <t>Copy the source address from the Extended Echo message to the
          destination address of the Extended Echo Reply</t>

          <t>Copy the destination address from the Extended Echo message to
          the source address of the Extended Echo Reply</t>

          <t>Set the DiffServ codepoint to <xref
          target="RFC4594">CS0</xref></t>

          <t>Set the ICMP Type to Extended Echo Reply</t>

          <t>Copy the Identifier from the Extended Echo message to the
          Extended Echo Reply</t>

          <t>Copy the sequence number from the Extended Echo message to the
          Extended Echo Reply</t>

          <t>Set the code appropriately</t>

          <t>Append ICMP Extensions as required</t>

          <t>Set the checksum appropriately</t>
        </list>The following rules govern how the Code should be set:</t>

      <t><list style="symbols">
          <t>If the query type is not supported, set the Code to
          Query_not_supported</t>

          <t>Otherwise, if the interface does not exist, set the Code to
          Interface_does_not_exist</t>

          <t>Otherwise, if the destination interface is in one security domain
          and the probed interface is in another security domain, set the Code
          to Interface_does_not_exist. Virtual Private Networks are examples
          of security domains.</t>

          <t>Otherwise, if the probed inactive, set the Code to Inactive</t>

          <t>Otherwise, set the code to Active</t>
        </list></t>
    </section>

    <section anchor="application" title="The Eping Application">
      <t>The eping application accepts input parameters, sets a counter and
      enters a loop to be exited when the counter is equal to zero. On each
      iteration of the loop, eping emits an ICMP Extended Echo, decrements the
      counter, sets a timer, waits for the timer to expire. If an expected
      ICMP Extended Echo Reply arrives while eping is waiting for the timer to
      expire, eping relays information returned by that message to its user.
      However, on each iteration of the loop, eping waits for the timer to
      expire, regardless of whether an Extended Echo Reply message
      arrives.</t>

      <t>Eping accepts the following parameters:</t>

      <t><list style="symbols">
          <t>Count</t>

          <t>Wait</t>

          <t>Source Interface Address</t>

          <t>Hop Count</t>

          <t>Destination Interface Address</t>

          <t>Probed Interface Identifier</t>
        </list></t>

      <t>Count is a positive integer whose default value is 3. Count
      determines the number of times that eping iterates through the
      above-mentioned loop.</t>

      <t>Wait is a positive integer whose minimum and default values are 1.
      Wait determines the duration of the above mentioned timer, measured in
      seconds.</t>

      <t>Source Interface Address specifies the source address of ICMP
      Extended Echo.</t>

      <t>The destination Interface Address identifies the interface to which
      the ICMP Extended Echo message is sent. It can be an IPv4 address or an
      IPv6 address. If it is an IPv4 address, eping emits an ICMPv4 message.
      If it is an IPv6 address, eping emits an ICMPv6 message.</t>

      <t>The probed interface is the interface whose status is being queried.
      If the probed interface identifier is not specified, the destination and
      probed interfaces are understood to be identical. If the probed
      interface identifier is specified, it can be:</t>

      <t><list style="symbols">
          <t>an interface name</t>

          <t>an interface description</t>

          <t>an address from any address family (e.g., IPv4, IPv6, MAC)</t>

          <t>an ifIndex</t>
        </list></t>

      <t>The probed interface identifier can have any scope. For example, the
      probed interface identifier can be:</t>

      <t><list style="symbols">
          <t>an IPv6 address, whose scope is global</t>

          <t>an IPv6 address, whose scope is link-local</t>

          <t>an interface name, whose scope is node-local</t>

          <t>an interface description, whose scope is node-local</t>

          <t>an ifIndex, whose scope is node-local</t>
        </list></t>

      <t>If the probed interface identifier is an address, it does not need to
      be of the same address family as the destination interface address. For
      example, eping accepts an IPv4 destination interface address and an IPv6
      probed interface identifier.</t>
    </section>

    <section anchor="IANA" title="IANA Considerations">
      <t>This document requests the following actions from IANA:</t>

      <t><list style="symbols">
          <t>Add an entry to the "ICMP Type Number" registry, representing the
          Extended Echo. This entry has one code (0).</t>

          <t>Add an entry to the "ICMP Type Number" registry, representing the
          Extended Echo Reply. This entry has the following codes: Inactive,
          Active, Interface_does_not_exist, and Query_not_supported.</t>

          <t>Add an entry to the "ICMPv6 Type Number" registry, representing
          the Extended Echo. This entry has the following codes: Inactive,
          Active, Interface_does_not_exist, and Query_not_supported.</t>

          <t>Add an entry to the "ICMPv6 Type Number" registry, representing
          the Extended Echo Reply. This entry has one code (0).</t>

          <t>Add an entry to the "ICMP Extension Object Classes and
          sub-classes" registry, representing the Interface Identification
          Class. This Class includes the sub-classes "By Address", "By Name" ,
          and "By ifIndex".</t>

          <t/>
        </list></t>

      <t>Note to RFC Editor: this section may be removed on publication as an
      RFC.</t>
    </section>

    <section anchor="security" title="Security Considerations">
      <section title="Probing by ifName and ifDescr">
        <t>Many implementations encode the following information in an
        ifName:</t>

        <t><list style="symbols">
            <t>Interface type (e.g.., Gigabit Ethernet, SONET, T1)</t>

            <t>Location on chassis (i.e., slot identifier)</t>

            <t>Location on line card (i.e., port identifier)</t>

            <t>Location on port (i.e., logical port identifier)</t>
          </list>While an operator may have a requirement to probe ports using
        eping, that operator may not want to expose the above mentioned
        information. Therefore, by default, implementations SHOULD NOT support
        probing by ifName. However, probing by ifName can be enabled through
        configuration.</t>
      </section>
    </section>

    <section anchor="Acknowledgements" title="Acknowledgements">
      <t>TBD</t>
    </section>
  </middle>

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

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

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

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

      <?rfc ?>

      <?rfc ?>

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

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

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

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

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

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

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

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

      <?rfc ?>
    </references>

    <section title="An Appendix">
      <t/>
    </section>
  </back>
</rfc>
