idnits 2.17.1 draft-ietf-hip-rfc5206-bis-02.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- -- The draft header indicates that this document obsoletes RFC5206, but the abstract doesn't seem to mention this, which it should. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == The document seems to contain a disclaimer for pre-RFC5378 work, but was first submitted on or after 10 November 2008. The disclaimer is usually necessary only for documents that revise or obsolete older RFCs, and that take significant amounts of text from those RFCs. If you can contact all authors of the source material and they are willing to grant the BCP78 rights to the IETF Trust, you can and should remove the disclaimer. Otherwise, the disclaimer is needed and you can ignore this comment. (See the Legal Provisions document at https://trustee.ietf.org/license-info for more information.) -- The document date (March 14, 2011) is 4793 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) == Unused Reference: 'RFC3484' is defined on line 1379, but no explicit reference was found in the text == Unused Reference: 'RFC4303' is defined on line 1387, but no explicit reference was found in the text == Outdated reference: A later version (-20) exists of draft-ietf-hip-rfc4423-bis-02 ** Downref: Normative reference to an Informational draft: draft-ietf-hip-rfc4423-bis (ref. 'I-D.ietf-hip-rfc4423-bis') == Outdated reference: A later version (-20) exists of draft-ietf-hip-rfc5201-bis-05 == Outdated reference: A later version (-07) exists of draft-ietf-hip-rfc5202-bis-00 == Outdated reference: A later version (-08) exists of draft-ietf-hip-rfc5204-bis-01 ** Obsolete normative reference: RFC 3484 (Obsoleted by RFC 6724) Summary: 2 errors (**), 0 flaws (~~), 8 warnings (==), 2 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group P. Nikander 3 Internet-Draft Ericsson Research NomadicLab 4 Obsoletes: 5206 (if approved) T. Henderson, Ed. 5 Intended status: Standards Track The Boeing Company 6 Expires: September 15, 2011 C. Vogt 7 J. Arkko 8 Ericsson Research NomadicLab 9 March 14, 2011 11 Host Mobility with the Host Identity Protocol 12 draft-ietf-hip-rfc5206-bis-02 14 Abstract 16 This document defines mobility extensions to the Host Identity 17 Protocol (HIP). Specifically, this document defines a general 18 "LOCATOR" parameter for HIP messages that allows for a HIP host to 19 notify peers about alternate addresses at which it may be reached. 20 This document also defines elements of procedure for mobility of a 21 HIP host -- the process by which a host dynamically changes the 22 primary locator that it uses to receive packets. While the same 23 LOCATOR parameter can also be used to support end-host multihoming, 24 detailed procedures are out of scope for this document. 26 Status of This Memo 28 This Internet-Draft is submitted in full conformance with the 29 provisions of BCP 78 and BCP 79. 31 Internet-Drafts are working documents of the Internet Engineering 32 Task Force (IETF). Note that other groups may also distribute 33 working documents as Internet-Drafts. The list of current Internet- 34 Drafts is at http://datatracker.ietf.org/drafts/current/. 36 Internet-Drafts are draft documents valid for a maximum of six months 37 and may be updated, replaced, or obsoleted by other documents at any 38 time. It is inappropriate to use Internet-Drafts as reference 39 material or to cite them other than as "work in progress." 41 This Internet-Draft will expire on September 15, 2011. 43 Copyright Notice 45 Copyright (c) 2011 IETF Trust and the persons identified as the 46 document authors. All rights reserved. 48 This document is subject to BCP 78 and the IETF Trust's Legal 49 Provisions Relating to IETF Documents 50 (http://trustee.ietf.org/license-info) in effect on the date of 51 publication of this document. Please review these documents 52 carefully, as they describe your rights and restrictions with respect 53 to this document. Code Components extracted from this document must 54 include Simplified BSD License text as described in Section 4.e of 55 the Trust Legal Provisions and are provided without warranty as 56 described in the Simplified BSD License. 58 This document may contain material from IETF Documents or IETF 59 Contributions published or made publicly available before November 60 10, 2008. The person(s) controlling the copyright in some of this 61 material may not have granted the IETF Trust the right to allow 62 modifications of such material outside the IETF Standards Process. 63 Without obtaining an adequate license from the person(s) controlling 64 the copyright in such materials, this document may not be modified 65 outside the IETF Standards Process, and derivative works of it may 66 not be created outside the IETF Standards Process, except to format 67 it for publication as an RFC or to translate it into languages other 68 than English. 70 Table of Contents 72 1. Introduction and Scope . . . . . . . . . . . . . . . . . . . . 4 73 2. Terminology and Conventions . . . . . . . . . . . . . . . . . 5 74 3. Protocol Model . . . . . . . . . . . . . . . . . . . . . . . . 6 75 3.1. Operating Environment . . . . . . . . . . . . . . . . . . 6 76 3.1.1. Locator . . . . . . . . . . . . . . . . . . . . . . . 8 77 3.1.2. Mobility Overview . . . . . . . . . . . . . . . . . . 8 78 3.2. Protocol Overview . . . . . . . . . . . . . . . . . . . . 9 79 3.2.1. Mobility with a Single SA Pair (No Rekeying) . . . . . 9 80 3.2.2. Mobility with a Single SA Pair (Mobile-Initiated 81 Rekey) . . . . . . . . . . . . . . . . . . . . . . . . 11 82 3.2.3. Using LOCATORs across Addressing Realms . . . . . . . 11 83 3.2.4. Network Renumbering . . . . . . . . . . . . . . . . . 12 84 3.3. Other Considerations . . . . . . . . . . . . . . . . . . . 12 85 3.3.1. Address Verification . . . . . . . . . . . . . . . . . 12 86 3.3.2. Credit-Based Authorization . . . . . . . . . . . . . . 12 87 3.3.3. Preferred Locator . . . . . . . . . . . . . . . . . . 14 88 4. LOCATOR Parameter Format . . . . . . . . . . . . . . . . . . . 14 89 4.1. Traffic Type and Preferred Locator . . . . . . . . . . . . 16 90 4.2. Locator Type and Locator . . . . . . . . . . . . . . . . . 16 91 4.3. UPDATE Packet with Included LOCATOR . . . . . . . . . . . 17 92 5. Processing Rules . . . . . . . . . . . . . . . . . . . . . . . 17 93 5.1. Locator Data Structure and Status . . . . . . . . . . . . 17 94 5.2. Sending LOCATORs . . . . . . . . . . . . . . . . . . . . . 18 95 5.3. Handling Received LOCATORs . . . . . . . . . . . . . . . . 20 96 5.4. Verifying Address Reachability . . . . . . . . . . . . . . 22 97 5.5. Changing the Preferred Locator . . . . . . . . . . . . . . 23 98 5.6. Credit-Based Authorization . . . . . . . . . . . . . . . . 24 99 5.6.1. Handling Payload Packets . . . . . . . . . . . . . . . 24 100 5.6.2. Credit Aging . . . . . . . . . . . . . . . . . . . . . 26 101 6. Security Considerations . . . . . . . . . . . . . . . . . . . 27 102 6.1. Impersonation Attacks . . . . . . . . . . . . . . . . . . 28 103 6.2. Denial-of-Service Attacks . . . . . . . . . . . . . . . . 29 104 6.2.1. Flooding Attacks . . . . . . . . . . . . . . . . . . . 29 105 6.2.2. Memory/Computational-Exhaustion DoS Attacks . . . . . 29 106 6.3. Mixed Deployment Environment . . . . . . . . . . . . . . . 30 107 7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 30 108 8. Authors and Acknowledgments . . . . . . . . . . . . . . . . . 31 109 9. References . . . . . . . . . . . . . . . . . . . . . . . . . . 31 110 9.1. Normative references . . . . . . . . . . . . . . . . . . . 31 111 9.2. Informative references . . . . . . . . . . . . . . . . . . 32 112 Appendix A. Document Revision History . . . . . . . . . . . . . . 32 114 1. Introduction and Scope 116 The Host Identity Protocol [I-D.ietf-hip-rfc4423-bis] (HIP) supports 117 an architecture that decouples the transport layer (TCP, UDP, etc.) 118 from the internetworking layer (IPv4 and IPv6) by using public/ 119 private key pairs, instead of IP addresses, as host identities. When 120 a host uses HIP, the overlying protocol sublayers (e.g., transport 121 layer sockets and Encapsulating Security Payload (ESP) Security 122 Associations (SAs)) are instead bound to representations of these 123 host identities, and the IP addresses are only used for packet 124 forwarding. However, each host must also know at least one IP 125 address at which its peers are reachable. Initially, these IP 126 addresses are the ones used during the HIP base exchange 127 [I-D.ietf-hip-rfc5201-bis]. 129 One consequence of such a decoupling is that new solutions to 130 network-layer mobility and host multihoming are possible. There are 131 potentially many variations of mobility and multihoming possible. 132 The scope of this document encompasses messaging and elements of 133 procedure for basic network-level host mobility, leaving more 134 complicated scenarios and other variations for further study. More 135 specifically: 137 This document defines a generalized LOCATOR parameter for use in 138 HIP messages. The LOCATOR parameter allows a HIP host to notify a 139 peer about alternate addresses at which it is reachable. The 140 LOCATORs may be merely IP addresses, or they may have additional 141 multiplexing and demultiplexing context to aid the packet handling 142 in the lower layers. For instance, an IP address may need to be 143 paired with an ESP Security Parameter Index (SPI) so that packets 144 are sent on the correct SA for a given address. 146 This document also specifies the messaging and elements of 147 procedure for end-host mobility of a HIP host -- the sequential 148 change in the preferred IP address used to reach a host. In 149 particular, message flows to enable successful host mobility, 150 including address verification methods, are defined herein. 152 However, while the same LOCATOR parameter is intended to support 153 host multihoming (parallel support of a number of addresses), and 154 experimentation is encouraged, detailed elements of procedure for 155 host multihoming are out of scope. 157 While HIP can potentially be used with transports other than the ESP 158 transport format [I-D.ietf-hip-rfc5202-bis], this document largely 159 assumes the use of ESP and leaves other transport formats for further 160 study. 162 There are a number of situations where the simple end-to-end 163 readdressing functionality is not sufficient. These include the 164 initial reachability of a mobile host, location privacy, simultaneous 165 mobility of both hosts, and some modes of NAT traversal. In these 166 situations, there is a need for some helper functionality in the 167 network, such as a HIP rendezvous server [I-D.ietf-hip-rfc5204-bis]. 168 Such functionality is out of the scope of this document. We also do 169 not consider localized mobility management extensions (i.e., mobility 170 management techniques that do not involve directly signaling the 171 correspondent node); this document is concerned with end-to-end 172 mobility. Making underlying IP mobility transparent to the transport 173 layer has implications on the proper response of transport congestion 174 control, path MTU selection, and Quality of Service (QoS). 175 Transport-layer mobility triggers, and the proper transport response 176 to a HIP mobility or multihoming address change, are outside the 177 scope of this document. 179 2. Terminology and Conventions 181 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 182 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 183 document are to be interpreted as described in RFC 2119 [RFC2119]. 185 LOCATOR. The name of a HIP parameter containing zero or more Locator 186 fields. This parameter's name is distinguished from the Locator 187 fields embedded within it by the use of all capital letters. 189 Locator. A name that controls how the packet is routed through the 190 network and demultiplexed by the end host. It may include a 191 concatenation of traditional network addresses such as an IPv6 192 address and end-to-end identifiers such as an ESP SPI. It may 193 also include transport port numbers or IPv6 Flow Labels as 194 demultiplexing context, or it may simply be a network address. 196 Address. A name that denotes a point-of-attachment to the network. 197 The two most common examples are an IPv4 address and an IPv6 198 address. The set of possible addresses is a subset of the set of 199 possible locators. 201 Preferred locator. A locator on which a host prefers to receive 202 data. With respect to a given peer, a host always has one active 203 Preferred locator, unless there are no active locators. By 204 default, the locators used in the HIP base exchange are the 205 Preferred locators. 207 Credit Based Authorization. A host must verify a peer host's 208 reachability at a new locator. Credit-Based Authorization 209 authorizes the peer to receive a certain amount of data at the new 210 locator before the result of such verification is known. 212 3. Protocol Model 214 This section is an overview; more detailed specification follows this 215 section. 217 3.1. Operating Environment 219 The Host Identity Protocol (HIP) [I-D.ietf-hip-rfc5201-bis] is a key 220 establishment and parameter negotiation protocol. Its primary 221 applications are for authenticating host messages based on host 222 identities, and establishing security associations (SAs) for the ESP 223 transport format [I-D.ietf-hip-rfc5202-bis] and possibly other 224 protocols in the future. 226 +--------------------+ +--------------------+ 227 | | | | 228 | +------------+ | | +------------+ | 229 | | Key | | HIP | | Key | | 230 | | Management | <-+-----------------------+-> | Management | | 231 | | Process | | | | Process | | 232 | +------------+ | | +------------+ | 233 | ^ | | ^ | 234 | | | | | | 235 | v | | v | 236 | +------------+ | | +------------+ | 237 | | IPsec | | ESP | | IPsec | | 238 | | Stack | <-+-----------------------+-> | Stack | | 239 | | | | | | | | 240 | +------------+ | | +------------+ | 241 | | | | 242 | | | | 243 | Initiator | | Responder | 244 +--------------------+ +--------------------+ 246 Figure 1: HIP Deployment Model 248 The general deployment model for HIP is shown above, assuming 249 operation in an end-to-end fashion. This document specifies 250 extensions to the HIP protocol to enable end-host mobility and basic 251 multihoming. In summary, these extensions to the HIP base protocol 252 enable the signaling of new addressing information to the peer in HIP 253 messages. The messages are authenticated via a signature or keyed 254 hash message authentication code (HMAC) based on its Host Identity. 256 This document specifies the format of this new addressing (LOCATOR) 257 parameter, the procedures for sending and processing this parameter 258 to enable basic host mobility, and procedures for a concurrent 259 address verification mechanism. 261 --------- 262 | TCP | (sockets bound to HITs) 263 --------- 264 | 265 --------- 266 ----> | ESP | {HIT_s, HIT_d} <-> SPI 267 | --------- 268 | | 269 ---- --------- 270 | MH |-> | HIP | {HIT_s, HIT_d, SPI} <-> {IP_s, IP_d, SPI} 271 ---- --------- 272 | 273 --------- 274 | IP | 275 --------- 277 Figure 2: Architecture for HIP Host Mobility (MH) 279 Figure 2 depicts a layered architectural view of a HIP-enabled stack 280 using the ESP transport format. In HIP, upper-layer protocols 281 (including TCP and ESP in this figure) are bound to Host Identity 282 Tags (HITs) and not IP addresses. The HIP sublayer is responsible 283 for maintaining the binding between HITs and IP addresses. The SPI 284 is used to associate an incoming packet with the right HITs. The 285 block labeled "MH" is introduced below. 287 Consider first the case in which there is no mobility or multihoming, 288 as specified in the base protocol specification 289 [I-D.ietf-hip-rfc5201-bis]. The HIP base exchange establishes the 290 HITs in use between the hosts, the SPIs to use for ESP, and the IP 291 addresses (used in both the HIP signaling packets and ESP data 292 packets). Note that there can only be one such set of bindings in 293 the outbound direction for any given packet, and the only fields used 294 for the binding at the HIP layer are the fields exposed by ESP (the 295 SPI and HITs). For the inbound direction, the SPI is all that is 296 required to find the right host context. ESP rekeying events change 297 the mapping between the HIT pair and SPI, but do not change the IP 298 addresses. 300 Consider next a mobility event, in which a host moves to another IP 301 address. Two things must occur in this case. First, the peer must 302 be notified of the address change using a HIP UPDATE message. 303 Second, each host must change its local bindings at the HIP sublayer 304 (new IP addresses). It may be that both the SPIs and IP addresses 305 are changed simultaneously in a single UPDATE; the protocol described 306 herein supports this. However, simultaneous movement of both hosts, 307 notification of transport layer protocols of the path change, and 308 procedures for possibly traversing middleboxes are not covered by 309 this document. 311 3.1.1. Locator 313 This document defines a generalization of an address called a 314 "locator". A locator specifies a point-of-attachment to the network 315 but may also include additional end-to-end tunneling or per-host 316 demultiplexing context that affects how packets are handled below the 317 logical HIP sublayer of the stack. This generalization is useful 318 because IP addresses alone may not be sufficient to describe how 319 packets should be handled below HIP. For example, in a host 320 multihoming context, certain IP addresses may need to be associated 321 with certain ESP SPIs to avoid violating the ESP anti-replay window. 322 Addresses may also be affiliated with transport ports in certain 323 tunneling scenarios. Locators may simply be traditional network 324 addresses. The format of the locator fields in the LOCATOR parameter 325 is defined in Section 4. 327 3.1.2. Mobility Overview 329 When a host moves to another address, it notifies its peer of the new 330 address by sending a HIP UPDATE packet containing a LOCATOR 331 parameter. This UPDATE packet is acknowledged by the peer. For 332 reliability in the presence of packet loss, the UPDATE packet is 333 retransmitted as defined in the HIP protocol specification 334 [I-D.ietf-hip-rfc5201-bis]. The peer can authenticate the contents 335 of the UPDATE packet based on the signature and keyed hash of the 336 packet. 338 When using ESP Transport Format [I-D.ietf-hip-rfc5202-bis], the host 339 may at the same time decide to rekey its security association and 340 possibly generate a new Diffie-Hellman key; all of these actions are 341 triggered by including additional parameters in the UPDATE packet, as 342 defined in the base protocol specification [I-D.ietf-hip-rfc5201-bis] 343 and ESP extension [I-D.ietf-hip-rfc5202-bis]. 345 When using ESP (and possibly other transport modes in the future), 346 the host is able to receive packets that are protected using a HIP 347 created ESP SA from any address. Thus, a host can change its IP 348 address and continue to send packets to its peers without necessarily 349 rekeying. However, the peers are not able to send packets to these 350 new addresses before they can reliably and securely update the set of 351 addresses that they associate with the sending host. Furthermore, 352 mobility may change the path characteristics in such a manner that 353 reordering occurs and packets fall outside the ESP anti-replay window 354 for the SA, thereby requiring rekeying. 356 3.2. Protocol Overview 358 In this section, we briefly introduce a number of usage scenarios for 359 HIP host mobility. These scenarios assume that HIP is being used 360 with the ESP transform [I-D.ietf-hip-rfc5202-bis], although other 361 scenarios may be defined in the future. To understand these usage 362 scenarios, the reader should be at least minimally familiar with the 363 HIP protocol specification [I-D.ietf-hip-rfc5201-bis]. However, for 364 the (relatively) uninitiated reader, it is most important to keep in 365 mind that in HIP the actual payload traffic is protected with ESP, 366 and that the ESP SPI acts as an index to the right host-to-host 367 context. More specification details are found later in Section 4 and 368 Section 5. 370 The scenarios below assume that the two hosts have completed a single 371 HIP base exchange with each other. Both of the hosts therefore have 372 one incoming and one outgoing SA. Further, each SA uses the same 373 pair of IP addresses, which are the ones used in the base exchange. 375 The readdressing protocol is an asymmetric protocol where a mobile 376 host informs a peer host about changes of IP addresses on affected 377 SPIs. The readdressing exchange is designed to be piggybacked on 378 existing HIP exchanges. The majority of the packets on which the 379 LOCATOR parameters are expected to be carried are UPDATE packets. 380 However, some implementations may want to experiment with sending 381 LOCATOR parameters also on other packets, such as R1, I2, and NOTIFY. 383 The scenarios below at times describe addresses as being in either an 384 ACTIVE, VERIFIED, or DEPRECATED state. From the perspective of a 385 host, newly-learned addresses of the peer must be verified before put 386 into active service, and addresses removed by the peer are put into a 387 deprecated state. Under limited conditions described below 388 (Section 5.6), an UNVERIFIED address may be used. The addressing 389 states are defined more formally in Section 5.1. 391 Hosts that use link-local addresses as source addresses in their HIP 392 handshakes may not be reachable by a mobile peer. Such hosts SHOULD 393 provide a globally routable address either in the initial handshake 394 or via the LOCATOR parameter. 396 3.2.1. Mobility with a Single SA Pair (No Rekeying) 398 A mobile host must sometimes change an IP address bound to an 399 interface. The change of an IP address might be needed due to a 400 change in the advertised IPv6 prefixes on the link, a reconnected PPP 401 link, a new DHCP lease, or an actual movement to another subnet. In 402 order to maintain its communication context, the host must inform its 403 peers about the new IP address. This first example considers the 404 case in which the mobile host has only one interface, IP address, a 405 single pair of SAs (one inbound, one outbound), and no rekeying 406 occurs on the SAs. We also assume that the new IP addresses are 407 within the same address family (IPv4 or IPv6) as the first address. 408 This is the simplest scenario, depicted in Figure 3. 410 Mobile Host Peer Host 412 UPDATE(ESP_INFO, LOCATOR, SEQ) 413 -----------------------------------> 414 UPDATE(ESP_INFO, SEQ, ACK, ECHO_REQUEST) 415 <----------------------------------- 416 UPDATE(ACK, ECHO_RESPONSE) 417 -----------------------------------> 419 Figure 3: Readdress without Rekeying, but with Address Check 421 The steps of the packet processing are as follows: 423 1. The mobile host is disconnected from the peer host for a brief 424 period of time while it switches from one IP address to another. 425 Upon obtaining a new IP address, the mobile host sends a LOCATOR 426 parameter to the peer host in an UPDATE message. The UPDATE 427 message also contains an ESP_INFO parameter containing the values 428 of the old and new SPIs for a security association. In this 429 case, the OLD SPI and NEW SPI parameters both are set to the 430 value of the preexisting incoming SPI; this ESP_INFO does not 431 trigger a rekeying event but is instead included for possible 432 parameter-inspecting middleboxes on the path. The LOCATOR 433 parameter contains the new IP address (Locator Type of "1", 434 defined below) and a locator lifetime. The mobile host waits for 435 this UPDATE to be acknowledged, and retransmits if necessary, as 436 specified in the base specification [I-D.ietf-hip-rfc5201-bis]. 438 2. The peer host receives the UPDATE, validates it, and updates any 439 local bindings between the HIP association and the mobile host's 440 destination address. The peer host MUST perform an address 441 verification by placing a nonce in the ECHO_REQUEST parameter of 442 the UPDATE message sent back to the mobile host. It also 443 includes an ESP_INFO parameter with the OLD SPI and NEW SPI 444 parameters both set to the value of the preexisting incoming SPI, 445 and sends this UPDATE (with piggybacked acknowledgment) to the 446 mobile host at its new address. The peer MAY use the new address 447 immediately, but it MUST limit the amount of data it sends to the 448 address until address verification completes. 450 3. The mobile host completes the readdress by processing the UPDATE 451 ACK and echoing the nonce in an ECHO_RESPONSE. Once the peer 452 host receives this ECHO_RESPONSE, it considers the new address to 453 be verified and can put the address into full use. 455 While the peer host is verifying the new address, the new address is 456 marked as UNVERIFIED in the interim, and the old address is 457 DEPRECATED. Once the peer host has received a correct reply to its 458 UPDATE challenge, it marks the new address as ACTIVE and removes the 459 old address. 461 3.2.2. Mobility with a Single SA Pair (Mobile-Initiated Rekey) 463 The mobile host may decide to rekey the SAs at the same time that it 464 notifies the peer of the new address. In this case, the above 465 procedure described in Figure 3 is slightly modified. The UPDATE 466 message sent from the mobile host includes an ESP_INFO with the OLD 467 SPI set to the previous SPI, the NEW SPI set to the desired new SPI 468 value for the incoming SA, and the KEYMAT Index desired. Optionally, 469 the host may include a DIFFIE_HELLMAN parameter for a new Diffie- 470 Hellman key. The peer completes the request for a rekey as is 471 normally done for HIP rekeying, except that the new address is kept 472 as UNVERIFIED until the UPDATE nonce challenge is received as 473 described above. Figure 4 illustrates this scenario. 475 Mobile Host Peer Host 477 UPDATE(ESP_INFO, LOCATOR, SEQ, [DIFFIE_HELLMAN]) 478 -----------------------------------> 479 UPDATE(ESP_INFO, SEQ, ACK, [DIFFIE_HELLMAN,] ECHO_REQUEST) 480 <----------------------------------- 481 UPDATE(ACK, ECHO_RESPONSE) 482 -----------------------------------> 484 Figure 4: Readdress with Mobile-Initiated Rekey 486 3.2.3. Using LOCATORs across Addressing Realms 488 It is possible for HIP associations to migrate to a state in which 489 both parties are only using locators in different addressing realms. 490 For example, the two hosts may initiate the HIP association when both 491 are using IPv6 locators, then one host may loose its IPv6 492 connectivity and obtain an IPv4 address. In such a case, some type 493 of mechanism for interworking between the different realms must be 494 employed; such techniques are outside the scope of the present text. 495 The basic problem in this example is that the host readdressing to 496 IPv4 does not know a corresponding IPv4 address of the peer. This 497 may be handled (experimentally) by possibly configuring this address 498 information manually or in the DNS, or the hosts exchange both IPv4 499 and IPv6 addresses in the locator. 501 3.2.4. Network Renumbering 503 It is expected that IPv6 networks will be renumbered much more often 504 than most IPv4 networks. From an end-host point of view, network 505 renumbering is similar to mobility. 507 3.3. Other Considerations 509 3.3.1. Address Verification 511 When a HIP host receives a set of locators from another HIP host in a 512 LOCATOR, it does not necessarily know whether the other host is 513 actually reachable at the claimed addresses. In fact, a malicious 514 peer host may be intentionally giving bogus addresses in order to 515 cause a packet flood towards the target addresses [RFC4225]. 516 Likewise, viral software may have compromised the peer host, 517 programming it to redirect packets to the target addresses. Thus, 518 the HIP host must first check that the peer is reachable at the new 519 address. 521 An additional potential benefit of performing address verification is 522 to allow middleboxes in the network along the new path to obtain the 523 peer host's inbound SPI. 525 Address verification is implemented by the challenger sending some 526 piece of unguessable information to the new address, and waiting for 527 some acknowledgment from the Responder that indicates reception of 528 the information at the new address. This may include the exchange of 529 a nonce, or the generation of a new SPI and observation of data 530 arriving on the new SPI. 532 3.3.2. Credit-Based Authorization 534 Credit-Based Authorization (CBA) allows a host to securely use a new 535 locator even though the peer's reachability at the address embedded 536 in the locator has not yet been verified. This is accomplished based 537 on the following three hypotheses: 539 1. A flooding attacker typically seeks to somehow multiply the 540 packets it generates for the purpose of its attack because 541 bandwidth is an ample resource for many victims. 543 2. An attacker can often cause unamplified flooding by sending 544 packets to its victim, either by directly addressing the victim 545 in the packets, or by guiding the packets along a specific path 546 by means of an IPv6 Routing header, if Routing headers are not 547 filtered by firewalls. 549 3. Consequently, the additional effort required to set up a 550 redirection-based flooding attack (without CBA and return 551 routability checks) would pay off for the attacker only if 552 amplification could be obtained this way. 554 On this basis, rather than eliminating malicious packet redirection 555 in the first place, Credit-Based Authorization prevents 556 amplifications. This is accomplished by limiting the data a host can 557 send to an unverified address of a peer by the data recently received 558 from that peer. Redirection-based flooding attacks thus become less 559 attractive than, for example, pure direct flooding, where the 560 attacker itself sends bogus packets to the victim. 562 Figure 5 illustrates Credit-Based Authorization: Host B measures the 563 amount of data recently received from peer A and, when A readdresses, 564 sends packets to A's new, unverified address as long as the sum of 565 the packet sizes does not exceed the measured, received data volume. 566 When insufficient credit is left, B stops sending further packets to 567 A until A's address becomes ACTIVE. The address changes may be due 568 to mobility, multihoming, or any other reason. Not shown in Figure 5 569 are the results of credit aging (Section 5.6.2), a mechanism used to 570 dampen possible time-shifting attacks. 572 +-------+ +-------+ 573 | A | | B | 574 +-------+ +-------+ 575 | | 576 address |------------------------------->| credit += size(packet) 577 ACTIVE | | 578 |------------------------------->| credit += size(packet) 579 |<-------------------------------| do not change credit 580 | | 581 + address change | 582 + address verification starts | 583 address |<-------------------------------| credit -= size(packet) 584 UNVERIFIED |------------------------------->| credit += size(packet) 585 |<-------------------------------| credit -= size(packet) 586 | | 587 |<-------------------------------| credit -= size(packet) 588 | X credit < size(packet) 589 | | => do not send packet! 590 + address verification concludes | 591 address | | 592 ACTIVE |<-------------------------------| do not change credit 593 | | 595 Figure 5: Readdressing Scenario 597 3.3.3. Preferred Locator 599 When a host has multiple locators, the peer host must decide which to 600 use for outbound packets. It may be that a host would prefer to 601 receive data on a particular inbound interface. HIP allows a 602 particular locator to be designated as a Preferred locator and 603 communicated to the peer (see Section 4). 605 4. LOCATOR Parameter Format 607 The LOCATOR parameter is a critical parameter as defined by 608 [I-D.ietf-hip-rfc5201-bis]. It consists of the standard HIP 609 parameter Type and Length fields, plus zero or more Locator sub- 610 parameters. Each Locator sub-parameter contains a Traffic Type, 611 Locator Type, Locator Length, Preferred locator bit, Locator 612 Lifetime, and a Locator encoding. A LOCATOR containing zero Locator 613 fields is permitted but has the effect of deprecating all addresses. 615 0 1 2 3 616 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 617 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 618 | Type | Length | 619 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 620 | Traffic Type | Locator Type | Locator Length | Reserved |P| 621 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 622 | Locator Lifetime | 623 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 624 | Locator | 625 | | 626 | | 627 | | 628 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 629 . . 630 . . 631 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 632 | Traffic Type | Locator Type | Locator Length | Reserved |P| 633 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 634 | Locator Lifetime | 635 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 636 | Locator | 637 | | 638 | | 639 | | 640 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 642 Figure 6: LOCATOR Parameter Format 644 Type: 193 646 Length: Length in octets, excluding Type and Length fields, and 647 excluding padding. 649 Traffic Type: Defines whether the locator pertains to HIP signaling, 650 user data, or both. 652 Locator Type: Defines the semantics of the Locator field. 654 Locator Length: Defines the length of the Locator field, in units of 655 4-byte words (Locators up to a maximum of 4*255 octets are 656 supported). 658 Reserved: Zero when sent, ignored when received. 660 P: Preferred locator. Set to one if the locator is preferred for 661 that Traffic Type; otherwise, set to zero. 663 Locator Lifetime: Locator lifetime, in seconds. 665 Locator: The locator whose semantics and encoding are indicated by 666 the Locator Type field. All Locator sub-fields are integral 667 multiples of four octets in length. 669 The Locator Lifetime indicates how long the following locator is 670 expected to be valid. The lifetime is expressed in seconds. Each 671 locator MUST have a non-zero lifetime. The address is expected to 672 become deprecated when the specified number of seconds has passed 673 since the reception of the message. A deprecated address SHOULD NOT 674 be used as a destination address if an alternate (non-deprecated) is 675 available and has sufficient scope. 677 4.1. Traffic Type and Preferred Locator 679 The following Traffic Type values are defined: 681 0: Both signaling (HIP control packets) and user data. 683 1: Signaling packets only. 685 2: Data packets only. 687 The "P" bit, when set, has scope over the corresponding Traffic Type. 688 That is, when a "P" bit is set for Traffic Type "2", for example, it 689 means that the locator is preferred for data packets. If there is a 690 conflict (for example, if the "P" bit is set for an address of Type 691 "0" and a different address of Type "2"), the more specific Traffic 692 Type rule applies (in this case, "2"). By default, the IP addresses 693 used in the base exchange are Preferred locators for both signaling 694 and user data, unless a new Preferred locator supersedes them. If no 695 locators are indicated as preferred for a given Traffic Type, the 696 implementation may use an arbitrary locator from the set of active 697 locators. 699 4.2. Locator Type and Locator 701 The following Locator Type values are defined, along with the 702 associated semantics of the Locator field: 704 0: An IPv6 address or an IPv4-in-IPv6 format IPv4 address [RFC4291] 705 (128 bits long). This locator type is defined primarily for non- 706 ESP-based usage. 708 1: The concatenation of an ESP SPI (first 32 bits) followed by an 709 IPv6 address or an IPv4-in-IPv6 format IPv4 address (an additional 710 128 bits). This IP address is defined primarily for ESP-based 711 usage. 713 4.3. UPDATE Packet with Included LOCATOR 715 A number of combinations of parameters in an UPDATE packet are 716 possible (e.g., see Section 3.2). In this document, procedures are 717 defined only for the case in which one LOCATOR and one ESP_INFO 718 parameter is used in any HIP packet. Furthermore, the LOCATOR SHOULD 719 list all of the locators that are active on the HIP association 720 (including those on SAs not covered by the ESP_INFO parameter). Any 721 UPDATE packet that includes a LOCATOR parameter SHOULD include both 722 an HMAC and a HIP_SIGNATURE parameter. The relationship between the 723 announced Locators and any ESP_INFO parameters present in the packet 724 is defined in Section 5.2. The sending of multiple LOCATOR and/or 725 ESP_INFO parameters is for further study; receivers may wish to 726 experiment with supporting such a possibility. 728 5. Processing Rules 730 This section describes rules for sending and receiving the LOCATOR 731 parameter, testing address reachability, and using Credit-Based 732 Authorization (CBA) on UNVERIFIED locators. 734 5.1. Locator Data Structure and Status 736 In a typical implementation, each outgoing locator is represented by 737 a piece of state that contains the following data: 739 o the actual bit pattern representing the locator, 741 o the lifetime (seconds), 743 o the status (UNVERIFIED, ACTIVE, DEPRECATED), 745 o the Traffic Type scope of the locator, and 747 o whether the locator is preferred for any particular scope. 749 The status is used to track the reachability of the address embedded 750 within the LOCATOR parameter: 752 UNVERIFIED indicates that the reachability of the address has not 753 been verified yet, 755 ACTIVE indicates that the reachability of the address has been 756 verified and the address has not been deprecated, 758 DEPRECATED indicates that the locator lifetime has expired. 760 The following state changes are allowed: 762 UNVERIFIED to ACTIVE The reachability procedure completes 763 successfully. 765 UNVERIFIED to DEPRECATED The locator lifetime expires while the 766 locator is UNVERIFIED. 768 ACTIVE to DEPRECATED The locator lifetime expires while the locator 769 is ACTIVE. 771 ACTIVE to UNVERIFIED There has been no traffic on the address for 772 some time, and the local policy mandates that the address 773 reachability must be verified again before starting to use it 774 again. 776 DEPRECATED to UNVERIFIED The host receives a new lifetime for the 777 locator. 779 A DEPRECATED address MUST NOT be changed to ACTIVE without first 780 verifying its reachability. 782 Note that the state of whether or not a locator is preferred is not 783 necessarily the same as the value of the Preferred bit in the Locator 784 sub-parameter received from the peer. Peers may recommend certain 785 locators to be preferred, but the decision on whether to actually use 786 a locator as a preferred locator is a local decision, possibly 787 influenced by local policy. 789 5.2. Sending LOCATORs 791 The decision of when to send LOCATORs is basically a local policy 792 issue. However, it is RECOMMENDED that a host send a LOCATOR 793 whenever it recognizes a change of its IP addresses in use on an 794 active HIP association, and assumes that the change is going to last 795 at least for a few seconds. Rapidly sending LOCATORs that force the 796 peer to change the preferred address SHOULD be avoided. 798 When a host decides to inform its peers about changes in its IP 799 addresses, it has to decide how to group the various addresses with 800 SPIs. The grouping should consider also whether middlebox 801 interaction requires sending the same LOCATOR in separate UPDATEs on 802 different paths. Since each SPI is associated with a different 803 Security Association, the grouping policy may also be based on ESP 804 anti-replay protection considerations. In the typical case, simply 805 basing the grouping on actual kernel level physical and logical 806 interfaces may be the best policy. Grouping policy is outside of the 807 scope of this document. 809 Note that the purpose of announcing IP addresses in a LOCATOR is to 810 provide connectivity between the communicating hosts. In most cases, 811 tunnels or virtual interfaces such as IPsec tunnel interfaces or 812 Mobile IP home addresses provide sub-optimal connectivity. 813 Furthermore, it should be possible to replace most tunnels with HIP 814 based "non-tunneling", therefore making most virtual interfaces 815 fairly unnecessary in the future. Therefore, virtual interfaces 816 SHOULD NOT be announced in general. On the other hand, there are 817 clearly situations where tunnels are used for diagnostic and/or 818 testing purposes. In such and other similar cases announcing the IP 819 addresses of virtual interfaces may be appropriate. 821 Hosts MUST NOT announce broadcast or multicast addresses in LOCATORs. 822 Link-local addresses MAY be announced to peers that are known to be 823 neighbors on the same link, such as when the IP destination address 824 of a peer is also link-local. The announcement of link-local 825 addresses in this case is a policy decision; link-local addresses 826 used as Preferred locators will create reachability problems when the 827 host moves to another link. In any case, link-local addresses MUST 828 NOT be announced to a peer unless that peer is known to be on the 829 same link. 831 Once the host has decided on the groups and assignment of addresses 832 to the SPIs, it creates a LOCATOR parameter that serves as a complete 833 representation of the addresses and affiliated SPIs intended for 834 active use. We now describe a few cases introduced in Section 3.2. 835 We assume that the Traffic Type for each locator is set to "0" (other 836 values for Traffic Type may be specified in documents that separate 837 the HIP control plane from data plane traffic). Other mobility cases 838 are possible but are left for further experimentation. 840 1. Host mobility with no multihoming and no rekeying. The mobile 841 host creates a single UPDATE containing a single ESP_INFO with a 842 single LOCATOR parameter. The ESP_INFO contains the current 843 value of the SPI in both the OLD SPI and NEW SPI fields. The 844 LOCATOR contains a single Locator with a "Locator Type" of "1"; 845 the SPI must match that of the ESP_INFO. The Preferred bit 846 SHOULD be set and the "Locator Lifetime" is set according to 847 local policy. The UPDATE also contains a SEQ parameter as usual. 849 This packet is retransmitted as defined in the HIP protocol 850 specification [I-D.ietf-hip-rfc5201-bis]. The UPDATE should be 851 sent to the peer's preferred IP address with an IP source address 852 corresponding to the address in the LOCATOR parameter. 854 2. Host mobility with no multihoming but with rekeying. The mobile 855 host creates a single UPDATE containing a single ESP_INFO with a 856 single LOCATOR parameter (with a single address). The ESP_INFO 857 contains the current value of the SPI in the OLD SPI and the new 858 value of the SPI in the NEW SPI, and a KEYMAT Index as selected 859 by local policy. Optionally, the host may choose to initiate a 860 Diffie Hellman rekey by including a DIFFIE_HELLMAN parameter. 861 The LOCATOR contains a single Locator with "Locator Type" of "1"; 862 the SPI must match that of the NEW SPI in the ESP_INFO. 863 Otherwise, the steps are identical to the case in which no 864 rekeying is initiated. 866 The sending of multiple LOCATORs, locators with Locator Type "0", and 867 multiple ESP_INFO parameters is for further study. Note that the 868 inclusion of LOCATOR in an R1 packet requires the use of Type "0" 869 locators since no SAs are set up at that point. 871 5.3. Handling Received LOCATORs 873 A host SHOULD be prepared to receive a LOCATOR parameter in the 874 following HIP packets: R1, I2, UPDATE, and NOTIFY. 876 This document describes sending both ESP_INFO and LOCATOR parameters 877 in an UPDATE. The ESP_INFO parameter is included when there is a 878 need to rekey or key a new SPI, and is otherwise included for the 879 possible benefit of HIP-aware middleboxes. The LOCATOR parameter 880 contains a complete map of the locators that the host wishes to make 881 or keep active for the HIP association. 883 In general, the processing of a LOCATOR depends upon the packet type 884 in which it is included. Here, we describe only the case in which 885 ESP_INFO is present and a single LOCATOR and ESP_INFO are sent in an 886 UPDATE message; other cases are for further study. The steps below 887 cover each of the cases described in Section 5.2. 889 The processing of ESP_INFO and LOCATOR parameters is intended to be 890 modular and support future generalization to the inclusion of 891 multiple ESP_INFO and/or multiple LOCATOR parameters. A host SHOULD 892 first process the ESP_INFO before the LOCATOR, since the ESP_INFO may 893 contain a new SPI value mapped to an existing SPI, while a Type "1" 894 locator will only contain a reference to the new SPI. 896 When a host receives a validated HIP UPDATE with a LOCATOR and 897 ESP_INFO parameter, it processes the ESP_INFO as follows. The 898 ESP_INFO parameter indicates whether an SA is being rekeyed, created, 899 deprecated, or just identified for the benefit of middleboxes. The 900 host examines the OLD SPI and NEW SPI values in the ESP_INFO 901 parameter: 903 1. (no rekeying) If the OLD SPI is equal to the NEW SPI and both 904 correspond to an existing SPI, the ESP_INFO is gratuitous 905 (provided for middleboxes) and no rekeying is necessary. 907 2. (rekeying) If the OLD SPI indicates an existing SPI and the NEW 908 SPI is a different non-zero value, the existing SA is being 909 rekeyed and the host follows HIP ESP rekeying procedures by 910 creating a new outbound SA with an SPI corresponding to the NEW 911 SPI, with no addresses bound to this SPI. Note that locators in 912 the LOCATOR parameter will reference this new SPI instead of the 913 old SPI. 915 3. (new SA) If the OLD SPI value is zero and the NEW SPI is a new 916 non-zero value, then a new SA is being requested by the peer. 917 This case is also treated like a rekeying event; the receiving 918 host must create a new SA and respond with an UPDATE ACK. 920 4. (deprecating the SA) If the OLD SPI indicates an existing SPI and 921 the NEW SPI is zero, the SA is being deprecated and all locators 922 uniquely bound to the SPI are put into the DEPRECATED state. 924 If none of the above cases apply, a protocol error has occurred and 925 the processing of the UPDATE is stopped. 927 Next, the locators in the LOCATOR parameter are processed. For each 928 locator listed in the LOCATOR parameter, check that the address 929 therein is a legal unicast or anycast address. That is, the address 930 MUST NOT be a broadcast or multicast address. Note that some 931 implementations MAY accept addresses that indicate the local host, 932 since it may be allowed that the host runs HIP with itself. 934 The below assumes that all locators are of Type "1" with a Traffic 935 Type of "0"; other cases are for further study. 937 For each Type "1" address listed in the LOCATOR parameter, the host 938 checks whether the address is already bound to the SPI indicated. If 939 the address is already bound, its lifetime is updated. If the status 940 of the address is DEPRECATED, the status is changed to UNVERIFIED. 941 If the address is not already bound, the address is added, and its 942 status is set to UNVERIFIED. Mark all addresses corresponding to the 943 SPI that were NOT listed in the LOCATOR parameter as DEPRECATED. 945 As a result, at the end of processing, the addresses listed in the 946 LOCATOR parameter have either a state of UNVERIFIED or ACTIVE, and 947 any old addresses on the old SA not listed in the LOCATOR parameter 948 have a state of DEPRECATED. 950 Once the host has processed the locators, if the LOCATOR parameter 951 contains a new Preferred locator, the host SHOULD initiate a change 952 of the Preferred locator. This requires that the host first verifies 953 reachability of the associated address, and only then changes the 954 Preferred locator; see Section 5.5. 956 If a host receives a locator with an unsupported Locator Type, and 957 when such a locator is also declared to be the Preferred locator for 958 the peer, the host SHOULD send a NOTIFY error with a Notify Message 959 Type of LOCATOR_TYPE_UNSUPPORTED, with the Notification Data field 960 containing the locator(s) that the receiver failed to process. 961 Otherwise, a host MAY send a NOTIFY error if a (non-preferred) 962 locator with an unsupported Locator Type is received in a LOCATOR 963 parameter. 965 5.4. Verifying Address Reachability 967 A host MUST verify the reachability of an UNVERIFIED address. The 968 status of a newly learned address MUST initially be set to UNVERIFIED 969 unless the new address is advertised in a R1 packet as a new 970 Preferred locator. A host MAY also want to verify the reachability 971 of an ACTIVE address again after some time, in which case it would 972 set the status of the address to UNVERIFIED and reinitiate address 973 verification. 975 A host typically starts the address-verification procedure by sending 976 a nonce to the new address. For example, when the host is changing 977 its SPI and sending an ESP_INFO to the peer, the NEW SPI value SHOULD 978 be random and the value MAY be copied into an ECHO_REQUEST sent in 979 the rekeying UPDATE. However, if the host is not changing its SPI, 980 it MAY still use the ECHO_REQUEST parameter in an UPDATE message sent 981 to the new address. A host MAY also use other message exchanges as 982 confirmation of the address reachability. 984 Note that in the case of receiving a LOCATOR in an R1 and replying 985 with an I2 to the new address in the LOCATOR, receiving the 986 corresponding R2 is sufficient proof of reachability for the 987 Responder's preferred address. Since further address verification of 988 such an address can impede the HIP-base exchange, a host MUST NOT 989 separately verify reachability of a new Preferred locator that was 990 received on an R1. 992 In some cases, it MAY be sufficient to use the arrival of data on a 993 newly advertised SA as implicit address reachability verification as 994 depicted in Figure 7, instead of waiting for the confirmation via a 995 HIP packet. In this case, a host advertising a new SPI as part of 996 its address reachability check SHOULD be prepared to receive traffic 997 on the new SA. 999 Mobile host Peer host 1001 prepare incoming SA 1002 NEW SPI in ESP_INFO (UPDATE) 1003 <----------------------------------- 1004 switch to new outgoing SA 1005 data on new SA 1006 -----------------------------------> 1007 mark address ACTIVE 1009 Figure 7: Address Activation Via Use of a New SA 1011 When address verification is in progress for a new Preferred locator, 1012 the host SHOULD select a different locator listed as ACTIVE, if one 1013 such locator is available, to continue communications until address 1014 verification completes. Alternatively, the host MAY use the new 1015 Preferred locator while in UNVERIFIED status to the extent Credit- 1016 Based Authorization permits. Credit-Based Authorization is explained 1017 in Section 5.6. Once address verification succeeds, the status of 1018 the new Preferred locator changes to ACTIVE. 1020 5.5. Changing the Preferred Locator 1022 A host MAY want to change the Preferred outgoing locator for 1023 different reasons, e.g., because traffic information or ICMP error 1024 messages indicate that the currently used preferred address may have 1025 become unreachable. Another reason may be due to receiving a LOCATOR 1026 parameter that has the "P" bit set. 1028 To change the Preferred locator, the host initiates the following 1029 procedure: 1031 1. If the new Preferred locator has ACTIVE status, the Preferred 1032 locator is changed and the procedure succeeds. 1034 2. If the new Preferred locator has UNVERIFIED status, the host 1035 starts to verify its reachability. The host SHOULD use a 1036 different locator listed as ACTIVE until address verification 1037 completes if one such locator is available. Alternatively, the 1038 host MAY use the new Preferred locator, even though in UNVERIFIED 1039 status, to the extent Credit-Based Authorization permits. Once 1040 address verification succeeds, the status of the new Preferred 1041 locator changes to ACTIVE and its use is no longer governed by 1042 Credit-Based Authorization. 1044 3. If the peer host has not indicated a preference for any address, 1045 then the host picks one of the peer's ACTIVE addresses randomly 1046 or according to policy. This case may arise if, for example, 1047 ICMP error messages that deprecate the Preferred locator arrive, 1048 but the peer has not yet indicated a new Preferred locator. 1050 4. If the new Preferred locator has DEPRECATED status and there is 1051 at least one non-deprecated address, the host selects one of the 1052 non-deprecated addresses as a new Preferred locator and 1053 continues. If the selected address is UNVERIFIED, the address 1054 verification procedure described above will apply. 1056 5.6. Credit-Based Authorization 1058 To prevent redirection-based flooding attacks, the use of a Credit- 1059 Based Authorization (CBA) approach is mandatory when a host sends 1060 data to an UNVERIFIED locator. The following algorithm meets the 1061 security considerations for prevention of amplification and time- 1062 shifting attacks. Other forms of credit aging, and other values for 1063 the CreditAgingFactor and CreditAgingInterval parameters in 1064 particular, are for further study, and so are the advanced CBA 1065 techniques specified in [CBA-MIPv6]. 1067 5.6.1. Handling Payload Packets 1069 A host maintains a "credit counter" for each of its peers. Whenever 1070 a packet arrives from a peer, the host SHOULD increase that peer's 1071 credit counter by the size of the received packet. When the host has 1072 a packet to be sent to the peer, and when the peer's Preferred 1073 locator is listed as UNVERIFIED and no alternative locator with 1074 status ACTIVE is available, the host checks whether it can send the 1075 packet to the UNVERIFIED locator. The packet SHOULD be sent if the 1076 value of the credit counter is higher than the size of the outbound 1077 packet. If the credit counter is too low, the packet MUST be 1078 discarded or buffered until address verification succeeds. When a 1079 packet is sent to a peer at an UNVERIFIED locator, the peer's credit 1080 counter MUST be reduced by the size of the packet. The peer's credit 1081 counter is not affected by packets that the host sends to an ACTIVE 1082 locator of that peer. 1084 Figure 8 depicts the actions taken by the host when a packet is 1085 received. Figure 9 shows the decision chain in the event a packet is 1086 sent. 1088 Inbound 1089 packet 1090 | 1091 | +----------------+ +---------------+ 1092 | | Increase | | Deliver | 1093 +-----> | credit counter |-------------> | packet to | 1094 | by packet size | | application | 1095 +----------------+ +---------------+ 1097 Figure 8: Receiving Packets with Credit-Based Authorization 1099 Outbound 1100 packet 1101 | _________________ 1102 | / \ +---------------+ 1103 | / Is the preferred \ No | Send packet | 1104 +-----> | destination address |-------------> | to preferred | 1105 \ UNVERIFIED? / | address | 1106 \_________________/ +---------------+ 1107 | 1108 | Yes 1109 | 1110 v 1111 _________________ 1112 / \ +---------------+ 1113 / Does an ACTIVE \ Yes | Send packet | 1114 | destination address |-------------> | to ACTIVE | 1115 \ exist? / | address | 1116 \_________________/ +---------------+ 1117 | 1118 | No 1119 | 1120 v 1121 _________________ 1122 / \ +---------------+ 1123 / Credit counter \ No | | 1124 | >= |-------------> | Drop packet | 1125 \ packet size? / | | 1126 \_________________/ +---------------+ 1127 | 1128 | Yes 1129 | 1130 v 1131 +---------------+ +---------------+ 1132 | Reduce credit | | Send packet | 1133 | counter by |----------------> | to preferred | 1134 | packet size | | address | 1135 +---------------+ +---------------+ 1137 Figure 9: Sending Packets with Credit-Based Authorization 1139 5.6.2. Credit Aging 1141 A host ensures that the credit counters it maintains for its peers 1142 gradually decrease over time. Such "credit aging" prevents a 1143 malicious peer from building up credit at a very slow speed and using 1144 this, all at once, for a severe burst of redirected packets. 1146 Credit aging may be implemented by multiplying credit counters with a 1147 factor, CreditAgingFactor (a fractional value less than one), in 1148 fixed time intervals of CreditAgingInterval length. Choosing 1149 appropriate values for CreditAgingFactor and CreditAgingInterval is 1150 important to ensure that a host can send packets to an address in 1151 state UNVERIFIED even when the peer sends at a lower rate than the 1152 host itself. When CreditAgingFactor or CreditAgingInterval are too 1153 small, the peer's credit counter might be too low to continue sending 1154 packets until address verification concludes. 1156 The parameter values proposed in this document are as follows: 1158 CreditAgingFactor 7/8 1159 CreditAgingInterval 5 seconds 1161 These parameter values work well when the host transfers a file to 1162 the peer via a TCP connection and the end-to-end round-trip time does 1163 not exceed 500 milliseconds. Alternative credit-aging algorithms may 1164 use other parameter values or different parameters, which may even be 1165 dynamically established. 1167 6. Security Considerations 1169 The HIP mobility mechanism provides a secure means of updating a 1170 host's IP address via HIP UPDATE packets. Upon receipt, a HIP host 1171 cryptographically verifies the sender of an UPDATE, so forging or 1172 replaying a HIP UPDATE packet is very difficult (see 1173 [I-D.ietf-hip-rfc5201-bis]). Therefore, security issues reside in 1174 other attack domains. The two we consider are malicious redirection 1175 of legitimate connections as well as redirection-based flooding 1176 attacks using this protocol. This can be broken down into the 1177 following: 1179 Impersonation attacks 1181 - direct conversation with the misled victim 1183 - man-in-the-middle attack 1185 DoS attacks 1187 - flooding attacks (== bandwidth-exhaustion attacks) 1189 * tool 1: direct flooding 1190 * tool 2: flooding by zombies 1192 * tool 3: redirection-based flooding 1194 - memory-exhaustion attacks 1196 - computational-exhaustion attacks 1198 We consider these in more detail in the following sections. 1200 In Section 6.1 and Section 6.2, we assume that all users are using 1201 HIP. In Section 6.3 we consider the security ramifications when we 1202 have both HIP and non-HIP users. Security considerations for Credit- 1203 Based Authorization are discussed in [SIMPLE-CBA]. 1205 6.1. Impersonation Attacks 1207 An attacker wishing to impersonate another host will try to mislead 1208 its victim into directly communicating with them, or carry out a man- 1209 in-the-middle (MitM) attack between the victim and the victim's 1210 desired communication peer. Without mobility support, both attack 1211 types are possible only if the attacker resides on the routing path 1212 between its victim and the victim's desired communication peer, or if 1213 the attacker tricks its victim into initiating the connection over an 1214 incorrect routing path (e.g., by acting as a router or using spoofed 1215 DNS entries). 1217 The HIP extensions defined in this specification change the situation 1218 in that they introduce an ability to redirect a connection (like 1219 IPv6), both before and after establishment. If no precautionary 1220 measures are taken, an attacker could misuse the redirection feature 1221 to impersonate a victim's peer from any arbitrary location. The 1222 authentication and authorization mechanisms of the HIP base exchange 1223 [I-D.ietf-hip-rfc5201-bis] and the signatures in the UPDATE message 1224 prevent this attack. Furthermore, ownership of a HIP association is 1225 securely linked to a HIP HI/HIT. If an attacker somehow uses a bug 1226 in the implementation or weakness in some protocol to redirect a HIP 1227 connection, the original owner can always reclaim their connection 1228 (they can always prove ownership of the private key associated with 1229 their public HI). 1231 MitM attacks are always possible if the attacker is present during 1232 the initial HIP base exchange and if the hosts do not authenticate 1233 each other's identities. However, once the opportunistic base 1234 exchange has taken place, even a MitM cannot steal the HIP connection 1235 anymore because it is very difficult for an attacker to create an 1236 UPDATE packet (or any HIP packet) that will be accepted as a 1237 legitimate update. UPDATE packets use HMAC and are signed. Even 1238 when an attacker can snoop packets to obtain the SPI and HIT/HI, they 1239 still cannot forge an UPDATE packet without knowledge of the secret 1240 keys. 1242 6.2. Denial-of-Service Attacks 1244 6.2.1. Flooding Attacks 1246 The purpose of a denial-of-service attack is to exhaust some resource 1247 of the victim such that the victim ceases to operate correctly. A 1248 denial-of-service attack can aim at the victim's network attachment 1249 (flooding attack), its memory, or its processing capacity. In a 1250 flooding attack, the attacker causes an excessive number of bogus or 1251 unwanted packets to be sent to the victim, which fills their 1252 available bandwidth. Note that the victim does not necessarily need 1253 to be a node; it can also be an entire network. The attack basically 1254 functions the same way in either case. 1256 An effective DoS strategy is distributed denial of service (DDoS). 1257 Here, the attacker conventionally distributes some viral software to 1258 as many nodes as possible. Under the control of the attacker, the 1259 infected nodes, or "zombies", jointly send packets to the victim. 1260 With such an 'army', an attacker can take down even very high 1261 bandwidth networks/victims. 1263 With the ability to redirect connections, an attacker could realize a 1264 DDoS attack without having to distribute viral code. Here, the 1265 attacker initiates a large download from a server, and subsequently 1266 redirects this download to its victim. The attacker can repeat this 1267 with multiple servers. This threat is mitigated through reachability 1268 checks and credit-based authorization. Both strategies do not 1269 eliminate flooding attacks per se, but they preclude: (i) their use 1270 from a location off the path towards the flooded victim; and (ii) any 1271 amplification in the number and size of the redirected packets. As a 1272 result, the combination of a reachability check and credit-based 1273 authorization lowers a HIP redirection-based flooding attack to the 1274 level of a direct flooding attack in which the attacker itself sends 1275 the flooding traffic to the victim. 1277 6.2.2. Memory/Computational-Exhaustion DoS Attacks 1279 We now consider whether or not the proposed extensions to HIP add any 1280 new DoS attacks (consideration of DoS attacks using the base HIP 1281 exchange and updates is discussed in [I-D.ietf-hip-rfc5201-bis]). A 1282 simple attack is to send many UPDATE packets containing many IP 1283 addresses that are not flagged as preferred. The attacker continues 1284 to send such packets until the number of IP addresses associated with 1285 the attacker's HI crashes the system. Therefore, there SHOULD be a 1286 limit to the number of IP addresses that can be associated with any 1287 HI. Other forms of memory/computationally exhausting attacks via the 1288 HIP UPDATE packet are handled in the base HIP document 1289 [I-D.ietf-hip-rfc5201-bis]. 1291 A central server that has to deal with a large number of mobile 1292 clients may consider increasing the SA lifetimes to try to slow down 1293 the rate of rekeying UPDATEs or increasing the cookie difficulty to 1294 slow down the rate of attack-oriented connections. 1296 6.3. Mixed Deployment Environment 1298 We now assume an environment with both HIP and non-HIP aware hosts. 1299 Four cases exist. 1301 1. A HIP host redirects its connection onto a non-HIP host. The 1302 non-HIP host will drop the reachability packet, so this is not a 1303 threat unless the HIP host is a MitM that could somehow respond 1304 successfully to the reachability check. 1306 2. A non-HIP host attempts to redirect their connection onto a HIP 1307 host. This falls into IPv4 and IPv6 security concerns, which are 1308 outside the scope of this document. 1310 3. A non-HIP host attempts to steal a HIP host's session (assume 1311 that Secure Neighbor Discovery is not active for the following). 1312 The non-HIP host contacts the service that a HIP host has a 1313 connection with and then attempts to change its IP address to 1314 steal the HIP host's connection. What will happen in this case 1315 is implementation dependent but such a request should fail by 1316 being ignored or dropped. Even if the attack were successful, 1317 the HIP host could reclaim its connection via HIP. 1319 4. A HIP host attempts to steal a non-HIP host's session. A HIP 1320 host could spoof the non-HIP host's IP address during the base 1321 exchange or set the non-HIP host's IP address as its preferred 1322 address via an UPDATE. Other possibilities exist, but a simple 1323 solution is to prevent the use of HIP address check information 1324 to influence non-HIP sessions. 1326 7. IANA Considerations 1328 This document defines a LOCATOR parameter for the Host Identity 1329 Protocol [I-D.ietf-hip-rfc5201-bis]. This parameter is defined in 1330 Section 4 with a Type of 193. 1332 This document also defines a LOCATOR_TYPE_UNSUPPORTED Notify Message 1333 Type as defined in the Host Identity Protocol specification 1335 [I-D.ietf-hip-rfc5201-bis]. This parameter is defined in Section 5.3 1336 with a value of 46. 1338 8. Authors and Acknowledgments 1340 Pekka Nikander and Jari Arkko originated this document, and Christian 1341 Vogt and Thomas Henderson (editor) later joined as co-authors. Greg 1342 Perkins contributed the initial draft of the security section. Petri 1343 Jokela was a co-author of the initial individual submission. 1345 The authors thank Miika Komu, Mika Kousa, Jeff Ahrenholz, and Jan 1346 Melen for many improvements to the document. 1348 9. References 1350 9.1. Normative references 1352 [I-D.ietf-hip-rfc4423-bis] Moskowitz, R., "Host Identity Protocol 1353 Architecture", 1354 draft-ietf-hip-rfc4423-bis-02 (work in 1355 progress), February 2011. 1357 [I-D.ietf-hip-rfc5201-bis] Moskowitz, R., Heer, T., Jokela, P., and 1358 T. Henderson, "Host Identity Protocol 1359 Version 2 (HIPv2)", 1360 draft-ietf-hip-rfc5201-bis-05 (work in 1361 progress), March 2011. 1363 [I-D.ietf-hip-rfc5202-bis] Jokela, P., Moskowitz, R., Nikander, P., 1364 and J. Melen, "Using the Encapsulating 1365 Security Payload (ESP) Transport Format 1366 with the Host Identity Protocol (HIP)", 1367 draft-ietf-hip-rfc5202-bis-00 (work in 1368 progress), September 2010. 1370 [I-D.ietf-hip-rfc5204-bis] Laganier, J. and L. Eggert, "Host 1371 Identity Protocol (HIP) Rendezvous 1372 Extension", draft-ietf-hip-rfc5204-bis-01 1373 (work in progress), March 2011. 1375 [RFC2119] Bradner, S., "Key words for use in RFCs 1376 to Indicate Requirement Levels", BCP 14, 1377 RFC 2119, March 1997. 1379 [RFC3484] Draves, R., "Default Address Selection 1380 for Internet Protocol version 6 (IPv6)", 1381 RFC 3484, February 2003. 1383 [RFC4291] Hinden, R. and S. Deering, "IP Version 6 1384 Addressing Architecture", RFC 4291, 1385 February 2006. 1387 [RFC4303] Kent, S., "IP Encapsulating Security 1388 Payload (ESP)", RFC 4303, December 2005. 1390 9.2. Informative references 1392 [CBA-MIPv6] Vogt, C. and J. Arkko, "Credit-Based 1393 Authorization for Mobile IPv6 Early 1394 Binding Updates", Work in Progress, 1395 February 2005. 1397 [RFC4225] Nikander, P., Arkko, J., Aura, T., 1398 Montenegro, G., and E. Nordmark, "Mobile 1399 IP Version 6 Route Optimization Security 1400 Design Background", RFC 4225, 1401 December 2005. 1403 [SIMPLE-CBA] Vogt, C. and J. Arkko, "Credit-Based 1404 Authorization for Concurrent Reachability 1405 Verification", Work in Progress, 1406 February 2006. 1408 Appendix A. Document Revision History 1410 To be removed upon publication 1412 +----------+--------------------------------------------------------+ 1413 | Revision | Comments | 1414 +----------+--------------------------------------------------------+ 1415 | draft-00 | Initial version from RFC5206 xml (unchanged). | 1416 | draft-01 | Remove multihoming-specific text; no other changes. | 1417 | draft-02 | Update references to point to -bis drafts; no other | 1418 | | changes. | 1419 +----------+--------------------------------------------------------+ 1421 Authors' Addresses 1423 Pekka Nikander 1424 Ericsson Research NomadicLab 1425 JORVAS FIN-02420 1426 FINLAND 1428 Phone: +358 9 299 1 1429 EMail: pekka.nikander@nomadiclab.com 1430 Thomas R. Henderson (editor) 1431 The Boeing Company 1432 P.O. Box 3707 1433 Seattle, WA 1434 USA 1436 EMail: thomas.r.henderson@boeing.com 1438 Christian Vogt 1439 Ericsson Research NomadicLab 1440 Hirsalantie 11 1441 JORVAS FIN-02420 1442 FINLAND 1444 Phone: 1445 EMail: christian.vogt@ericsson.com 1447 Jari Arkko 1448 Ericsson Research NomadicLab 1449 JORVAS FIN-02420 1450 FINLAND 1452 Phone: +358 40 5079256 1453 EMail: jari.arkko@ericsson.com