idnits 2.17.1 draft-ietf-ipngwg-router-renum-04.txt: ** The Abstract section seems to be numbered Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- ** Cannot find the required boilerplate sections (Copyright, IPR, etc.) in this document. Expected boilerplate is as follows today (2024-04-16) according to https://trustee.ietf.org/license-info : IETF Trust Legal Provisions of 28-dec-2009, Section 6.a: This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79. IETF Trust Legal Provisions of 28-dec-2009, Section 6.b(i), paragraph 2: Copyright (c) 2024 IETF Trust and the persons identified as the document authors. All rights reserved. IETF Trust Legal Provisions of 28-dec-2009, Section 6.b(i), paragraph 3: This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (https://trustee.ietf.org/license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Simplified BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Simplified BSD License. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- ** Missing expiration date. The document expiration date should appear on the first and last page. ** The document seems to lack a 1id_guidelines paragraph about Internet-Drafts being working documents. ** The document seems to lack a 1id_guidelines paragraph about 6 months document validity. ** The document seems to lack a 1id_guidelines paragraph about the list of current Internet-Drafts. ** The document seems to lack a 1id_guidelines paragraph about the list of Shadow Directories. ** The document is more than 15 pages and seems to lack a Table of Contents. == No 'Intended status' indicated for this document; assuming Proposed Standard Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- ** The document seems to lack an Introduction section. ** The document seems to lack an IANA Considerations section. (See Section 2.2 of https://www.ietf.org/id-info/checklist for how to handle the case when there are no actions for IANA.) ** The document seems to lack separate sections for Informative/Normative References. All references will be assumed normative when checking for downward references. Miscellaneous warnings: ---------------------------------------------------------------------------- -- The document seems to lack a disclaimer for pre-RFC5378 work, but may have content which was first submitted before 10 November 2008. If you have contacted all the original authors and they are all willing to grant the BCP78 rights to the IETF Trust, then this is fine, and you can ignore this comment. If not, you may need to add the pre-RFC5378 disclaimer. (See the Legal Provisions document at https://trustee.ietf.org/license-info for more information.) -- The document date (August 7, 1998) is 9384 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) -- Unexpected draft version: The latest known version of draft-ietf-ipngwg-addr-arch-v2 is -06, but you're referring to -07. ** Downref: Normative reference to an Informational RFC: RFC 2104 (ref. 'HMAC') -- Possible downref: Non-RFC (?) normative reference: ref. 'ICMPV6' -- Unexpected draft version: The latest known version of draft-ietf-ipsec-arch-sec is -06, but you're referring to -07. -- Unexpected draft version: The latest known version of draft-ietf-ipngwg-ipv6-spec-v2 is -01, but you're referring to -02. -- Unexpected draft version: The latest known version of draft-ietf-ipngwg-ipv6-mib is -03, but you're referring to -04. ** Downref: Normative reference to an Historic draft: draft-ietf-ipngwg-ipv6-mib (ref. 'IPV6MIB') ** Downref: Normative reference to an Informational RFC: RFC 1321 (ref. 'MD5') -- Unexpected draft version: The latest known version of draft-ietf-ipngwg-discovery-v2 is -02, but you're referring to -03. -- Unexpected draft version: The latest known version of draft-ietf-ipngwg-addrconf-v2 is -01, but you're referring to -02. Summary: 14 errors (**), 0 flaws (~~), 1 warning (==), 9 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 1 IPng Working Group Matt Crawford 2 Internet Draft Fermilab 3 Bob Hinden 4 Nokia 5 August 7, 1998 7 Router Renumbering for IPv6 8 10 Status of this Memo 12 This document is an Internet Draft. Internet Drafts are working 13 documents of the Internet Engineering Task Force (IETF), its Areas, 14 and its Working Groups. Note that other groups may also distribute 15 working documents as Internet Drafts. 17 Internet Drafts are draft documents valid for a maximum of six 18 months. Internet Drafts may be updated, replaced, or obsoleted by 19 other documents at any time. It is not appropriate to use Internet 20 Drafts as reference material or to cite them other than as a 21 ``working draft'' or ``work in progress.'' 23 To view the entire list of current Internet-Drafts, please check the 24 ``1id-abstracts.txt'' listing contained in the Internet Drafts 25 Shadow Directories on ftp.is.co.za (Africa), ftp.nordu.net (Northern 26 Europe), ftp.nis.garr.it (Southern Europe), munnari.oz.au (Pacific 27 Rim), ftp.ietf.org (US East Coast), or ftp.isi.edu (US West Coast). 29 Distribution of this memo is unlimited. 31 1. Abstract 33 IPv6 Neighbor Discovery and Address Autoconfiguration conveniently 34 make initial assignments of address prefixes to hosts. Aside from 35 the problem of connection survival across a renumbering event, these 36 two mechanisms also simplify the reconfiguration of hosts when the 37 set of valid prefixes changes. 39 This document defines a mechanism called Router Renumbering ("RR") 40 which allows address prefixes on routers to be configured and 41 reconfigured almost as easily as the combination of Neighbor 42 Discovery and Address Autoconfiguration works for hosts. It 43 provides a means for a network manager to make updates to the 44 prefixes used by and advertised by IPv6 routers throughout a site. 46 2. Functional Overview 48 Router Renumbering Command packets contain a sequence of Prefix 49 Control Operations (PCOs). Each PCO specifies an operation, a 50 Match-Prefix, and zero or more Use-Prefixes. A router processes 51 each PCO in sequence, checking each of its interfaces for an address 52 or prefix which matches the Match-Prefix. For every interface on 53 which a match is found, the operation is applied. The operation is 54 one of ADD, CHANGE, or SET-GLOBAL to instruct the router to 55 respectively add the Use-Prefixes to the set of configured prefixes, 56 remove the prefix which matched the Match-Prefix and replace it with 57 the Use-Prefixes, or replace all global-scope prefixes with the 58 Use-Prefixes. If the set of Use-Prefixes in the PCO is empty, the 59 ADD operation does nothing and the other two reduce to deletions. 61 Additional information for each Use-Prefix is included in the Prefix 62 Control Operation: the valid and preferred lifetimes to be included 63 in Router Advertisement Prefix Information Options [ND], and either 64 the L and A flags for the same option, or an indication that they 65 are to be copied from the prefix that matched the Match-Prefix. 67 It is possible to instruct routers to create new prefixes by 68 combining the Use-Prefixes in a PCO with some portion of the 69 existing prefix which matched the Match-Prefix. This simplifies 70 certain operations which are expected to be among the most common. 71 For every Use-Prefix, the PCO specifies a number of bits which 72 should be copied from the existing address or prefix which matched 73 the Match-Prefix and appended to the use-prefix prior to configuring 74 the new prefix on the interface. The copied bits are zero or more 75 bits from the positions immediately after the length of the Use- 76 Prefix. If subnetting information is in the same portion of the old 77 and new prefixes, this synthesis allows a single Prefix Control 78 Operation to define a new global prefix on every router in a site, 79 while preserving the subnetting structure. 81 Because of the power of the Router Renumbering mechanism, each RR 82 message includes a sequence number and an authenticator to guard 83 against replays. Each single Prefix Control Operation is idempotent 84 and so could be retransmitted for improved reliability, as long as 85 the sequence number is current, without concern about multiple 86 processing. However, non-idempotent combinations of PCOs can easily 87 be constructed and messages containing such combinations could not 88 be safely reprocessed. Therefore, all routers are required to guard 89 against processing an RR message more than once. To allow reliable 90 verification that Commands have been received and processed by 91 routers, a mechanism for duplicate-command notification to the 92 management station is included. 94 Possibly a network manager will want to perform more renumbering, or 95 exercise more detailed control, than can be expressed in a single 96 Router Renumbering packet on the available media. The RR mechanism 97 is most powerful when RR packets are multicast, so IP fragmentation 98 is undesirable. For these reasons, each RR packet contains a 99 "Segment Number". All RR packets which have a Sequence Number 100 greater than or equal to the highest value seen (for each valid 101 key), and which pass the authentication check, are valid and must be 102 processed. However, a router must keep track of the Segment Numbers 103 of RR messages already processed and avoid reprocessing a message 104 whose Sequence Number and Segment Number match a previously 105 processed message. (This list of processed segment numbers is reset 106 when a new highest Sequence Number is seen.) 108 The Segment Number does not impose an ordering on packet processing. 109 If a specific sequence of operations is desired, it may be achieved 110 by ordering the PCOs in a single RR Command message or through the 111 Sequence Number field. 113 There is a "Test" flag which indicates that all routers should 114 simulate processing of the RR message and not perform any actual 115 reconfiguration. A separate "Report" flag instructs routers to send 116 a Router Renumbering Result message back to the source of the RR 117 Command message indicating the actual or simulated result of the 118 operations in the RR Command message. 120 The effect or simulated effect of an RR Command message may also 121 reported to network management by means outside the scope of this 122 document, regardless of the value of the "Report" flag. 124 3. Definitions 126 3.1. Terminology 128 Address 129 This term always refers to a 128-bit IPv6 address [AARCH]. When 130 referring to bits within an address, they are numbered from 0 to 131 127, with bit 0 being the first bit of the Format Prefix. 133 Prefix 134 A prefix can be understood as an address plus a length, the 135 latter being an integer in the range 0 to 128 indicating how many 136 leading bits are significant. When referring to bits within a 137 prefix, they are numbered in the same way as the bits of an 138 address. For example, the significant bits of a prefix whose 139 length is L are the bits numbered 0 through L-1, inclusive. 141 Match 142 An address A "matches" a prefix P whose length is L if the first 143 L bits of A are identical with the first L bits of P. (Every 144 address matches a prefix of length 0.) A prefix P1 with length 145 L1 matches a prefix P2 of length L2 if L1 >= L2 and the first L2 146 bits of P1 and P2 are identical. 148 Prefix Control Operation 149 This is the smallest individual unit of Router Renumbering 150 operation. A Router Renumbering Command packet includes zero or 151 more of these, each comprising one matching condition, called a 152 Match-Prefix Part, and zero or more substitution specifications, 153 called Use-Prefix Parts. 155 Match-Prefix 156 This is a Prefix against which a router compares the addresses 157 and prefixes configured on its interfaces. 159 Use-Prefix 160 The prefix and associated information which is to be configured 161 on a router interface when certain conditions are met. 163 Matched Prefix 164 The existing prefix or address which matched a Match-Prefix. 166 New Prefix 167 A prefix constructed from a Use-Prefix, possibly including some 168 of the Matched Prefix. 170 Recorded Sequence Number 171 The highest sequence number found in a valid, authenticated 172 message with a given key MUST be recorded in non-volatile storage 173 along with that key. 175 Note that "matches" is a transitive relation but not symmetric. If 176 two prefixes match each other, they are identical. 178 3.2. Requirements 180 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 181 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 182 document are to be interpreted as described in [KWORD]. 184 3.3. Authentication Algorithms 186 All implementations MUST support HMAC-MD5 [HMAC] for authentication. 187 Additional algorithms MAY be supported. 189 4. Message Format 191 There are two types of Router Renumbering messages: Commands, which 192 are sent to routers, and Results, which are sent by routers. The 193 two types of messages are distinguished the ICMPv6 "Code" field and 194 differ in the contents of the "Message Body" field. 196 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 197 | | 198 / IPv6 header, extension headers / 199 | | 200 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 201 | | 202 / ICMPv6 & RR Header (16 octets) / 203 | | 204 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 205 | | 206 / RR Message Body / 207 | | 208 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 209 | | 210 / Authentication Data (16 octets for HMAC-MD5) / 211 | | 212 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 214 Router Renumbering Message Format 216 Router Renumbering messages are carried in ICMPv6 packets with 217 Type = 138. The RR message comprises 219 An RR header, containing the ICMPv6 header, the sequence and 220 segment numbers and information about the authentication key and 221 the location and length of the authentication data within the 222 packet. 224 The RR Message Body, of variable length; 226 The authentication data, with length dependent on the 227 authentication type. The length of HMAC-MD5 authentication data 228 is 16 octets. 230 All fields marked "reserved" or "res" MUST be set to zero on 231 generation of an RR message. During processing of the message they 232 MUST be included in the authentication check, but otherwise ignored. 234 All implementations which generate Router Renumbering Command 235 messages MUST support sending them to the All Routers multicast 236 address with link and site scopes, and to unicast addresses of 237 link-local and site-local formats. All routers MUST be capable of 238 receiving RR messages sent to those multicast addresses and to any 239 of their link local and site local unicast addresses. 240 Implementations SHOULD support sending and receiving RR messages 241 addressed to other unicast addresses. 243 4.1. Router Renumbering Header 245 0 1 2 3 246 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 247 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 248 | Type | Code | Checksum | 249 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 250 | SequenceNumber | 251 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 252 | SegmentNumber | Flags | MaxDelay | AuthLen | 253 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 254 | AuthOffset | KeyID | 255 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 257 Fields: 259 Type 138 (decimal), the ICMPv6 type value assigned to Router 260 Renumbering 262 Code 0 for a Router Renumbering Command 263 1 for a Router Renumbering Result 265 Checksum The ICMPv6 checksum, as specified in [ICMPV6]. The 266 checksum covers the IPv6 pseudo-header and all fields of 267 the RR message from the Type field through the 268 Authentication Data. (For purposes of calculating and 269 verifying the Authentication Data, the ICMPv6 checksum 270 field is considered to be zero.) 272 SequenceNumber 273 An unsigned 32-bit sequence number. The sequence number 274 MUST be non-decreasing for all messages sent with a 275 given KeyID, for the lifetime of that key. 277 SegmentNumber 278 An unsigned 8-bit field which enumerates different valid 279 RR messages having the same SequenceNumber and KeyID. 280 No ordering among RR messages is imposed by the 281 SegmentNumber. 283 Flags A combination of one-bit flags. Six are defined and two 284 bits are reserved. 286 +-+-+-+-+-+-+-+-+ 287 |T|R|A|S|P| res | 288 +-+-+-+-+-+-+-+-+ 290 The flags T, R, A and S have defined meanings in an RR 291 Command message. In a Result message they MUST be 292 copied from the corresponding Command. The P flag is 293 meaningful only in a Result message and MUST be zero in 294 a Command. 296 T 0 indicates that the router configuration is to be 297 modified; 298 1 indicates a "Test" message: processing is to be 299 simulated and no configuration changes are to be 300 made. 302 R 0 indicates that a Result message MUST NOT be sent 303 (but other forms of logging are not precluded); 304 1 indicates that the router MUST send a Result 305 message upon completion of processing the Command 306 message; 308 A 0 indicates that the Command MUST NOT be applied to 309 interfaces which are administratively shut down; 310 1 indicates that the Command MUST be applied to 311 interfaces regardless of administrative shutdown 312 status. 314 S This flag MUST be ignored unless the router treats 315 interfaces as belonging to different "sites". 316 0 indicates that the Command MUST be applied to 317 interfaces regardless of which site they belong 318 to; 319 1 indicates that the Command MUST be applied only to 320 interfaces which belong to the same site as the 321 interface to which the Command is addressed. If 322 the destination address is appropriate for 323 interfaces belonging to more than one site, then 324 the Command MUST be applied only to interfaces 325 belonging to the same site as the interface on 326 which the Command was received. 328 P 0 indicates that the Result message contains the 329 complete report of processing the Command; 330 1 indicates that the Command message was previously 331 processed (and is not a Test) and the responding 332 router is not processing it again. This Result 333 message MAY have an empty body. 335 MaxDelay The maximum number of seconds by which a router MUST 336 delay sending any reply to this Command. Although this 337 field carries an integral number of seconds, routers 338 SHOULD generate the random delay between 0 and MaxDelay 339 with a finer granularity. 341 AuthLen An unsigned 16-bit field giving the length in octets of 342 the Authentication Data. 344 AuthOffset An unsigned 16-bit offset, measured in octets, from the 345 beginning of the RR message (which is the beginning of 346 the ICMPv6 header) to the beginning of the 347 Authentication Data. The smallest valid value for 348 AuthOffset is 16. 350 KeyID An unsigned 16-bit field that identifies the key used to 351 create and verify the Authentication Data for this RR 352 message. If multiple authentication algorithms are 353 supported by the implementation, the choice of algorithm 354 is implicit in the KeyID. If an asymmetric scheme is 355 used, the public key for verification of received 356 messages and the private key for signing transmitted 357 messages are both implied by the KeyID. 359 4.2. Message Body -- Command Message 361 The body of an RR Command message is a sequence of zero or more 362 Prefix Control Operations, each of variable length. The end of the 363 sequence MAY be located by the AuthOffset field in the RR header. 365 4.2.1. Prefix Control Operation 367 A Prefix Control Operation has one Match-Prefix Part of 24 octets, 368 followed by zero or more Use-Prefix Parts of 32 octets each. 370 4.2.1.1. Match-Prefix Part 372 0 1 2 3 373 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 374 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 375 | OpCode | OpLength | Ordinal | MatchLen | 376 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 377 | reserved | 378 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 379 | | 380 +- -+ 381 | | 382 +- MatchPrefix -+ 383 | | 384 +- -+ 385 | | 386 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 388 Fields: 390 OpCode An unsigned 8-bit field specifying the operation to be 391 performed when the associated MatchPrefix matches an 392 interface's prefix or address. Values are: 394 1 the ADD operation 396 2 the CHANGE operation 398 3 the SET-GLOBAL operation 400 OpLength The total length of this Prefix Control Operation, in 401 units of 8 octets. A valid OpLength will always be of 402 the form 4N+3, with N equal to the number of UsePrefix 403 parts (possibly zero). 405 Ordinal An 8-bit field which MUST have a different value in each 406 Prefix Control Operation contained in a given RR Command 407 message. The value is otherwise unconstrained. 409 MatchLen An 8-bit unsigned integer between 0 and 128 inclusive 410 specifying the number of initial bits of MatchPrefix 411 which are significant in matching. 413 MatchPrefix The 128-bit prefix to be compared with each interface's 414 prefix or address. 416 4.2.1.2. Use-Prefix Part 418 0 1 2 3 419 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 420 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 421 | UseLen | KeepLen | FlagMask | RAFlags | 422 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 423 | Valid Lifetime | 424 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 425 | Preferred Lifetime | 426 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 427 |V|P| reserved | 428 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 429 | | 430 +- -+ 431 | | 432 +- UsePrefix -+ 433 | | 434 +- -+ 435 | | 436 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 438 Fields: 440 UseLen An 8-bit unsigned integer less than or equal to 128 441 specifying the number of initial bits of UsePrefix to 442 use in creating a new prefix for an interface. 444 KeepLen An 8-bit unsigned integer less than or equal to (128- 445 UseLen) specifying the number of bits of the prefix or 446 address which matched the associated Match-Prefix which 447 should be retained in the new prefix. The retained bits 448 are those at positions UseLen through (UseLen+KeepLen-1) 449 in the matched address or prefix, and they are copied to 450 the same positions in the New Prefix. 452 FlagMask An 8-bit mask. A 1 bit in any position means that the 453 corresponding flag bit in a Router Advertisement (RA) 454 Prefix Information Option for the New Prefix should be 455 set from the RAFlags field in this Use-Prefix Part. A 0 456 bit in the FlagMask means that the RA flag bit for the 457 New Prefix should be copied from the corresponding RA 458 flag bit of the Matched Prefix. 460 RAFlags An 8 bit field which, under control of the FlagMask 461 field, may be used to initialize the flags in Router 462 Advertisement Prefix Information Options [ND] which 463 advertise the New Prefix. Note that only two flags have 464 defined meanings to date: the L (on-link) and A 465 (autonomous configuration) flags. These flags occupy 466 the two leftmost bit positions in the RAFlags field, 467 corresponding to their position in the Prefix 468 Information Option. 470 Valid Lifetime 471 A 32-bit unsigned integer which is the number of seconds 472 for which the New Prefix will be valid [ND, SAA]. 474 Preferred Lifetime 475 A 32-bit unsigned integer which is the number of seconds 476 for which the New Prefix will be preferred [ND, SAA]. 478 V A 1-bit flag indicating that the valid lifetime of the 479 New Prefix MUST be effectively decremented in real time. 481 P A 1-bit flag indicating that the preferred lifetime of 482 the New Prefix MUST be effectively decremented in real 483 time. 485 UsePrefix The 128-bit Use-prefix which either becomes or is used 486 in forming (if KeepLen is nonzero) the New Prefix. It 487 MUST NOT have the form of a multicast or link-local 488 address [AARCH]. 490 4.3. Message Body -- Result Message 492 The body of an RR Result message is a sequence of zero or more Match 493 Reports of 24 octets. An RR Command message with the "R" flag set 494 will elicit an RR Result message containing one Match Report for 495 each Prefix Control Operation, for each different prefix it matches 496 on each interface. The Match Report has the following format. 498 0 1 2 3 499 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 500 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 501 | reserved |F| Ordinal | MatchedLen | 502 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 503 | InterfaceIndex | 504 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 505 | | 506 +- -+ 507 | | 508 +- MatchedPrefix -+ 509 | | 510 +- -+ 511 | | 512 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 514 Fields: 516 F A one-bit flag which, when set, indicates that one or 517 more Use-Prefix parts from the associated PCO were not 518 honored by the router because of attempted formation of 519 a forbidden prefix format, such as a multicast or 520 loopback address. 522 Ordinal Copied from the Prefix Control Operation whose 523 MatchPrefix matched the MatchedPrefix on the interface 524 indicated by InterfaceIndex. 526 MatchedLen The length of the Matched Prefix. 528 InterfaceIndex 529 The router's numeric designation of the interface on 530 which the MatchedPrefix was configured. This MUST be 531 the same as the value of ipv6IfIndex which designates 532 that index in the SNMP IPv6 MIB General Group [IPV6MIB]. 534 It is possible for a Result message to be larger than the Command 535 message which elicited it. Such a Result message may have to be 536 fragmented for transmission. If so, it SHOULD be fragmented to the 537 IPv6 minimum required MTU [IPV6]. 539 4.4. Authentication 541 The authentication covers the following fields, which are to be 542 treated as contiguous data for the purpose of computing and 543 verifying the AuthData. 544 The IPv6 source address, 545 The IPv6 destination address, 546 The ICMPv6 and RR Header, 547 The RR Message Body (which may be empty). 549 Before generating the AuthData, all fields of the RR header and all 550 the PCOs are filled in, except that the ICMPv6 checksum field is set 551 to zero. AuthLen will be an algorithm-dependent constant and 552 AuthOffset will be equal to the length in octets of the RR message, 553 not including the AuthData, the IPv6 header or any extension 554 headers, but including the ICMPv6 header. 556 When checking the AuthData, the ICMPv6 checksum must be treated as 557 zero. 559 4.4.1. HMAC-MD5 561 When the key and algorithm associated with the KeyID indicate that 562 HMAC-MD5 authentication is to be used, the AuthData is generated in 563 accordance with RFC 2104 [HMAC] and RFC 1321 [MD5]. AuthLen will be 564 16. 566 4.4.2. IPSEC 568 The KeyID value zero is reserved to indicate that no Authentication 569 is done on the Router Renumbering message itself. An RR message 570 with Key ID zero MUST have AuthLen equal to zero and AuthOffset 571 equal to the total length of the ICMPv6/RR header plus the RR 572 message body. Such a message MUST be authenticated at the IP layer 573 [SECARCH]. 575 As IPsec anti-replay processing may interact badly with the Router 576 Renumbering reliability mechanism, IPsec's anti-reply services MUST 577 NOT be used. Sequence Numbers and Segment Numbers of IPsec- 578 authenticated Commands MUST be recorded in association the with 579 KeyID of zero. This information need not be cleared when a new 580 Security Association is created, but some means of clearing it MUST 581 be provided. 583 Note that while Router Renumbering Commands are intended to be most 584 commonly sent to multicast addresses, "IPsec SA management 585 mechanisms currently are defined only for unicast SAs." [SECARCH] 587 5. Message Processing 589 Processing of received Router Renumbering Result messages is 590 entirely implementation-defined. 592 Processing of received Router Renumbering Command messages consists 593 of three parts: header check, authentication check, and execution. 595 5.1. Header Check 597 The ICMPv6 checksum, type and code are presumed to have been checked 598 before a Router Renumbering module receives a Command to process. 599 An an implementation environment where this may not be the case, 600 these checks MUST be made at this point in the processing. 602 If the ICMPv6 length derived from the IPv6 length is less than 16 603 octets, the message MUST be discarded and SHOULD be logged to 604 network management. 606 If the IPv6 destination address is neither an All Routers multicast 607 address [AARCH] nor one of the receiving router's unicast addresses, 608 the message MUST be discarded and SHOULD be logged to network 609 management. 611 Then, the existence and validity of the key indicated by the KeyID 612 are checked. If KeyID and AuthLen are zero and the message was not 613 authenticated by IP layer security, or if KeyID is not zero and does 614 not indicate a valid key, or if the value of AuthLen is not correct 615 for the indicated key, then the message MUST be discarded and SHOULD 616 be logged to network management. 618 Next, the SequenceNumber is compared to the Recorded Sequence Number 619 for the specified key. (If no messages have been received and 620 accepted using this key, the Recorded Sequence Number is zero.) 621 This comparison is done with the two numbers considered as unsigned 622 integers, not as DNS-style serial numbers. If the SequenceNumber is 623 less than the Recorded Sequence Number for the key, the message MUST 624 be discarded and SHOULD be logged to network management. 626 Finally, if the SequenceNumber in the message is greater than the 627 Recorded Sequence Number or the T flag is set, skip to the 628 Authentication Check. Otherwise the SegmentNumber MUST now be 629 checked. If a correctly authenticated message with the same KeyID, 630 SequenceNumber and SegmentNumber has not already been processed, 631 skip to the Authentication Check. Otherwise, this Command is a 632 duplicate and not a Test Command. If the R flag is not set, the 633 duplicate message MUST be discarded and SHOULD NOT be logged to 634 network management. If R is set, an RR Result message with the P 635 flag set MUST be scheduled for transmission to the source address of 636 the Command after a random time uniformly distributed between 0 and 637 MaxDelay seconds. The body of that Result message MUST either be 638 empty or be a saved copy of the Result message body generated by 639 processing of the previous message with the same KeyID, 640 SequenceNumber and SegmentNumber. After scheduling the Result 641 message, the Command MUST be discarded without further processing. 643 5.2. Authentication Check 645 The authentication check is performed over the data listed in 646 section 4.4. If the computed authentication value is not equal to 647 the AuthData in the received packet, the authentication check fails. 649 If the authentication check fails, the message MUST be discarded and 650 SHOULD be logged to network management. 652 If the authentication check passes, and the SequenceNumber is 653 greater than the Recorded Sequence Number for the key, then the list 654 of processed SegmentNumbers and the set of saved Result messages, if 655 any, MUST be cleared and the Recorded Sequence Number MUST be 656 updated to the value used in the current message, regardless of 657 subsequent processing errors. 659 At this point, if T is set and R is not set, the message MAY be 660 discarded without further processing. 662 5.3. Execution 664 For each applicable router interface, as determined by the A and S 665 flags, the Prefix Control Operations in an RR Command message must 666 be carried out in order of appearance. The relative order of PCO 667 processing among different interfaces is not specified. 669 If the T flag is set, create a copy of each interface's 670 configuration on which to operate, because the results of processing 671 a PCO may affect the processing of subsequent PCOs. Note that if 672 all operations are performed on one interface before proceeding to 673 another interface, only one interface-configuration copy will be 674 required at a time. 676 If the R flag is set in the RR header, begin constructing an RR 677 Result message. The RR header is completely determined at this time 678 except for the Checksum and AuthOffset. 680 For each interface and for each Prefix Control Operation, each 681 prefix configured on that interface is tested to determine whether 682 it matches (as defined in section 3.1) the MatchPrefix of the PCO. 683 The prefixes are tested in an arbitrary order. Any new prefix 684 configured on an interface by the effect of a given PCO MUST NOT be 685 tested against that PCO, but MUST be tested against any subsequent 686 PCOs in the same RR Command message. 688 Under a certain condition the addresses on an interface are also 689 tested to see whether any of them matches the MatchPrefix. If and 690 only if a configured prefix "P" does not match the MatchPrefix "M" 691 but M does match P (this can happen only if M is longer than P), 692 then those addresses on that interface which match P MUST be tested 693 to determine whether any of them matches M. If any such address 694 does match M, process the PCO as if P matched M, but when forming 695 New Prefixes, if KeepLen is non-zero, bits are copied from the 696 address. This special case allows a PCO to be easily targeted to a 697 single specific interface in a network. 699 If P does not match M, processing is finished for this combination 700 of PCO, interface and prefix. Continue with another prefix on the 701 same interface if there are any more prefixes which have not been 702 tested against this PCO and were not created by the action of this 703 PCO. If no such prefixes remain on the current interface, continue 704 processing with the next PCO on the same interface, or with another 705 interface. 707 If P does match M, either directly or because a configured address 708 which matches P also matches M, then P is the Matched Prefix. 709 Perform the following steps. 711 If the Command has the R flag set, add a Match Report to 712 the Result message being constructed. 714 If the OpCode is CHANGE, mark P for deletion from the 715 current interface. 717 If the OpCode is SET-GLOBAL, mark all global-scope 718 prefixes on the current interface for deletion. 720 If there are any Use-Prefix parts in the current PCO, form 721 the New Prefixes. Discard any New Prefix which has a 722 forbidden format, and if the R flag is set in the command, 723 set the F flag in the Match Report for this PCO and 724 interface. Forbidden prefix formats include, at a 725 minimum, multicast, unspecified and loopback addresses. 726 [AARCH] Any implementation MAY forbid, or allow the 727 network manager to forbid other formats as well. 729 For each New Prefix which is already configured on the 730 current interface, unmark that prefix for deletion and 731 update the lifetimes and RA flags. For each New Prefix 732 which is not already configured, add the prefix and, if 733 appropriate, configure an address with that prefix. 735 Delete any prefixes which are still marked for deletion, 736 together with any addresses which match those prefixes but 737 do not match any prefix which is not marked for deletion. 739 After processing all the Prefix Control Operations on all the 740 interfaces, an implementation MUST record the SegmentNumber of the 741 packet in a list associated with the KeyID and SequenceNumber. 743 If the Command has the R flag set, compute the AuthData and append 744 it to the Result message, fill in the AuthOffset and Checksum and 745 schedule the Result message for transmission after a random time 746 uniformly distributed between 0 and MaxDelay seconds. A copy of the 747 Result message MAY be saved to be retransmitted in response to a 748 duplicate Command. 750 The only Neighbor Discovery [ND] parameters which can be affected by 751 Router Renumbering are the following. 753 A router's addresses and advertised prefixes, including the 754 prefix lengths. 756 The flag bits (L and A, and any which may be defined in the 757 future) and the valid and preferred lifetimes which appear in a 758 Router Advertisement Prefix Information Option. 760 The unnamed property of the lifetimes, which specifies whether 761 they are fixed or decrementing. 763 Other internal router information, such as the time until the next 764 unsolicited Router Advertisement or MIB variables MAY be affected as 765 needed. 767 6. Key Management 769 As with all security methods using keys, it is necessary to change 770 the RR Authentication Key on a regular basis. To provide RR 771 functionality during key changes, implementations MUST be able to 772 store and use more than one Authentication Key at the same time. 774 The Authentication Keys SHOULD NOT be stored or transmitted using 775 algorithms or protocols that have known flaws. Implementations MUST 776 support the storage of more than one key at the same time, MUST 777 associate a specific lifetime (start and end times) and a key 778 identifier with each key, and MUST support manual key distribution 779 (e.g., manual entry of the key, key lifetime, and key identifier on 780 the router console). 782 An infinite key lifetime SHOULD NOT be allowed. If infinite 783 lifetimes are allowed, manual deletion of valid keys MUST be 784 supported; otherwise manual deletion SHOULD be supported. The 785 implementation MAY automatically delete expired keys. 787 7. Usage Examples 789 This section sketches some sample applications of Router 790 Renumbering. 792 7.1. Maintaining Global-Scope Prefixes 794 A simple use of the Router Renumbering mechanism, and one which is 795 expected to to be common, is the maintenance of a set of global 796 prefixes with a subnet structure that matches that of the site's 797 site-local address assignments. In the steady state this would 798 serve to keep the Preferred and Valid lifetimes set to their desired 799 values. During a renumbering transition, similar Command messages 800 can add new prefixes and/or delete old ones. An outline of a 801 suitable Command message follows. Fields not listed are presumed 802 set to suitable values. This Command assumes all router interfaces 803 to be maintained already have site-local [AARCH] addresses. 805 IPv6 Header 806 Next Header = 58 (ICMPv6) 807 Source Address = (Management Station) 808 Destination Address = FF05::2 (All Routers, site-local scope) 810 ICMPv6/RR Header 811 Type = 138 (Router Renumbering), Code = 0 (Command) 812 Flags = 60 hex (R, A) 813 AuthOffset = 32 N + 24 (assuming N global prefixes) 815 First (and only) PCO: 817 Match-Prefix Part 818 OpCode = 3 (SET-GLOBAL) 819 OpLength = 4 N + 3 (assuming N global prefixes) 820 Ordinal = 0 (arbitrary) 821 MatchLen = 10 822 MatchPrefix = FEC0::0 824 First Use-Prefix Part 825 UseLen = 48 (Length of TLA ID + RES + NLA ID [AARCH]) 826 KeepLen = 16 (Length of SLA (subnet) ID [AARCH]) 827 FlagMask, RAFlags, Lifetimes, V & P flags -- as desired 828 UsePrefix = First global /48 prefix 830 . . . 832 Nth Use-Prefix Part 833 UseLen = 48 834 KeepLen = 16 835 FlagMask, RAFlags, Lifetimes, V & P flags -- as desired 836 UsePrefix = Last global /48 prefix 838 This will cause N global prefixes to be set (or updated) on each 839 applicable interface. On each interface, the SLA ID (subnet) field 840 of each global prefix will be copied from the existing site-local 841 prefix. 843 7.2. Renumbering a Subnet 845 A subnet can be gracefully renumbered by setting the valid and 846 preferred timers on the old prefix to a short value and having them 847 run down, while concurrently adding adding the new prefix. Later, 848 the expired prefix is deleted. The first step is described by the 849 following RR Command. 851 IPv6 Header 852 Next Header = 58 (ICMPv6) 853 Source Address = (Management Station) 854 Destination Address = FF05::2 (All Routers, site-local scope) 856 ICMPv6/RR Header 857 Type = 138 (Router Renumbering), Code = 0 (Command) 858 Flags = 60 hex (R, A) 859 AuthOffset = 88 861 First (and only) PCO: 863 Match-Prefix Part 864 OpCode = 2 (CHANGE) 865 OpLength = 11 (reflects 2 Use-Prefix Parts) 866 Ordinal = 0 (arbitrary) 867 MatchLen = 64 868 MatchPrefix = Old /64 prefix 870 First Use-Prefix Part 871 UseLen = 0 872 KeepLen = 64 (this retains the old prefix value intact) 873 FlagMask = 0, RAFlags = 0 874 Valid Lifetime = 28800 seconds (8 hours) 875 Preferred Lifetime = 7200 seconds (2 hours) 876 V flag = 1, P flag = 1 877 UsePrefix = 0::0 879 Second Use-Prefix Part 880 UseLen = 64 881 KeepLen = 0 882 FlagMask = 0, RAFlags = 0 883 Lifetimes, V & P flags -- as desired 884 UsePrefix = New /64 prefix 886 The second step, deletion of the old prefix, can be done by an RR 887 Command with the same Match-Prefix Part (except for an OpLength 888 reduced from 11 to 3) and no Use-Prefix Parts. Any temptation to 889 set KeepLen = 64 in the second Use-Prefix Part above should be 890 resisted, as it would instruct the router to sidestep address 891 configuration. 893 7.3. Key Changes 895 Using a new authentication key while a previously used key is still 896 valid can open the possibility of a replay attack. The processing 897 rules as given in section 5 specify that routers keep track of the 898 highest sequence number seen for each key, and that messages with 899 that key and sequence number remain valid until either a higher 900 sequence number is seen or the key expires. The difficulty arises 901 when a new key is used to send a message which supersedes the last 902 message sent with another still-valid key. That older message can 903 still be replayed. 905 This vulnerability can be avoided in practice by sending a "NO-OP" 906 Command message with the old key and a valid new sequence number 907 before using a newer key. This message will then become the only 908 one which can be replayed with the old key. Examples of NO-OP 909 messages are one which contains no Prefix Control Operations, or one 910 with the T flag set. As with any other RR Command, the NO-OP SHOULD 911 be repeated until it is confidently determined that all relevant 912 routers have processed it. 914 Clearly a management station must keep track of the highest sequence 915 number it has used for each authentication key, at least to the 916 extent of being able to generate a larger value when needed. A 917 timestamp may make a good sequence number. 919 8. Security Considerations 921 The Router Renumbering mechanism proposed here is very powerful and 922 prevention of spoofing it is important. Replay of old messages must 923 be prevented, except in the narrow case of idempotent messages which 924 are still valid at the time of replay. We believe the 925 authentication mechanisms included in this specification achieve the 926 necessary protections, so long as authentication keys are not 927 compromised. 929 Authentication keys must be as well protected as is any other access 930 method that allows reconfiguration of a site's routers. 931 Distribution of keys must not expose them or permit alteration, and 932 key lifetimes must be limited. 934 If the messages of several different protocols use the same 935 authentication mechanism then it's possible for one authenticated 936 message body to be grafted onto a different set of headers and cause 937 at least some confusion, and possibly worse. One solution to this 938 problem is never to use the same set of keys for two different 939 protocols. 941 9. Acknowledgments 943 This protocol was designed by Matt Crawford based on an idea of 944 Robert Hinden and Geert Jan de Groot. Several other members of the 945 IPNG Working Group contributed useful comments, in particular 946 members of the DIGITAL UNIX IPv6 team. 948 10. References 950 [AARCH] 951 R. Hinden, S. Deering, "IP Version 6 Addressing Architecture", 952 Currently draft-ietf-ipngwg-addr-arch-v2-07.txt. 954 [HMAC] 955 H. Krawczyk, M. Bellare, R. Canetti, "HMAC: Keyed-Hashing for 956 Message Authentication", RFC 2104. 958 [ICMPV6] 959 A. Conta, S. Deering, "Internet Control Message Protocol 960 (ICMPv6) for the Internet Protocol Version 6 (IPv6)", currently 962 [SECARCH] 963 S. Kent, R. Atkinson, "Security Architecture for the Internet 964 Protocol", currently draft-ietf-ipsec-arch-sec-07.txt. 966 [IPV6] 967 S. Deering, R. Hinden, "Internet Protocol, Version 6 (IPv6) 968 Specification", currently draft-ietf-ipngwg-ipv6-spec-v2-02.txt. 970 [IPV6MIB] 971 D. Haskin, S. Onishi, "Management Information Base for IP 972 Version 6: Textual Conventions and General Group", currently 973 draft-ietf-ipngwg-ipv6-mib-04.txt. 975 [KWORD] 976 S. Bradner, "Key words for use in RFCs to Indicate Requirement 977 Levels," RFC 2119. 979 [MD5] R. Rivest, "The MD5 Message-Digest Algorithm", RFC 1321. 981 [ND] T. Narten, E. Nordmark, W. Simpson, "Neighbor Discovery for 982 IP Version 6 (IPv6)", currently draft-ietf-ipngwg- 983 discovery-v2-03.txt. 985 [SAA] S. Thomson, T. Narten, "IPv6 Stateless Address 986 Autoconfiguration", draft-ietf-ipngwg-addrconf-v2-02.txt. 988 11. Authors' Addresses 990 Matt Crawford Robert M. Hinden 991 Fermilab MS 368 Nokia 992 PO Box 500 232 Java Drive 993 Batavia, IL 60510 Sunnyvale, CA 94089 994 USA USA 996 Phone: +1 630 840 3461 Phone: +1 408 990 2004 998 Email: crawdad@fnal.gov Email: hinden@ipsilon.com