Neighbor Discovery Protocol

Last updated
Neighbor Discovery Protocol
Communication protocol
ICMP header - General-en.svg
When defining its messages, NDP follows ICMPv6 message format.
PurposeAuxiliary protocol for IPv6
Developer(s) Internet Engineering Task Force
IntroductionMarch 1996;28 years ago (1996-03)
OSI layer Network layer
RFC(s)

The Neighbor Discovery Protocol (NDP), or simply Neighbor Discovery (ND), is a protocol of the Internet protocol suite used with Internet Protocol Version 6 (IPv6). [1] It operates at the internet layer of the Internet model, [2] [3] and is responsible for gathering various information required for network communication, including the configuration of local connections and the domain name servers and gateways. [4]

Contents

The protocol defines five ICMPv6 packet types to perform functions for IPv6 similar to the Address Resolution Protocol (ARP) and Internet Control Message Protocol (ICMP) Router Discovery and Router Redirect protocols for IPv4. It provides many improvements over its IPv4 counterparts (RFC 4861, section 3.1). For example, it includes Neighbor Unreachability Detection (NUD), thus improving robustness of packet delivery in the presence of failing routers or links, or mobile nodes.

The Inverse Neighbor Discovery (IND) protocol extension (RFC 3122) allows nodes to determine and advertise an IPv6 address corresponding to a given link-layer address, similar to Reverse ARP for IPv4.

The Secure Neighbor Discovery Protocol (SEND), a security extension of NDP, uses Cryptographically Generated Addresses (CGA) and the Resource Public Key Infrastructure (RPKI) to provide an alternative mechanism for securing NDP with a cryptographic method that is independent of IPsec. Neighbor Discovery Proxy (ND Proxy) (RFC 4389) provides a service similar to IPv4 Proxy ARP and allows bridging multiple network segments within a single subnet prefix when bridging cannot be done at the link layer.

Functions

NDP defines five ICMPv6 packet types for the purpose of router solicitation, router advertisement, neighbor solicitation, neighbor advertisement, and network redirects. [4]

Router Solicitation (Type 133)
Hosts inquire with Router Solicitation messages to locate routers on an attached link. [5] Routers which forward packets not addressed to them generate Router Advertisements immediately upon receipt of this message rather than at their next scheduled time.
Router Advertisement (Type 134)
Routers advertise their presence together with various link and Internet parameters either periodically, or in response to a Router Solicitation message.
Neighbor Solicitation (Type 135)
Neighbor solicitations are used by nodes to determine the link-layer address of a neighbor, or to verify that a neighbor is still reachable via a cached link-layer address.
Neighbor Advertisement (Type 136)
Neighbor advertisements are used by nodes to respond to a Neighbor Solicitation message, or unsolicited to provide new information quickly.
Redirect (Type 137)
Routers may inform hosts of a better first-hop router for a destination.

These messages are used to provide the following functionality:

IANA maintains a list of all current NDP options as they are published. [8]

Example

Two computers in an office (Computer 1 and Computer 2) are connected to each other in a local area network by Ethernet cables and network switches, with no intervening gateways or routers. Computer 1 has a packet to send to Computer 2. Through DNS, it determines that Computer 2 has the IP address 2001:db8::55.

To send the message, it also requires Computer 2's MAC address. First, Computer 1 uses a cached NDP table to look up 2001:db8::55 for any existing records of Computer 2's MAC address (00:EB:24:B2:05:AC). If the MAC address is found, it sends an Ethernet frame containing the IP packet onto the link with the destination address 00:EB:24:B2:05:AC. If the cache did not produce a result for 2001:db8::55, Computer 1 has to create a solicited-node multicast address by taking the least-significant 24 bits of Computer 2's address and appending them to the prefix ff02::1:ff00:0/104, which is ff02::1:ff00:55, and create a solicited-node multicast MAC address by taking the least-significant 24 bits of Computer 2's solicited-node multicast address and appending them to the prefix 33:33:FF:xx:xx:xx, [9] which is 33:33:FF:00:00:55, and send a neighbor solicitation message requesting an answer for 2001:db8::55 (destination ff02::1:ff00:55 IP address and destination 33:33:FF:00:00:55 MAC address), which is accepted by Computer 2 which is listening on its own solicited-node multicast address on the local network.

Computer 2 responds with a neighbor advertisement message containing its MAC and IP addresses. As part of fielding the request, Computer 2 may insert an entry for Computer 1 into its NDP table for future use.

Computer 1 receives and caches the response information in its NDP table and can now send the packet.

Messages formats

See also

Related Research Articles

An Internet Protocol address is a numerical label such as 192.0.2.1 that is assigned to a device connected to a computer network that uses the Internet Protocol for communication. IP addresses serve two main functions: network interface identification, and location addressing.

<span class="mw-page-title-main">IPv6</span> Version 6 of the Internet Protocol

Internet Protocol version 6 (IPv6) is the most recent version of the Internet Protocol (IP), the communications protocol that provides an identification and location system for computers on networks and routes traffic across the Internet. IPv6 was developed by the Internet Engineering Task Force (IETF) to deal with the long-anticipated problem of IPv4 address exhaustion, and was intended to replace IPv4. In December 1998, IPv6 became a Draft Standard for the IETF, which subsequently ratified it as an Internet Standard on 14 July 2017.

A multicast address is a logical identifier for a group of hosts in a computer network that are available to process datagrams or frames intended to be multicast for a designated network service. Multicast addressing can be used in the link layer, such as Ethernet multicast, and at the internet layer for Internet Protocol Version 4 (IPv4) or Version 6 (IPv6) multicast.

<span class="mw-page-title-main">Subnet</span> Logical subdivision of an IP network

A subnetwork or subnet is a logical subdivision of an IP network. The practice of dividing a network into two or more networks is called subnetting.

Zero-configuration networking (zeroconf) is a set of technologies that automatically creates a usable computer network based on the Internet Protocol Suite (TCP/IP) when computers or network peripherals are interconnected. It does not require manual operator intervention or special configuration servers. Without zeroconf, a network administrator must set up network services, such as Dynamic Host Configuration Protocol (DHCP) and Domain Name System (DNS), or configure each computer's network settings manually.

<span class="mw-page-title-main">Anycast</span> Network addressing and routing methodology

Anycast is a network addressing and routing methodology in which a single IP address is shared by devices in multiple locations. Routers direct packets addressed to this destination to the location nearest the sender, using their normal decision-making algorithms, typically the lowest number of BGP network hops. Anycast routing is widely used by content delivery networks such as web and name servers, to bring their content closer to end users.

The Virtual Router Redundancy Protocol (VRRP) is a computer networking protocol that provides for automatic assignment of available Internet Protocol (IP) routers to participating hosts. This increases the availability and reliability of routing paths via automatic default gateway selections on an IP subnetwork.

Mobile IP is an Internet Engineering Task Force (IETF) standard communications protocol that is designed to allow mobile device users to move from one network to another while maintaining a permanent IP address. Mobile IP for IPv4 is described in IETF RFC 5944, and extensions are defined in IETF RFC 4721. Mobile IPv6, the IP mobility implementation for the next generation of the Internet Protocol, IPv6, is described in RFC 6275.

In computer networking, the ICMP Internet Router Discovery Protocol (IRDP), also called the Internet Router Discovery Protocol, is a protocol for computer hosts to discover the presence and location of routers on their IPv4 local area network. Router discovery is useful for accessing computer systems on other nonlocal area networks. The IRDP is defined by the IETF RFC 1256 standard, with the Internet Control Message Protocol (ICMP) upon which it is based defined in IETF RFC 792. IRDP eliminates the need to manually configure routing information.

In computer networking, the multicast DNS (mDNS) protocol resolves hostnames to IP addresses within small networks that do not include a local name server. It is a zero-configuration service, using essentially the same programming interfaces, packet formats and operating semantics as unicast Domain Name System (DNS). It was designed to work as either a stand-alone protocol or compatibly with standard DNS servers. It uses IP multicast User Datagram Protocol (UDP) packets and is implemented by the Apple Bonjour and open-source Avahi software packages, included in most Linux distributions. Although the Windows 10 implementation was limited to discovering networked printers, subsequent releases resolved hostnames as well. mDNS can work in conjunction with DNS Service Discovery (DNS-SD), a companion zero-configuration networking technique specified separately in RFC 6763.

6over4 is an IPv6 transition mechanism meant to transmit IPv6 packets between dual-stack nodes on top of a multicast-enabled IPv4 network. IPv4 is used as a virtual data link layer on which IPv6 can be run.

The Dynamic Host Configuration Protocol version 6 (DHCPv6) is a network protocol for configuring Internet Protocol version 6 (IPv6) hosts with IP addresses, IP prefixes, default route, local segment MTU, and other configuration data required to operate in an IPv6 network. It is not just the IPv6 equivalent of the Dynamic Host Configuration Protocol for IPv4.

Internet Control Message Protocol version 6 (ICMPv6) is the implementation of the Internet Control Message Protocol (ICMP) for Internet Protocol version 6 (IPv6). ICMPv6 is an integral part of IPv6 and performs error reporting and diagnostic functions.

In computer networking, a link-local address is a unicast network address that is valid only for communications within the subnetwork that the host is connected to. Link-local addresses are most often assigned automatically with a process known as stateless address autoconfiguration (SLAAC) or link-local address autoconfiguration, also known as automatic private IP addressing (APIPA) or auto-IP.

The Router Advertisement Daemon (radvd) is an open-source software product that implements link-local advertisements of IPv6 router addresses and IPv6 routing prefixes using the Neighbor Discovery Protocol (NDP) as specified in RFC 2461.

An IPv6 transition mechanism is a technology that facilitates the transitioning of the Internet from the Internet Protocol version 4 (IPv4) infrastructure in use since 1983 to the successor addressing and routing system of Internet Protocol Version 6 (IPv6). As IPv4 and IPv6 networks are not directly interoperable, transition technologies are designed to permit hosts on either network type to communicate with any other host.

The Neighbor Discovery Protocol Monitor (NDPMon) is a diagnostic software application used by network administrators for monitoring ICMPv6 packets in Internet Protocol version 6 (IPv6) networks. NDPMon observes the local network for anomalies in the function of nodes using Neighbor Discovery Protocol (NDP) messages, especially during the Stateless Address Autoconfiguration. When an NDP message is flagged, it notifies the administrator by writing to the syslog or by sending an email report. It may also execute a user-defined script. For IPv6, NDPMon is an equivalent of Arpwatch for IPv4, and has similar basic features with added attacks detection.

<span class="mw-page-title-main">IPv6 address</span> Label to identify a network interface of a computer or other network node

An Internet Protocol Version 6 address is a numeric label that is used to identify and locate a network interface of a computer or a network node participating in a computer network using IPv6. IP addresses are included in the packet header to indicate the source and the destination of each packet. The IP address of the destination is used to make decisions about routing IP packets to other networks.

An IPv6 packet is the smallest message entity exchanged using Internet Protocol version 6 (IPv6). Packets consist of control information for addressing and routing and a payload of user data. The control information in IPv6 packets is subdivided into a mandatory fixed header and optional extension headers. The payload of an IPv6 packet is typically a datagram or segment of the higher-level transport layer protocol, but may be data for an internet layer or link layer instead.

A solicited-node multicast address is an IPv6 multicast address used by the Neighbor Discovery Protocol to determine the link layer address associated with a given IPv6 address, which is also used to check if an address is already being used by the local-link or not, through a process called DAD. The solicited-node multicast addresses are generated from the host's IPv6 unicast or anycast address, and each interface must have a solicited-node multicast address associated with it.

References

  1. Thomas Narten; Erik Nordmark; William Allen Simpson; Hesham Soliman (1 March 2005). "Neighbor Discovery for IP version 6 (IPv6)". ietf.org. The Internet Engineering Task Force (IETF): 3. Archived from the original on 3 July 2016. Retrieved 2016-06-07.{{cite journal}}: CS1 maint: bot: original URL status unknown (link)
  2. RFC 1970, T. Marten, E. Nordmark, W. Simpson, Neighbor Discovery for IP Version 6 (IPv6), IETF,1996
  3. RFC 1122
  4. 1 2 RFC 4861, Neighbor Discovery for IP version 6 (IPv6), T. Narten et al. (September 2007)
  5. Thomas Narten; Erik Nordmark; William Allen Simpson; Hesham Soliman (1 March 2005). "Neighbor Discovery for IP version 6 (IPv6)". ietf.org. The Internet Engineering Task Force (IETF). p. 9. Archived from the original on 2 September 2007. Retrieved 2 March 2013. Router Discovery: How hosts locate routers that reside on an attached link.
  6. Jeong, Jaehoon Paul; Park, Soohong Daniel; Beloeil, Luc; Madanapalli, Syam (March 2017). IPv6 Router Advertisement Options for DNS Configuration. doi: 10.17487/RFC8106 . RFC 8106.
  7. Jeong, Jaehoon Paul; Park, Soohong Daniel; Beloeil, Luc; Madanapalli, Syam (November 2010). IPv6 Router Advertisement Options for DNS Configuration. doi: 10.17487/RFC6106 . RFC 6106.
  8. "IPv6 Neighbor Discovery Option Formats". Internet Control Message Protocol version 6 (ICMPv6) Parameters. Internet Assigned Numbers Authority. 2017-12-05. Retrieved 2017-12-16.
  9. "IPv6 Real-Time Usage of IEEE 802.16: Problem Statement". www.ietf.org. Retrieved 2023-09-22.