Gratuitous Neighbor Discovery: Creating Neighbor Cache Entries on First-Hop Routers
draft-ietf-6man-grand-02
The information below is for an old version of the document.
Document | Type |
This is an older version of an Internet-Draft that was ultimately published as RFC 9131.
|
|
---|---|---|---|
Author | Jen Linkova | ||
Last updated | 2020-09-13 | ||
Replaces | draft-linkova-6man-grand | ||
RFC stream | Internet Engineering Task Force (IETF) | ||
Formats | |||
Reviews |
GENART Last Call review
(of
-04)
by Dan Romascanu
Ready w/nits
IOTDIR Last Call review
(of
-04)
by Carles Gomez
Ready w/nits
TSVART Last Call review
(of
-04)
by Michael Scharf
Ready w/nits
|
||
Additional resources | Mailing list discussion | ||
Stream | WG state | Submitted to IESG for Publication | |
Document shepherd | Bob Hinden | ||
Shepherd write-up | Show Last changed 2020-08-12 | ||
IESG | IESG state | Became RFC 9131 (Proposed Standard) | |
Consensus boilerplate | Yes | ||
Telechat date | (None) | ||
Responsible AD | Erik Kline | ||
Send notices to | Bob Hinden <bob.hinden@gmail.com> |
draft-ietf-6man-grand-02
Linkova Expires March 17, 2021 [Page 8] Internet-Draft Gratuitous ND September 2020 1. The rightful owner of the address has not been using it for communication. 2. The rightful owner just started sending packets from that address but the router has not received any return traffic yet. The impact on the rightful owner's traffic flows would be different in those cases. 5.3.1. The Rightful Owner Is Not Sending Packets From The Address In this scenario the following events are expected to happen: 1. The host configures the address and sets its state to Optimistic. 2. The host sends an unsolicited NA with the Override flag set to zero and starts sending traffic from the Optimistic address. 3. The router creates a STALE entry for the address and the host link-layer address. 4. The host starts DAD and detects the address duplication. 5. The router receives the return traffic for the duplicated address. As the NC entry is STALE it sends traffic using that entry, changes it to DELAY and wait up to DELAY_FIRST_PROBE_TIME ([RFC4861]) seconds. 6. The router changes the NC entry state to PROBE and sends up to MAX_UNICAST_SOLICIT ([RFC4861]) unicast NSes separated by RetransTimer milliseconds ([RFC4861]) to the host link-layer address. 7. As the host has detected the address conflict already it does not respond to the unicast NSes. 8. The router sends a multicast NS to the solicited node multicast address, the rightful owner responds and the router NC entry is updated with the rightful owner link-local address. The rightful owner is not experiencing any disruption as it does not send/receive any traffic. If after step 7 the router keeps receiving any return traffic for communication initiated at step 2, those packets would be forwarded to the rightful owner. However the same behaviour would be observed if changes proposed in this document are implemented: if the host starts sending packets from its Optimistic address but then changed the address state to Duplicated, almost all return traffic would be forwarded to the rightful owner of the said Linkova Expires March 17, 2021 [Page 9] Internet-Draft Gratuitous ND September 2020 address. Therefore it's safe to conclude that the proposed changes do not cause any disruption for the rightful owner. 5.3.2. The Rightful Owner Has Started Sending Packets From The Address In this scenario the following events are happening: 1. The rightful owner starts sending traffic from the address (e.g. the address has just been configured or has not been recently used). 2. The host configures the address and sets its state to Optimistic. 3. The host sends an unsolicited NA with the Override flag set to zero and starts sending traffic from the Optimistic address. 4. The router creates a STALE entry for the address and the host link-layer address. 5. The host starts DAD and detects the address duplication. 6. The router receives the return traffic flows for both the rightful owner of the duplicated address and the new host. As the NC entry is STALE it sends traffic using that entry, changes it to DELAY and wait up to DELAY_FIRST_PROBE_TIME ([RFC4861]) seconds. 7. The router changes the NC entry state to PROBE and sends up to MAX_UNICAST_SOLICIT ([RFC4861]) unicast NSes separated by RetransTimer milliseconds ([RFC4861]) to the host link-layer address. 8. As the host has detected the address conflict already it does not respond to the unicast NSes. 9. The router sends a multicast NS to the solicited node multicast address, the rightful owner responds and the router NC entry is updated with the rightful owner link-local address. As a result the traffic for the address rightful owner would be sent to the host with the duplicated address instead. The duration of the disruption can be estimated as DELAY_FIRST_PROBE_TIME*1000 + (MAX_UNICAST_SOLICIT - 1)*RetransTimer milliseconds. As per the constants defined in Section 10 of [RFC4861] this interval is equal to 5*1000 + (3 - 1)*1000 = 7000ms or 7 seconds. Linkova Expires March 17, 2021 [Page 10] Internet-Draft Gratuitous ND September 2020 However it should be noted that the probability of such scenario is rather low as it would require the following things to happen almost simultaneously (within tens of milliseconds): o One host starts using a new IPv6 address and sending traffic. o Another host configures the same IPv6 address in Optimistic mode before the router receives the return traffic for the first host. 6. Modifications to RFC-Mandated Behavior All normative text in this memo is contained in this section. 6.1. Modification to RFC4861 Neighbor Discovery for IP version 6 (IPv6) 6.1.1. Modification to the section 7.2.5 This document proposes the following changes to the section 7.2.5 of [RFC4861]: ------------------------------------------------------------------ OLD TEXT: When a valid Neighbor Advertisement is received (either solicited or unsolicited), the Neighbor Cache is searched for the target's entry. If no entry exists, the advertisement SHOULD be silently discarded. There is no need to create an entry if none exists, since the recipient has apparently not initiated any communication with the target. NEW TEXT: When a valid Neighbor Advertisement is received (either solicited or unsolicited), the Neighbor Cache is searched for the target's entry. If no entry exists, hosts SHOULD silently discard the advertisement. There is no need to create an entry if none exists, since the recipient has apparently not initiated any communication with the target. Routers SHOULD create a new entry for the target address with the link-layer address set to the Target link-layer address option (if supplied). The entry its reachability state MUST also be set to STALE. If the received Neighbor Advertisement does not contain the Target link-layer address option the advertisement SHOULD be silently discarded. ------------------------------------------------------------------ Linkova Expires March 17, 2021 [Page 11] Internet-Draft Gratuitous ND September 2020 6.1.2. Modification to the section 7.2.6 This document proposes the following changes to the section 7.2.6 of [RFC4861]: OLD TEXT: Also, a node belonging to an anycast address MAY multicast unsolicited Neighbor Advertisements for the anycast address when the node's link-layer address changes. NEW TEXT: Also, a node belonging to an anycast address MAY multicast unsolicited Neighbor Advertisements for the anycast address when the node's link-layer address changes. A node may also wish to notify its first-hop routers when it configures a new global IPv6 address so the routers can proactively populate their neighbor caches with the corresponding entries. In such cases a node SHOULD send up to MAX_NEIGHBOR_ADVERTISEMENT Neighbor Advertisement messages. If the address is preferred then the Override flag SHOULD NOT be set. If the address is in the Optimistic state then the Override flag MUST NOT be set. The destination address SHOULD be set to the all-routers multicast address. These advertisements MUST be separated by at least RetransTimer seconds. The first advertisement SHOULD be sent as soon as one of the following events happens: o if Optimistic DAD [RFC4429] is used: a new Optimistic address is assigned to the node interface. o if Optimistic DAD is not used: an address changes the state from tentative to preferred. ------------------------------------------------------------------ 7. Solutions Considered but Discarded There are other possible approaches to address the problem, for example: o Just do nothing. o Migrating from the "reactive" Neighbor Discovery ([RFC4861]) to the registration-based mechanisms ([RFC8505]). Linkova Expires March 17, 2021 [Page 12] Internet-Draft Gratuitous ND September 2020 o Creating new entries in routers Neighbor Cache by gleaning from Neighbor Discovery DAD messages. o Initiates bidirectional communication from the host to the router using the host GUA. o Making the probing logic on hosts more robust. o Increasing the buffer size on routers. o Transit dataplane traffic from an unknown address (an address w/o the corresponding neighbor cache entry) triggers an address resolution process on the router. It should be noted that some of those options are already implemented by some vendors. The following sections discuss those approaches and the reasons they were discarded. 7.1. Do Nothing One of the possible approaches might be to declare that everything is working as intended and let the upper-layer protocols to deal with packet loss. The obvious drawbacks include: o Unhappy users. o Many support tickets. o More resistance to deploy IPv6 and IPv6-Only networks. 7.2. Change to the Registration-Based Neighbor Discovery The most radical approach would be to move away from the reactive ND as defined in [RFC4861] and expand the registration-based ND ([RFC6775], [RFC8505]) used in Low-Power Wireless Personal Area Networks (6LoWPANs) to the rest of IPv6 deployments. This option requires some investigation and discussions and seems to be excessive for the problem described in this document. 7.3. Host Sending NS to the Router Address from Its GUA The host could force creating a STALE entry for its GUA in the router ND cache by sending the following Neighbor Solicitation message: o The NS source address is the host GUA. o The destination address is the default router IPv6 address. Linkova Expires March 17, 2021 [Page 13] Internet-Draft Gratuitous ND September 2020 o The Source Link-Layer Address option contains the host link-layer address. o The target address is the host default router address (the default router address the host received in the RA). The main disadvantages of this approach are: o Would not work for Optimistic addresses as section 2.2 of [RFC4429] explicitly prohibits sending Neighbor Solicitations from an Optimistic Address. o If first-hop redundancy is deployed in the network, the NS would reach the active router only, so all backup routers (or all active routers except one) would not get their neighbor cache updated. o Some wireless devices are known to alter ND packets and perform various non-obvious forms of ND proxy actions. In some cases, unsolicited NAs might not even reach the routers. 7.4. Host Sending Router Solicitation from its GUA The host could send a router solicitation message to 'all routers' multicast address, using its GUA as a source. If the host link-layer address is included in the Source Link-Layer Address option, the router would create a STALE entry for the host GUA as per the section 6.2.6 of [RFC4861]. However, this approach can not be used if the GUA is in optimistic state: section 2.2 of [RFC4429] explicitly prohibits using an Optimistic Address as the source address of a Router Solicitation with a SLLAO as it might disrupt the rightful owner of the address in the case of a collision. So for the optimistic addresses the host can send an RS without SLLAO included. In that case the router may respond with either a multicast or a unicast RA (only the latter would create a cache entry). This approach has the following drawbacks: o If the address is in the Optimistic state the RS can not contain SLLAO. As a result the router would only create a cache entry if solicited RAs are sent as unicast. Routers sending solicited RAs as multicast would not create a new cache entry as they do not need to send a unicast packet back to the host. o There might be a random delay between receiving an RS and sending a unicast RA back (and creating a cache entry) which might undermine the idea of creating the cache entry proactively. Linkova Expires March 17, 2021 [Page 14] Internet-Draft Gratuitous ND September 2020 o Some wireless devices are known to intercept ND packets and perform various non-obvious forms of ND proxy actions. In some cases the RS might not even reach the routers. 7.5. Routers Populating Their Caches by Gleaning From Neighbor Discovery Packets Routers may be able to learn about new addresses by gleaning from the DAD Neighbor Solicitation messages. The router could listen to all solicited node multicast address groups and upon receiving a Neighbor Solicitation from the unspecified address search its Neighbor Cache for the solicitation's Target Address. If no entry exists, the router may create an entry, set its reachability state to 'INCOMPLETE' and start the address resolution for that entry. The same solution was proposed in [I-D.halpern-6man-nd-pre-resolve-addr]. Some routing vendors support such optimization already. However, this approach has a number of drawbacks and therefore should not be used as the only solution: o Routers need to receive all multicast Neighbor Discovery packets which might negatively impact the routers CPU. o If the router starts the address resolution as soon as it receives the DAD Neighbor Solicitation the host might be still performing DAD and the target address might be tentative. In that case, the host SHOULD silently ignore the received Neighbor Solicitation from the router as per the Section 5.4.3 of [RFC4862]. As a result the router might not be able to complete the address resolution before the return traffic arrives. 7.6. Initiating Hosts-to-Routers Communication The host may force the router to start address resolution by sending a data packet such as ping or traceroute to its default router link- local address, using the GUA as a source address. As the RTT to the default router is lower than RTT to any off-link destinations it's quite likely that the router would start the neighbor discovery process for the host GUA before the first packet of the returning traffic arrives. This approach has the following drawbacks: o Data packets to the router link-local address could be blocked by security policy or control plane protection mechanism. Linkova Expires March 17, 2021 [Page 15] Internet-Draft Gratuitous ND September 2020 o It introduces an additional overhead for routers control plane (in addition to processing ND packets, the data packet needs to be processed as well). o Unless the data packet is sent to 'all routers' ff02::2 multicast address, if the network provides a first-hop redundancy then only the active router would create a new cache entry. 7.7. Transit Dataplane Traffic From a New Address Triggering Address Resolution When a router receives a transit packet, it might check the presence of the neighbor cache entry for the packet source address and if the entry does not, exist start address resolution process. This approach does ensure that a Neighbor Cache entry is proactively created every time a new, previously unseen GUA is used for sending offlink traffic. However this approach has a number of limitations, in particular: o If traffic flows are asymmetrical the return traffic might not transit the same router as the original traffic which triggered the address resolution. So the neighbor cache entry is created on the "wrong" router, not the one which actually needs the neighbor cache entry for the host address. o The functionality needs to be limited to explicitly configured networks/interfaces, as the router needs to distinguish between onlink addresses (ones the router needs to have Neighbor Cache entries for) and the rest of the address space. o Implementing such functionality is much more complicated than all other solutions as it would involve complex data-control planes interaction. 8. IANA Considerations This memo asks the IANA for no new parameters. 9. Security Considerations One of the potential attack vectors to consider is a cache spoofing when the attacker might try to install a cache entry for the victim's IPv6 address and the attacker's Link-Layer address. However it should be noted that this document does not propose any changes for the scenario when the ND cache for the given IPv6 address already exists. Therefore it is not possible for the attacker to override any existing cache entry. Linkova Expires March 17, 2021 [Page 16] Internet-Draft Gratuitous ND September 2020 A malicious host could attempt to exhaust the neighbor cache on the router by creating a large number of STALE entries. However this attack vector is not new and this document does not increase the risk of such an attack: the attacker could do it, for example, by sending a NS or RS packet with SLLAO included. All recommendations from [RFC6583] still apply. Announcing a new address to all-routers multicast address may inform an on-link attacker about IPv6 addresses assigned to the host. However hiding information about the specific IPv6 address should not be considered a security measure as such information is usually disclosed via DAD to all nodes anyway. Network administrators can also mitigate this issue by enabling MLD snooping on the link-layer devices to prevent IPv6 link-local multicast packets being flooded to all onlink nodes. If peer-to-peer onlink communications are not desirable for the given network segment they should be prevented by proper layer2 security mechanisms. Therefore the risk of allowing hosts to send unsolicited Neighbor Advertisements to all-routers multicast address is low. It should be noted that the proposed mechanism allows hosts to proactively inform their routers about global IPv6 addresses existing on-link. Routers could use that information to distinguish between used and unused addresses to mitigate ND cache exhaustion DoS attacks described in Section 4.3.2 [RFC3756] and [RFC6583]. 10. Acknowledgements Thanks to the following people (in alphabetical order) for their comments, review and feedback: Mikael Abrahamsson, Stewart Bryant, Lorenzo Colitti, Owen DeLong, Igor Gashinsky, Fernando Gont, Tatuya Jinmei, Erik Kline, Warren Kumari, Barry Leiba, Jordi Palet Martinez, Erik Nordmark, Michael Richardson, Mark Smith, Dave Thaler, Pascal Thubert, Loganaden Velvindron, Eric Vyncke. 11. References 11.1. Normative References [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, DOI 10.17487/RFC2119, March 1997, <https://www.rfc-editor.org/info/rfc2119>. [RFC4291] Hinden, R. and S. Deering, "IP Version 6 Addressing Architecture", RFC 4291, DOI 10.17487/RFC4291, February 2006, <https://www.rfc-editor.org/info/rfc4291>. Linkova Expires March 17, 2021 [Page 17] Internet-Draft Gratuitous ND September 2020 [RFC4429] Moore, N., "Optimistic Duplicate Address Detection (DAD) for IPv6", RFC 4429, DOI 10.17487/RFC4429, April 2006, <https://www.rfc-editor.org/info/rfc4429>. [RFC4861] Narten, T., Nordmark, E., Simpson, W., and H. Soliman, "Neighbor Discovery for IP version 6 (IPv6)", RFC 4861, DOI 10.17487/RFC4861, September 2007, <https://www.rfc-editor.org/info/rfc4861>. [RFC4862] Thomson, S., Narten, T., and T. Jinmei, "IPv6 Stateless Address Autoconfiguration", RFC 4862, DOI 10.17487/RFC4862, September 2007, <https://www.rfc-editor.org/info/rfc4862>. [RFC6775] Shelby, Z., Ed., Chakrabarti, S., Nordmark, E., and C. Bormann, "Neighbor Discovery Optimization for IPv6 over Low-Power Wireless Personal Area Networks (6LoWPANs)", RFC 6775, DOI 10.17487/RFC6775, November 2012, <https://www.rfc-editor.org/info/rfc6775>. [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, May 2017, <https://www.rfc-editor.org/info/rfc8174>. [RFC8305] Schinazi, D. and T. Pauly, "Happy Eyeballs Version 2: Better Connectivity Using Concurrency", RFC 8305, DOI 10.17487/RFC8305, December 2017, <https://www.rfc-editor.org/info/rfc8305>. [RFC8505] Thubert, P., Ed., Nordmark, E., Chakrabarti, S., and C. Perkins, "Registration Extensions for IPv6 over Low-Power Wireless Personal Area Network (6LoWPAN) Neighbor Discovery", RFC 8505, DOI 10.17487/RFC8505, November 2018, <https://www.rfc-editor.org/info/rfc8505>. 11.2. Informative References [I-D.halpern-6man-nd-pre-resolve-addr] Chen, I. and J. Halpern, "Triggering ND Address Resolution on Receiving DAD-NS", draft-halpern-6man-nd-pre-resolve- addr-00 (work in progress), January 2014. [RFC3756] Nikander, P., Ed., Kempf, J., and E. Nordmark, "IPv6 Neighbor Discovery (ND) Trust Models and Threats", RFC 3756, DOI 10.17487/RFC3756, May 2004, <https://www.rfc-editor.org/info/rfc3756>. Linkova Expires March 17, 2021 [Page 18] Internet-Draft Gratuitous ND September 2020 [RFC4541] Christensen, M., Kimball, K., and F. Solensky, "Considerations for Internet Group Management Protocol (IGMP) and Multicast Listener Discovery (MLD) Snooping Switches", RFC 4541, DOI 10.17487/RFC4541, May 2006, <https://www.rfc-editor.org/info/rfc4541>. [RFC4941] Narten, T., Draves, R., and S. Krishnan, "Privacy Extensions for Stateless Address Autoconfiguration in IPv6", RFC 4941, DOI 10.17487/RFC4941, September 2007, <https://www.rfc-editor.org/info/rfc4941>. [RFC6583] Gashinsky, I., Jaeggli, J., and W. Kumari, "Operational Neighbor Discovery Problems", RFC 6583, DOI 10.17487/RFC6583, March 2012, <https://www.rfc-editor.org/info/rfc6583>. Author's Address Jen Linkova Google 1 Darling Island Rd Pyrmont, NSW 2009 AU Email: furry@google.com Linkova Expires March 17, 2021 [Page 19]