idnits 2.17.1 draft-ietf-ipsecme-g-ikev2-01.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 : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (July 13, 2020) is 1376 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) == Missing Reference: 'CERTREQ' is mentioned on line 2094, but not defined == Missing Reference: 'N' is mentioned on line 892, but not defined == Missing Reference: 'AUTH' is mentioned on line 892, but not defined ** Downref: Normative reference to an Informational RFC: RFC 2627 ** Downref: Normative reference to an Informational RFC: RFC 3740 ** Downref: Normative reference to an Informational RFC: RFC 4046 == Outdated reference: A later version (-12) exists of draft-ietf-ipsecme-ikev2-multiple-ke-00 == Outdated reference: A later version (-09) exists of draft-smyslov-ipsecme-ikev2-qr-alt-01 -- Obsolete informational reference (is this intentional?): RFC 2409 (Obsoleted by RFC 4306) -- Obsolete informational reference (is this intentional?): RFC 3447 (Obsoleted by RFC 8017) -- Obsolete informational reference (is this intentional?): RFC 8229 (Obsoleted by RFC 9329) Summary: 3 errors (**), 0 flaws (~~), 6 warnings (==), 4 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group V. Smyslov 3 Internet-Draft ELVIS-PLUS 4 Obsoletes: 6407 (if approved) B. Weis 5 Intended status: Standards Track Independent 6 Expires: January 14, 2021 July 13, 2020 8 Group Key Management using IKEv2 9 draft-ietf-ipsecme-g-ikev2-01 11 Abstract 13 This document presents an extension to the Internet Key Exchange 14 version 2 (IKEv2) protocol for the purpose of a group key management. 15 The protocol is in conformance with the Multicast Security (MSEC) key 16 management architecture, which contains two components: member 17 registration and group rekeying. Both components require a Group 18 Controller/Key Server to download IPsec group security associations 19 to authorized members of a group. The group members then exchange IP 20 multicast or other group traffic as IPsec packets. This document 21 obsoletes RFC 6407. 23 Status of This Memo 25 This Internet-Draft is submitted in full conformance with the 26 provisions of BCP 78 and BCP 79. 28 Internet-Drafts are working documents of the Internet Engineering 29 Task Force (IETF). Note that other groups may also distribute 30 working documents as Internet-Drafts. The list of current Internet- 31 Drafts is at https://datatracker.ietf.org/drafts/current/. 33 Internet-Drafts are draft documents valid for a maximum of six months 34 and may be updated, replaced, or obsoleted by other documents at any 35 time. It is inappropriate to use Internet-Drafts as reference 36 material or to cite them other than as "work in progress." 38 This Internet-Draft will expire on January 14, 2021. 40 Copyright Notice 42 Copyright (c) 2020 IETF Trust and the persons identified as the 43 document authors. All rights reserved. 45 This document is subject to BCP 78 and the IETF Trust's Legal 46 Provisions Relating to IETF Documents 47 (https://trustee.ietf.org/license-info) in effect on the date of 48 publication of this document. Please review these documents 49 carefully, as they describe your rights and restrictions with respect 50 to this document. Code Components extracted from this document must 51 include Simplified BSD License text as described in Section 4.e of 52 the Trust Legal Provisions and are provided without warranty as 53 described in the Simplified BSD License. 55 Table of Contents 57 1. Introduction and Overview . . . . . . . . . . . . . . . . . . 3 58 1.1. Requirements Language . . . . . . . . . . . . . . . . . . 5 59 1.2. G-IKEv2 Integration into IKEv2 Protocol . . . . . . . . . 5 60 1.2.1. G-IKEv2 Transport and Port . . . . . . . . . . . . . 6 61 1.2.2. IKEv2 Header Initialization . . . . . . . . . . . . . 6 62 1.3. G-IKEv2 Protocol . . . . . . . . . . . . . . . . . . . . 6 63 1.3.1. G-IKEv2 Payloads . . . . . . . . . . . . . . . . . . 6 64 1.4. G-IKEv2 Member Registration and Secure Channel 65 Establishment . . . . . . . . . . . . . . . . . . . . . . 7 66 1.4.1. GSA_AUTH exchange . . . . . . . . . . . . . . . . . . 7 67 1.4.2. GSA_REGISTRATION Exchange . . . . . . . . . . . . . . 9 68 1.4.3. GM Registration Operations . . . . . . . . . . . . . 10 69 1.4.4. GCKS Registration Operations . . . . . . . . . . . . 12 70 1.4.5. Group Maintenance Channel . . . . . . . . . . . . . . 13 71 1.4.6. Counter-based modes of operation . . . . . . . . . . 20 72 2. Group Key Management and Access Control . . . . . . . . . . . 22 73 2.1. Key Wrap Keys . . . . . . . . . . . . . . . . . . . . . . 23 74 2.1.1. Default Key Wrap Key . . . . . . . . . . . . . . . . 23 75 2.2. GCKS Key Management Semantics . . . . . . . . . . . . . . 23 76 2.2.1. Forward Access Control Requirements . . . . . . . . . 24 77 2.3. GM Key Management Semantics . . . . . . . . . . . . . . . 25 78 2.4. Group SA Keys . . . . . . . . . . . . . . . . . . . . . . 26 79 3. Header and Payload Formats . . . . . . . . . . . . . . . . . 27 80 3.1. G-IKEv2 Header . . . . . . . . . . . . . . . . . . . . . 27 81 3.2. Group Identification Payload . . . . . . . . . . . . . . 27 82 3.3. Security Association - GM Supported Transforms Payload . 27 83 3.4. Group Security Association Payload . . . . . . . . . . . 28 84 3.4.1. Group Policies . . . . . . . . . . . . . . . . . . . 28 85 3.4.2. Group Security Association Policy Substructure . . . 29 86 3.4.3. Group Associated Policy Substructure . . . . . . . . 35 87 3.5. Key Download Payload . . . . . . . . . . . . . . . . . . 37 88 3.5.1. Wrapped Key Format . . . . . . . . . . . . . . . . . 37 89 3.5.2. Group Key Packet Substructure . . . . . . . . . . . . 39 90 3.5.3. Member Key Packet Substructure . . . . . . . . . . . 40 91 3.6. Delete Payload . . . . . . . . . . . . . . . . . . . . . 43 92 3.7. Notify Payload . . . . . . . . . . . . . . . . . . . . . 43 93 3.7.1. USE_TRANSPORT_MODE Notification . . . . . . . . . . . 44 94 3.8. Authentication Payload . . . . . . . . . . . . . . . . . 45 95 4. Interaction with other IKEv2 Protocol Extensions . . . . . . 45 96 4.1. Mixing Preshared Keys in IKEv2 for Post-quantum Security 45 98 5. Security Considerations . . . . . . . . . . . . . . . . . . . 47 99 5.1. GSA Registration and Secure Channel . . . . . . . . . . . 47 100 5.2. GSA Maintenance Channel . . . . . . . . . . . . . . . . . 47 101 5.2.1. Authentication/Authorization . . . . . . . . . . . . 47 102 5.2.2. Confidentiality . . . . . . . . . . . . . . . . . . . 47 103 5.2.3. Man-in-the-Middle Attack Protection . . . . . . . . . 48 104 5.2.4. Replay/Reflection Attack Protection . . . . . . . . . 48 105 6. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 48 106 6.1. New Registries . . . . . . . . . . . . . . . . . . . . . 48 107 6.2. Changes in the Existing IKEv2 Registries . . . . . . . . 50 108 7. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 51 109 8. Contributors . . . . . . . . . . . . . . . . . . . . . . . . 51 110 9. References . . . . . . . . . . . . . . . . . . . . . . . . . 52 111 9.1. Normative References . . . . . . . . . . . . . . . . . . 52 112 9.2. Informative References . . . . . . . . . . . . . . . . . 53 113 Appendix A. Use of LKH in G-IKEv2 . . . . . . . . . . . . . . . 56 114 A.1. Notation . . . . . . . . . . . . . . . . . . . . . . . . 56 115 A.2. Group Creation . . . . . . . . . . . . . . . . . . . . . 56 116 A.3. Simple Group SA Rekey . . . . . . . . . . . . . . . . . . 57 117 A.4. Group Member Exclusion . . . . . . . . . . . . . . . . . 58 118 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 59 120 1. Introduction and Overview 122 A group key management protocol provides IPsec keys and policy to a 123 set of IPsec devices which are authorized to communicate using a 124 Group Security Association (GSA) defined in [RFC3740]. The data 125 communications within the group (e.g., IP multicast packets) are 126 protected by a key pushed to the group members (GMs) by the Group 127 Controller/Key Server (GCKS). This document presents an extension to 128 IKEv2 [RFC7296] called G-IKEv2, that allows to perform a group key 129 management. 131 G-IKEv2 conforms to the Multicast Group Security Architecture 132 [RFC3740], Multicast Extensions to the Security Architecture for the 133 Internet Protocol [RFC5374] and the Multicast Security (MSEC) Group 134 Key Management Architecture [RFC4046]. G-IKEv2 replaces GDOI 135 [RFC6407], which defines a similar group key management protocol 136 using IKEv1 [RFC2409] (since deprecated by IKEv2). When G-IKEv2 is 137 used, group key management use cases can benefit from the simplicity, 138 increased robustness and cryptographic improvements of IKEv2 (see 139 Appendix A of [RFC7296]. 141 A GM begins a "registration" exchange when it first joins the group. 142 With G-IKEv2, the GCKS authenticates and authorizes GMs, then pushes 143 policy and keys used by the group to the GM. G-IKEv2 includes two 144 "registration" exchanges. The first is the GSA_AUTH exchange ( 145 Section 1.4.1), which follows an IKE_SA_INIT exchange. The second is 146 the GSA_REGISTRATION exchange (Section 1.4.2), which a GM can use 147 within an established IKE SA. Group rekeys are accomplished using 148 either the GSA_REKEY pseudo-exchange (a single message distributed to 149 all GMs, usually as a multicast message), or as a GSA_INBAND_REKEY 150 exchange delivered individually to group members using existing IKE 151 SAs). 153 Large and small groups may use different sets of these protocols. 154 When a large group of devices are communicating, the GCKS is likely 155 to use the GSA_REKEY message for efficiency. This is shown in 156 Figure 1. (Note: For clarity, IKE_SA_INIT is omitted from the 157 figure.) 159 +--------+ 160 +------------->| GCKS |<-------------+ 161 | +--------+ | 162 | | ^ | 163 | | | | 164 | | GSA_AUTH | 165 | | or | 166 | | GSA_REGISTRATION | 167 | | | | 168 GSA_AUTH | | GSA_AUTH 169 or GSA_REKEY | or 170 GSA_REGISTRATION | | GSA_REGISTRATION 171 | | | | 172 | +------------+-----------------+ | 173 | | | | | | 174 v v v v v v 175 +-------+ +--------+ +-------+ 176 | GM | ... | GM | ... | GM | 177 +-------+ +--------+ +-------+ 178 ^ ^ ^ 179 | | | 180 +-------ESP-------+-------ESP------+ 182 Figure 1: G-IKEv2 used in large groups 184 Alternatively, a small group may simply use the GSA_AUTH as a 185 registration protocol, where the GCKS issues rekeys using the 186 GSA_INBAND_REKEY within the same IKEv2 SA. The GCKS is also likely 187 to be a GM in a small group (as shown in Figure 2.) 188 GSA_AUTH, GSA_INBAND_REKEY 189 +-----------------------------------------------+ 190 | | 191 | GSA_AUTH, GSA_INBAND_REKEY | 192 | +-----------------------------+ | 193 | | | | 194 | | GSA_AUTH, GSA_INBAND_REKEY | | 195 | | +--------+ | | 196 v v v v v v 197 +---------+ +----+ +----+ +----+ 198 | GCKS/GM | | GM | | GM | | GM | 199 +---------+ +----+ +----+ +----+ 200 ^ ^ ^ ^ 201 | | | | 202 +----ESP-----+------ESP-------+-----ESP-----+ 204 Figure 2: G-IKEv2 used in small groups 206 IKEv2 message semantics are preserved in that all communications 207 consists of message request-response pairs. The exception to this 208 rule is the GSA_REKEY pseudo-exchange, which is a single message 209 delivering group updates to the GMs. 211 1.1. Requirements Language 213 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 214 "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and 215 "OPTIONAL" in this document are to be interpreted as described in BCP 216 14 [RFC2119] [RFC8174] when, and only when, they appear in all 217 capitals, as shown here. 219 1.2. G-IKEv2 Integration into IKEv2 Protocol 221 G-IKEv2 uses the security mechanisms of IKEv2 (peer authentication, 222 confidentiality, message integrity) to ensure that only authenticated 223 devices have access to the group policy and keys. The G-IKEv2 224 exchange further provides group authorization, and secure policy and 225 key download from the GCKS to GMs. Some IKEv2 extensions require 226 special handling if used with G-IKEv2. See Section 4 for more 227 details. 229 It is assumed that readers are familiar with the IKEv2 protocol, so 230 this document skips many details that are described in [RFC7296]. 232 1.2.1. G-IKEv2 Transport and Port 234 G-IKEv2 SHOULD use UDP port 848, the same as GDOI [RFC6407], because 235 they serve a similar function. They can use the same ports, just as 236 IKEv1 and IKEv2 can share port 500. The version number in the IKE 237 header distinguishes the G-IKEv2 protocol from GDOI protocol 238 [RFC6407]. G-IKEv2 MAY also use the IKEv2 ports (500, 4500), which 239 would provide a better integration with IKEv2. G-IKEv2 MAY also use 240 TCP transport for registration (unicast) IKE SA, as defined in 241 [RFC8229]. 243 1.2.2. IKEv2 Header Initialization 245 The Major Version is (2) and Minor Version is (0) according to IKEv2 246 [RFC7296], and maintained in this document. The G-IKEv2 IKE_SA_INIT, 247 GSA_AUTH, GSA_REGISTRATION and GSA_INBAND_REKEY use the IKE SPI 248 according to IKEv2 [RFC7296], section 2.6. 250 1.3. G-IKEv2 Protocol 252 1.3.1. G-IKEv2 Payloads 254 In the following descriptions, the payloads contained in the G-IKEv2 255 messages are indicated by names as listed below. 257 Notation Payload 258 ------------------------------------------------------------ 259 AUTH Authentication 260 CERT Certificate 261 CERTREQ Certificate Request 262 D Delete 263 GSA Group Security Association 264 HDR IKEv2 Header 265 IDg Identification - Group 266 IDi Identification - Initiator 267 IDr Identification - Responder 268 KD Key Download 269 KE Key Exchange 270 Ni, Nr Nonce 271 N Notify 272 SA Security Association 273 SAg Security Association - GM Supported Transforms 275 Payloads defined as part of other IKEv2 extensions MAY also be 276 included in these messages. Payloads that may optionally appear in 277 G-IKEv2 messages will be shown in brackets, such as [CERTREQ]. 279 G-IKEv2 defines several new payloads not used in IKEv2: 281 o IDg (Group ID) - The GM requests the GCKS for membership into the 282 group by sending its IDg payload. 284 o GSA (Group Security Association) - The GCKS sends the group policy 285 to the GM using this payload. 287 o KD (Key Download) - The GCKS sends the keys and the security 288 parameters to the GMs using the KD payload. 290 o SAg (Security Association - GM Supported Transforms) - the GM 291 sends supported transforms, so that GCKS may select a policy 292 appropriate for all members of the group. 294 The details of the contents of each payload are described in 295 Section 3. 297 1.4. G-IKEv2 Member Registration and Secure Channel Establishment 299 The registration protocol consists of a minimum of two messages 300 exchanges, IKE_SA_INIT and GSA_AUTH; member registration may have a 301 few more messages exchanged if the EAP method, cookie challenge (for 302 DoS protection) or negotiation of Diffie-Hellman group is included. 303 Each exchange consists of request/response pairs. The first exchange 304 IKE_SA_INIT is defined in IKEv2 [RFC7296]. This exchange negotiates 305 cryptographic algorithms, exchanges nonces and does a Diffie-Hellman 306 exchange between the group member (GM) and the Group Controller/Key 307 Server (GCKS). 309 The second exchange GSA_AUTH authenticates the previous messages, 310 exchanges identities and certificates. These messages are encrypted 311 and integrity protected with keys established through the IKE_SA_INIT 312 exchange, so the identities are hidden from eavesdroppers and all 313 fields in all the messages are authenticated. The GCKS SHOULD 314 authorize group members to be allowed into the group as part of the 315 GSA_AUTH exchange. Once the GCKS accepts a group member to join a 316 group it will download the data security keys (TEKs) and/or group key 317 encrypting key (KEK) or KEK array as part of the GSA_AUTH response 318 message. 320 1.4.1. GSA_AUTH exchange 322 After the group member and GCKS use the IKE_SA_INIT exchange to 323 negotiate cryptographic algorithms, exchange nonces, and perform a 324 Diffie-Hellman exchange as defined in IKEv2 [RFC7296], the GSA_AUTH 325 exchange MUST complete before any other exchanges can be done. The 326 security properties of the GSA_AUTH exchange are the same as the 327 properties of the IKE_AUTH exchange. It is used to authenticate the 328 IKE_SA_INIT messages, exchange identities and certificates. G-IKEv2 329 also uses this exchange for group member registration and 330 authorization. Even though the IKE_AUTH does contain the SA2, TSi, 331 and TSr payload the GSA_AUTH does not. They are not needed because 332 policy is not negotiated between the group member and the GCKS, but 333 instead downloaded from the GCKS to the group member. 335 Initiator (Member) Responder (GCKS) 336 -------------------- ------------------ 337 HDR, SK{IDi, [CERT,] [CERTREQ,] [IDr,] 338 AUTH, IDg, [SAg,] [N]} --> 340 Figure 3: GSA_AUTH Request 342 After the IKE_SA_INIT exchange completes, the group member initiates 343 a GSA_AUTH request to join a group indicated by the IDg payload. The 344 GM MAY include an SAg payload declaring which Transforms it is 345 willing to accept. A GM that intends to emit data packets SHOULD 346 include a Notify payload status type of SENDER, which enables the 347 GCKS to provide any additional policy necessary by group senders. 349 Initiator (Member) Responder (GCKS) 350 -------------------- ------------------ 351 <-- HDR, SK{IDr, [CERT,] 352 AUTH, [GSA, KD,] [N,] [D]} 354 Figure 4: GSA_AUTH Normal Response 356 The GCKS responds with IDr, optional CERT, and AUTH material as if it 357 were an IKE_AUTH. It also informs the group member of the 358 cryptographic policies of the group in the GSA payload and the key 359 material in the KD payload. The GCKS can also include a Delete (D) 360 payload instructing the group member to delete existing SAs it might 361 have as the result of a previous group member registration. Note, 362 that since the GCKS generally doesn't know which SAs the GM has, the 363 SPI field in the Delete payload(s) SHOULD be set to zero in this 364 case. (See more discussion on the Delete payload in Section 3.6.) 366 In addition to the IKEv2 error handling, the GCKS can reject the 367 registration request when the IDg is invalid or authorization fails, 368 etc. In these cases, see Section 3.7, the GSA_AUTH response will not 369 include the GSA and KD, but will include a Notify payload indicating 370 errors. If the group member included an SAg payload, and the GCKS 371 chooses to evaluate it, and it detects that that group member cannot 372 support the security policy defined for the group, then the GCKS 373 SHOULD return a NO_PROPOSAL_CHOSEN. Other types of notifications can 374 be AUTHORIZATION_FAILED or REGISTRATION_FAILED. 376 Initiator (Member) Responder (GCKS) 377 -------------------- ------------------ 378 <-- HDR, SK{IDr, [CERT,] AUTH, N} 380 Figure 5: GSA_AUTH Error Response 382 If the group member finds the policy sent by the GCKS is 383 unacceptable, the member SHOULD initiate GSA_REGISTRATION exchange 384 sending IDg and the Notify NO_PROPOSAL_CHOSEN (see Section 1.4.2)). 386 1.4.2. GSA_REGISTRATION Exchange 388 When a secure channel is already established between a GM and the 389 GCKS, the GM registration for a group can reuse the established 390 secure channel. In this scenario the GM will use the 391 GSA_REGISTRATION exchange. Payloads in the exchange are generated 392 and processed as defined in Section 1.4.1. 394 Initiator (Member) Responder (GCKS) 395 -------------------- ------------------ 396 HDR, SK{IDg, [SAg,][N ]} --> 397 <-- HDR, SK{GSA,] [N,] [D]} 399 Figure 6: GSA_REGISTRATION Normal Exchange 401 As with GSA_AUTH exchange, the GCKS can reject the registration 402 request when the IDg is invalid or authorization fails, or GM cannot 403 support the security policy defined for the group (which can be 404 concluded by GCKS by evaluation of SAg payload). In this case the 405 GCKS returns an appropriate error notification as described in 406 Section 1.4.1. 408 Initiator (Member) Responder (GCKS) 409 -------------------- ------------------ 410 HDR, SK{IDg, [SAg,] [N]} --> 411 <-- HDR, SK{N} 413 Figure 7: GSA_REGISTRATION Error Exchange 415 This exchange can also be used if the group member finds the policy 416 sent by the GCKS is unacceptable or for some reason wants to 417 unregister itself from the group. The group member SHOULD notify the 418 GCKS by sending IDg and the Notify type NO_PROPOSAL_CHOSEN or 419 REGISTRATION_FAILED, as shown below. The GCKS MUST unregister the 420 group member. 422 Initiator (Member) Responder (GCKS) 423 -------------------- ------------------ 424 HDR, SK{IDg, N} --> 425 <-- HDR, SK{} 427 Figure 8: GM Reporting Errors in GSA_REGISTRATION Exchange 429 1.4.3. GM Registration Operations 431 A G-IKEv2 Initiator (GM) requesting registration contacts the GCKS 432 using the IKE_SA_INIT exchange and receives the response from the 433 GCKS. This exchange is unchanged from the IKE_SA_INIT in IKEv2 434 protocol. 436 Upon completion of parsing and verifying the IKE_SA_INIT response, 437 the GM sends the GSA_AUTH message with the IKEv2 payloads from 438 IKE_AUTH (without the SAi2, TSi and TSr payloads) along with the 439 Group ID informing the GCKS of the group the initiator wishes to 440 join. An initiator intending to emit data traffic SHOULD send a 441 SENDER Notify payload status. The SENDER not only signifies that it 442 is a sender, but provides the initiator the ability to request 443 Sender-ID values, in case the data security SA supports a counter 444 mode cipher. Section 1.4.6) includes guidance on requesting Sender- 445 ID values. 447 A GM may be limited in the types of Transforms that it is able or 448 willing to use, and may find it useful to inform the GCKS which 449 Transforms it is willing to accept for different security protocols. 450 Proposals for Rekey SA (with protocol GIKE_REKEY) and for data 451 security (AH and/or ESP) SAs may be included into SAg. Each Proposal 452 contains a list of Transforms that the GM is able to support for that 453 protocol. Valid transform types depend on the protocol and are 454 defined in Figure 15. Other transform types SHOULD NOT be included. 455 The SPI length of each Proposal in an SAg is set to zero, and thus 456 the SPI field is empty. The GCKS MUST ignore SPI field in the SAg 457 payload. 459 Generally, a single Proposal of each type will suffice, because the 460 group member is not negotiating Transform sets, simply alerting the 461 GCKS to restrictions it may have. In particular, the restriction 462 from Section 3.3 of [RFC7296] that AEAD and non-AEAD transforms must 463 not be combined in a single proposal doesn't hold when the SAg 464 payload is being formed. However if the GM has restrictions on 465 combination of algorithms, this can be expressed by sending several 466 proposals. 468 Although the SAg payload is optional, it is RECOMMENDED for the GM to 469 include this payload into the GSA_AUTH request to allow the GCKS to 470 select an appropriate policy. 472 A GM may also indicate the support for IPcomp by inclusion one or 473 more the IPCOMP_SUPPORTED notifications along with the SAg payload. 474 The CPI in these notifications is set to zero and MUST be ignored by 475 the GCKS. 477 Upon receiving the GSA_AUTH response, the initiator parses the 478 response from the GCKS authenticating the exchange using the IKEv2 479 method, then processes the GSA and KD. 481 The GSA payload contains the security policy and cryptographic 482 protocols used by the group. This policy describes the Rekey SA 483 (KEK), Data-security SAs (TEK), and other group policy (GAP). If the 484 policy in the GSA payload is not acceptable to the GM, it SHOULD 485 notify the GCKS by initiating a GSA_REGISTRATION exchange with a 486 NO_PROPOSAL_CHOSEN Notify payload (see Section 1.4.2). Note, that 487 this should normally not happen if the GM includes SAg payload in the 488 GSA_AUTH request and the GCKS takes it into account. Finally the KD 489 are parsed providing the keying material for the TEK and/or KEK. The 490 GM interprets the KD key packets, where each key packet includes the 491 keying material for SAs distributed in the GSA payload. Keying 492 material is matched by comparing the SPIs in the key packets to SPIs 493 previously included in the GSA payloads. Once TEK keys and policy 494 are matched, the GM provides them to the data security subsystem, and 495 it is ready to send or receive packets matching the TEK policy. 497 The GSA KEK policy MUST include the attribute GSA_INITIAL_MESSAGE_ID 498 with a first Message ID the GM should expect to receive if it is non- 499 zero. The value of the attribute MUST be checked by a GM against any 500 previously received Message ID for this group. If it is less than 501 the previously received number, it should be considered stale and 502 ignored. This could happen if two GSA_AUTH exchanges happened in 503 parallel, and the Message ID changed. This attribute is used by the 504 GM to prevent GSA_REKEY message replay attacks. The first GSA_REKEY 505 message that the GM receives from the GCKS must have a Message ID 506 greater or equal to the Message ID received in the 507 GSA_INITIAL_MESSAGE_ID attribute. 509 Once a GM has received GSA_REKEY policy during a registration the IKE 510 SA may be closed. However, the GM SHOULD NOT close IKE SA, it is the 511 GCKS who makes the decision whether to close or keep it, because 512 depending on the policy the IKE SA may be used for inband rekeying 513 for small groups. 515 1.4.4. GCKS Registration Operations 517 A G-IKEv2 GCKS passively listens for incoming requests from group 518 members. When the GCKS receives an IKE_SA_INIT request, it selects 519 an IKE proposal and generates a nonce and DH to include them in the 520 IKE_SA_INIT response. 522 Upon receiving the GSA_AUTH request, the GCKS authenticates the group 523 member using the same procedures as in the IKEv2 IKE_AUTH. The GCKS 524 then authorizes the group member according to group policy before 525 preparing to send the GSA_AUTH response. If the GCKS fails to 526 authorize the GM, it will respond with an AUTHORIZATION_FAILED notify 527 message. 529 The GSA_AUTH response will include the group policy in the GSA 530 payload and keys in the KD payload. If the GCKS policy includes a 531 group rekey option, this policy is constructed in the GSA KEK and the 532 key is constructed in the KD KEK. The GSA KEK MUST include the 533 GSA_INITIAL_MESSAGE_ID attribute, specifying the starting Message ID 534 the GCKS will use when sending the GSA_REKEY message to the group 535 member if this Message ID is non-zero. This Message ID is used to 536 prevent GSA_REKEY message replay attacks and will be increased each 537 time a GSA_REKEY message is sent to the group. The GCKS data traffic 538 policy is included in the GSA TEK and keys are included in the KD 539 TEK. The GAP MAY also be included to provide the ATD and/or DTD 540 (Section 3.4.3.1) specifying activation and deactivation delays for 541 SAs generated from the TEKs. If the group member has indicated that 542 it is a sender of data traffic and one or more Data Security SAs 543 distributed in the GSA payload included a counter mode of operation, 544 the GCKS responds with one or more SIDs (see Section 1.4.6). 546 If the GCKS receives a GSA_REGISTRATION exchange with a request to 547 register a GM to a group, the GCKS will need to authorize the GM with 548 the new group (IDg) and respond with the corresponding group policy 549 and keys. If the GCKS fails to authorize the GM, it will respond 550 with the AUTHORIZATION_FAILED notification. 552 If a group member includes an SAg in its GSA_AUTH or GSA_REGISTRATION 553 request, the GCKS MAY evaluate it according to an implementation 554 specific policy. 556 o The GCKS could evaluate the list of Transforms and compare it to 557 its current policy for the group. If the group member did not 558 include all of the ESP or AH Transforms in its current policy, 559 then it could return a NO_PROPOSAL_CHOSEN Notification. 561 o The GCKS could store the list of Transforms, with the goal of 562 migrating the group policy to a different Transform when all of 563 the group members indicate that they can support that Transform. 565 o The GCKS could store the list of Transforms and adjust the current 566 group policy based on the capabilities of the devices as long as 567 they fall within the acceptable security policy of the GCKS. 569 Depending on its policy, the GCKS may have no need for the IKE SA 570 (e.g., it does not plan to initiate an GSA_INBAND_REKEY exchange). 571 If the GM does not initiate another registration exchange or Notify 572 (e.g., NO_PROPOSAL_CHOSEN), and also does not close the IKE SA and 573 the GCKS is not intended to use the SA, then after a short period of 574 time the GCKS SHOULD close the IKEv2 SA. The delay before closing 575 provides for receipt of a GM's error notification in the event of 576 packet loss. 578 1.4.5. Group Maintenance Channel 580 The GCKS is responsible for rekeying the secure group per the group 581 policy. Rekeying is an operation whereby the GCKS provides 582 replacement TEKs and KEK, deleting TEKs, and/or excluding group 583 members. The GCKS may initiate a rekey message if group membership 584 and/or policy has changed, or if the keys are about to expire. Two 585 forms of group maintenance channels are provided in G-IKEv2 to push 586 new policy to group members. 588 GSA_REKEY The GSA_REKEY is a pseudo-exchange initiated by the GCKS, 589 where the rekey policy is usually delivered to group members using 590 IP multicast as a transport. This is not a real IKEv2 exchange, 591 since no response messages are sent. This method is valuable for 592 large and dynamic groups, and where policy may change frequently 593 and a scalable rekeying method is required. When the GSA_REKEY is 594 used, the IKEv2 SA protecting the member registration exchanges is 595 usually terminated, and group members await policy changes from 596 the GCKS via the GSA_REKEY messages. 598 GSA_INBAND_REKEY The GSA_INBAND_REKEY is a normal IKEv2 exchange 599 using the IKEv2 SA that was setup to protecting the member 600 registration exchange. This exchange allows the GCKS to rekey 601 without using an independent GSA_REKEY pseudo-exchange. The 602 GSA_INBAND_REKEY exchange provides a reliable policy delivery and 603 is useful when G-IKEv2 is used with a small group of cooperating 604 devices. 606 Depending on the policy the GCKS may combine these two methods. For 607 example, it may use the GSA_INBAND_REKEY to deliver key to the GMs in 608 the group acting as senders (as this would provide reliable keys 609 delivery), and the GSA_REKEY for the rest GMs. 611 1.4.5.1. GSA_REKEY 613 The GCKS initiates the G-IKEv2 Rekey securely, usually using IP 614 multicast. Since this rekey does not require a response and it sends 615 to multiple GMs, G-IKEv2 rekeying MUST NOT support IKE SA windowing. 616 The GCKS rekey message replaces the rekey GSA KEK or KEK array, and/ 617 or creates a new Data-Security GSA TEK. The SID Download attribute 618 in the Key Download payload (defined in Section 3.5.3.2) MUST NOT be 619 part of the Rekey Exchange as this is sender specific information and 620 the Rekey Exchange is group specific. The GCKS initiates the 621 GSA_REKEY pseudo-exchange as following: 623 Members (Responder) GCKS (Initiator) 624 -------------------- ------------------ 625 <-- HDR, SK{GSA, KD, [N,] [D,] [AUTH]} 627 Figure 9: GSA_REKEY Pseudo-Exchange 629 HDR is defined in Section 3.1. The Message ID in this message will 630 start with the value the GCKS sent to the group members in the KEK 631 attribute GSA_INITIAL_MESSAGE_ID or from zero if this attribute 632 wasn't sent. The Message ID will be incremented each time a new 633 GSA_REKEY message is sent to the group members. 635 The GSA payload contains the current rekey and data security SAs. 636 The GSA may contain a new rekey SA and/or a new data security SA 637 Section 3.4. 639 The KD payload contains the keys for the policy included in the GSA. 640 If the data security SA is being refreshed in this rekey message, the 641 IPsec keys are updated in the KD, and/or if the rekey SA is being 642 refreshed in this rekey message, the rekey Key or the LKH KEK array 643 is updated in the KD payload. 645 A Delete payload MAY be included to instruct the GM to delete 646 existing SAs. 648 The AUTH payload MUST be included to authenticate the GSA_REKEY 649 message if the authentication method is based on public key 650 signatures or a dedicated shared secret and MUST NOT be included if 651 authentication is implicit. In a latter case, the fact that a GM can 652 decrypt the GSA_REKEY message and verify its ICV proves that the 653 sender of this message knows the current KEK, thus authenticating 654 that the sender is a member of the group. Shared secret and implicit 655 authentication don't provide source origin authentication. For this 656 reason using them as authentication methods for GSA_REKEY is NOT 657 RECOMMENDED unless source origin authentication is not required (for 658 example, in a small group of highly trusted GMs). If AUTH payload is 659 included then the Auth Method field MUST NOT be NULL Authentication. 661 During group member registration, the GCKS sends the authentication 662 key in the GSA KEK payload, AUTH_KEY attribute, which the group 663 member uses to authenticate the key server. Before the current 664 Authentication Key expires, the GCKS will send a new AUTH_KEY to the 665 group members in a GSA_REKEY message. The AUTH key that is used in 666 the rekey message may be not the same as the authentication key used 667 in GSA_AUTH. If implicit authentication is used, then AUTH_KEY MUST 668 NOT be sent to GMs. 670 1.4.5.1.1. GSA_REKEY Messages Authentication 672 The content of the AUTH payload depends on the authentication method 673 and is either a digital signature or a result of prf applied to the 674 content of the not yet encrypted GSA_REKEY message. 676 The authentication algorithm (prf or digital signing) is applied to 677 the concatenation of two chunks: A and P. The chunk A lasts from the 678 first octet of the G-IKEv2 Header (not including prepended four 679 octets of zeros, if port 4500 is used) to the last octet of the 680 Encrypted Payload header. The chunk P consists of the not yet 681 encrypted content of the Encrypted payload, excluding the 682 Initialization Vector, the Padding, the Pad Length and the Integrity 683 Checksum Data fields (see 3.14 of [RFC7296] for description of the 684 Encrypted payload). In other words, the P chunk is the inner 685 payloads of the Encrypted payload in plaintext form. These inner 686 payloads must be fully formed and ready for encryption except for the 687 AUTH payload. Figure 10 illustrates the layout of the P and A chunks 688 in the GSA_REKEY message. 690 The AUTH payload must have correct values in the Payload Header, the 691 Auth Method and the RESERVED fields. The Authentication Data field 692 is zeroed, but if Digital Signature authentication method is in use, 693 then the ASN.1 Length and the AlgorithmIdentifier fields must be 694 properly filled in, see [RFC7427]. 696 For the purpose of the AUTH payload calculation the Length field in 697 the IKE header and the Payload Length field in the Encrypted Payload 698 header are adjusted so that they don't count the lengths of 699 Initialization Vector, Integrity Checksum Data and Padding (along 700 with Pad Length field). In other words, the Length field in the IKE 701 header (denoted as AdjustedLen in Figure 10 ) is set to the sum of 702 the lengths of A and P, and the Payload Length field in the Encrypted 703 Payload header (denoted as AdjustedPldLen in Figure 10) is set to the 704 length of P plus the size of the Payload header (four octets). 706 DataToAuthenticate = A | P 707 GsaRekeyMessage = GenIKEHDR | EncPayload 708 GenIKEHDR = [ four octets 0 if using port 4500 ] | AdjustedIKEHDR 709 AdjustedIKEHDR = SPIi | SPIr | . . . | AdjustedLen 710 EncPayload = AdjustedEncPldHdr | IV | InnerPlds | Pad | PadLen | ICV 711 AdjustedEncPldHdr = NextPld | C | RESERVED | AdjustedPldLen 712 A = AdjustedIKEHDR | AdjustedEncPldHdr 713 P = InnerPlds 715 1 2 3 716 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 717 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ ^ ^ 718 | G-IKEv2 SA Initiator's SPI | | | 719 | | | | 720 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ I | 721 | G-IKEv2 SA Responder's SPI | K | 722 | | E | 723 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 724 | Next Payload | MjVer | MnVer | Exchange Type | Flags | H A 725 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ d | 726 | Message ID | r | 727 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | | 728 | AdjustedLeng | | | 729 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ v | 730 | Next Payload |C| RESERVED | AdjustedPldLen | | | 731 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ E v 732 | Initialization Vector | n 733 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ c ^ 734 | | r | 735 ~ Inner payloads (not yet encrypted) ~ P 736 | | P | 737 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ l v 738 | Padding (0-255 octets) | Pad Length | d 739 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 740 ~ Integrity Checksum Data ~ | 741 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ v 743 Figure 10: Data to Authenticate in the GSA_REKEY Messages 745 The authentication data is calculated using the authentication 746 algorithm from the Authentication Method transform and the key 747 provided before in the AUTH_KEY attribute. Depending on the 748 authentication method the authentication data is either a digital 749 signature or a result of applying prf from the Pseudorandom Function 750 transform. The calculated authentication data is placed into the 751 AUTH payload, the Length fields in the IKE Header and the Encryption 752 Payload header are restored, the content of the Encrypted payload is 753 encrypted and the ICV is computed using the current SKe/SKa keys. 755 The calculation of authentication data MUST be applied to whole 756 messages only, before possible IKE Fragmentation. If the message was 757 received in fragmented form, it should be reconstructed before 758 verifying its authenticity as if it were received unfragmented. The 759 RESERVED field in the reconstructed Encrypted Payload header MUST be 760 set to the value of the RESERVED field in the Encrypted Fragment 761 payload header from the first fragment (that with Fragment Number 762 equal to 1). 764 1.4.5.1.2. GSA_REKEY GCKS Operations 766 The GCKS builds the rekey message with a Message ID value that is one 767 greater than the value included in the previous rekey. If the 768 message is using a new KEK attribute, the Message ID is reset to 0 in 769 this message. The GSA, KD, N and D payloads follow with the same 770 characteristics as in the GSA Registration exchange. 772 The AUTH payload (if present) is created as defined in 773 Section 1.4.5.1.1. 775 Because GSA_REKEY messages are not acknowledged and could be 776 discarded by the network, one or more GMs may not receive the 777 message. To mitigate such lost messages, during a rekey event the 778 GCKS may transmit several GSA_REKEY messages with the new policy. 779 The retransmitted messages MUST be bitwise identical and SHOULD be 780 sent within a short time interval (a few seconds) to ensure that 781 time-to-live would not be substantially skewed for the GMs that would 782 receive different copies of the messages. 784 GCKS may also include one or several GSA_NEXT_SPI attributes 785 specifying SPIs for the prospected rekeys, so that listening GMs are 786 able to detect lost rekey messages and recover from this situation. 787 See Sections Section 3.4.2.2.3 for more detail. 789 1.4.5.1.3. GSA_REKEY GM Operations 791 When a group member receives the Rekey Message from the GCKS it 792 decrypts the message using the current KEK, validates its 793 authenticity using the key retrieved in a previous G-IKEv2 exchange 794 if AUTH payload is present, verifies the Message ID, and processes 795 the GSA and KD payloads. The group member then downloads the new 796 data security SA and/or new rekey SA. The parsing of the payloads is 797 identical to the parsing done in the registration exchange. 799 Replay protection is achieved by a group member rejecting a GSA_REKEY 800 message which has a Message ID smaller than the current Message ID 801 that the GM is expecting. The GM expects the Message ID in the first 802 GSA_REKEY message it receives to be equal or greater than the Message 803 ID it receives in the GSA_INITIAL_MESSAGE_ID attribute. Note, that 804 if no this attribute was received for the Rekey SA, the GM MUST 805 assume zero as the first expected Message ID. The GM expects the 806 Message ID in subsequent GSA_REKEY messages to be greater than the 807 last valid GSA_REKEY message ID it received. 809 If the GSA payload includes a Data-Security SA including a counter- 810 modes of operation and the receiving group member is a sender for 811 that SA, the group member uses its current SID value with the Data- 812 Security SAs to create counter-mode nonces. If it is a sender and 813 does not hold a current SID value, it MUST NOT install the Data- 814 Security SAs. It MAY initiate a GSA_REGISTRATION exchange to the 815 GCKS in order to obtain an SID value (along with current group 816 policy). 818 Once a new Rekey SA is installed as a result of GSA_REKEY message, 819 the current Rekey SA (over which the message was received) MUST be 820 silently deleted after waiting DEACTIVATION_TIME_DELAY interval 821 regardless of its expiration time. If the GSA TEK payload includes 822 GSA_REKEY_SPI attribute then after installing a new Data-Security SA 823 the old one, identified by the SPI in this attribute, MUST be 824 silently deleted after waiting DEACTIVATION_TIME_DELAY interval 825 regardless of its expiration time. 827 If a Data-Security SA is not rekeyed yet and is about to expire (a 828 "soft lifetime" expiration is described in Section 4.4.2.1 of 829 [RFC4301]), the GM SHOULD initiate a registration to the GCKS. This 830 registration serves as a request for current SAs, and will result in 831 the download of replacement SAs, assuming the GCKS policy has created 832 them. A GM SHOULD also initiate a registration request if a Rekey SA 833 is about to expire and not yet replaced with a new one. 835 1.4.5.1.4. IKE Fragmentation 837 IKE fragmentation [RFC7383] can be used to perform fragmentation of 838 large GSA_REKEY messages, however when the GSA_REKEY message is 839 emitted as an IP multicast packet there is a lack of response from 840 the GMs. This has the following implications. 842 o Policy regarding the use of IKE fragmentation is implicit. If a 843 GCKS detects that all GMs have negotiated support of IKE 844 fragmentation in IKE_SA_INIT, then it MAY use IKE fragmentation on 845 large GSA_REKEY messages. 847 o The GCKS must always use IKE fragmentation based on a known 848 fragmentation threshold (unspecified in this memo), as there is no 849 way to check if fragmentation is needed by first sending 850 unfragmented messages and waiting for response. 852 o PMTU probing cannot be performed due to lack of GSA_REKEY response 853 message. 855 1.4.5.2. GSA_INBAND_REKEY Exchange 857 When the IKEv2 SA protecting the member registration exchange is 858 maintained while group member participates in the group, the GCKS can 859 use the GSA_INBAND_REKEY exchange to individually provide policy 860 updates to the group member. 862 Member (Responder) GCKS (Initiator) 863 -------------------- ------------------ 864 <-- HDR, SK{GSA, KD, [N,] [D]} 865 HDR, SK{} --> 867 Figure 11: GSA_INBAND_REKEY Exchange 869 Because this is a normal IKEv2 exchange, the HDR is treated as 870 defined in [RFC7296]. 872 1.4.5.2.1. GSA_INBAND_REKEY GCKS Operations 874 The GSA, KD, N and D payloads are built in the same manner as in a 875 registration exchange. 877 1.4.5.2.2. GSA_INBAND_REKEY GM Operations 879 The GM processes the GSA, KD, N and D payloads in the same manner as 880 if they were received in a registration exchange. 882 1.4.5.3. Deletion of SAs 884 There are occasions when the GCKS may want to signal to group members 885 to delete policy at the end of a broadcast, or if group policy has 886 changed. Deletion of keys MAY be accomplished by sending the G-IKEv2 887 Delete Payload [RFC7296], section 3.11 as part of the GSA_REKEY 888 pseudo-exchange as shown below. 890 Members (Responder) GCKS (Initiator) 891 -------------------- ------------------ 892 <-- HDR, SK{[GSA,] [KD,], [N] [D,] [AUTH]} 894 Figure 12: SA Deletion in GSA_REKEY 896 The GSA MAY specify the remaining active time of the remaining policy 897 by using the DTD attribute in the GSA GAP. If a GCKS has no further 898 SAs to send to group members, the GSA and KD payloads MUST be omitted 899 from the message. There may be circumstances where the GCKS may want 900 to start over with a clean state. If the administrator is no longer 901 confident in the integrity of the group, the GCKS can signal deletion 902 of all the policies of a particular TEK protocol by sending a TEK 903 with a SPI value equal to zero in the delete payload. For example, 904 if the GCKS wishes to remove all the KEKs and all the TEKs in the 905 group, the GCKS SHOULD send a Delete payload with a SPI of zero and 906 Protocol ID of AH or ESP, followed by another Delete payload with a 907 SPI of zero and Protocol ID of GIKE_REKEY, indicating that the KEK SA 908 should be deleted. 910 1.4.6. Counter-based modes of operation 912 Several new counter-based modes of operation have been specified for 913 ESP (e.g., AES-CTR [RFC3686], AES-GCM [RFC4106], AES-CCM [RFC4309], 914 ChaCha20-Poly1305 [RFC7634], AES-GMAC [RFC4543]) and AH (e.g., AES- 915 GMAC [RFC4543]). These counter-based modes require that no two 916 senders in the group ever send a packet with the same Initialization 917 Vector (IV) using the same cipher key and mode. This requirement is 918 met in G-IKEv2 when the following requirements are met: 920 o The GCKS distributes a unique key for each Data-Security SA. 922 o The GCKS uses the method described in [RFC6054], which assigns 923 each sender a portion of the IV space by provisioning each sender 924 with one or more unique SID values. 926 1.4.6.1. Allocation of SIDs 928 When at least one Data-Security SA included in the group policy 929 includes a counter-based mode of operation, the GCKS automatically 930 allocates and distributes one SID to each group member acting in the 931 role of sender on the Data-Security SA. The SID value is used 932 exclusively by the group member to which it was allocated. The group 933 member uses the same SID for each Data-Security SA specifying the use 934 of a counter-based mode of operation. A GCKS MUST distribute unique 935 keys for each Data-Security SA including a counter-based mode of 936 operation in order to maintain unique key and nonce usage. 938 During registration, the group member can choose to request one or 939 more SID values. Requesting a value of 1 is not necessary since the 940 GCKS will automatically allocate exactly one to the group member. A 941 group member MUST request as many SIDs matching the number of 942 encryption modules in which it will be installing the TEKs in the 943 outbound direction. Alternatively, a group member MAY request more 944 than one SID and use them serially. This could be useful when it is 945 anticipated that the group member will exhaust their range of Data- 946 Security SA nonces using a single SID too quickly (e.g., before the 947 time-based policy in the TEK expires). 949 When the group policy includes a counter-based mode of operation, a 950 GCKS SHOULD use the following method to allocate SID values, which 951 ensures that each SID will be allocated to just one group member. 953 1. A GCKS maintains an SID-counter, which records the SIDs that have 954 been allocated. SIDs are allocated sequentially, with zero as 955 the first allocated SID. 957 2. Each time an SID is allocated, the current value of the counter 958 is saved and allocated to the group member. The SID-counter is 959 then incremented in preparation for the next allocation. 961 3. When the GCKS specifies a counter-based mode of operation in the 962 data security SA a group member may request a count of SIDs 963 during registration in a Notify payload information of type 964 SENDER. When the GCKS receives this request, it increments the 965 SID-counter once for each requested SID, and distributes each SID 966 value to the group member. The GCKS SHOULD have a policy-defined 967 upper bound for the number of SIDs that it will return 968 irrespective of the number requested by the GM. 970 4. A GCKS allocates new SID values for each GSA_REGISTRATION 971 exchange originated by a sender, regardless of whether a group 972 member had previously contacted the GCKS. In this way, the GCKS 973 is not required to maintaining a record of which SID values it 974 had previously allocated to each group member. More importantly, 975 since the GCKS cannot reliably detect whether the group member 976 had sent data on the current group Data-Security SAs it does not 977 know what Data-Security counter-mode nonce values that a group 978 member has used. By distributing new SID values, the key server 979 ensures that each time a conforming group member installs a Data- 980 Security SA it will use a unique set of counter-based mode 981 nonces. 983 5. When the SID-counter maintained by the GCKS reaches its final SID 984 value, no more SID values can be distributed. Before 985 distributing any new SID values, the GCKS MUST delete the Data- 986 Security SAs for the group, followed by creation of new Data- 987 Security SAs, and resetting the SID-counter to its initial value. 989 6. The GCKS SHOULD send a GSA_REKEY message deleting all Data- 990 Security SAs and the Rekey SA for the group. This will result in 991 the group members initiating a new GSA_REGISTRATION exchange, in 992 which they will receive both new SID values and new Data-Security 993 SAs. The new SID values can safely be used because they are only 994 used with the new Data-Security SAs. Note that deletion of the 995 Rekey SA is necessary to ensure that group members receiving a 996 GSA_REKEY message before the re-register do not inadvertently use 997 their old SIDs with the new Data-Security SAs. Using the method 998 above, at no time can two group members use the same IV values 999 with the same Data-Security SA key. 1001 1.4.6.2. GM Usage of SIDs 1003 A GM applies the SID to data security SA as follows. 1005 o The most significant bits NUMBER_OF_SID_BITS of the IV are taken 1006 to be the SID field of the IV. 1008 o The SID is placed in the least significant bits of the SID field, 1009 where any unused most significant bits are set to zero. If the 1010 SID value doesn't fit into the NUMBER_OF_SID_BITS bits, then the 1011 GM MUST treat this as a fatal error and re-register to the group. 1013 2. Group Key Management and Access Control 1015 Through the G-IKEv2 rekey, G-IKEv2 supports algorithms such as 1016 Logical Key Hierarchy (LKH) that have the property of denying access 1017 to a new group key by a member removed from the group (forward access 1018 control) and to an old group key by a member added to the group 1019 (backward access control). An unrelated notion to PFS, "forward 1020 access control" and "backward access control" have been called 1021 "perfect forward security" and "perfect backward security" in the 1022 literature [RFC2627]. 1024 Group management algorithms providing forward and backward access 1025 control other than LKH have been proposed in the literature, 1026 including OFT [OFT] and Subset Difference [NNL]. These algorithms 1027 could be used with G-IKEv2, but are not specified as a part of this 1028 document. 1030 The Group Key Management Method transform from the GSA policy 1031 specifies how members of the group obtain group keys. This document 1032 specifies a single method for the group key management - Wrapped Key 1033 Download. This method assumes that all group keys are sent to the 1034 GMs by the GCKS encrypted with other keys, called Key Wrap Keys 1035 (KWK). 1037 2.1. Key Wrap Keys 1039 Every GM always knows at least one KWK - the KWK that is associated 1040 with the IKE SA or multicast rekey SA the wrapped keys are sent over. 1041 In this document it is called default KWK and is denoted as SK_w. 1043 The GCKS may also send other keys to GMs that will be used as Key 1044 Wrap Keys for the purpose of building key hierarchy. Each such key 1045 is associated with an encryption algorithm from the Encryption 1046 Algorithm transform used for the SA the key is sent in. The size of 1047 such key MUST be of the size of the key size of this Encryption 1048 Algorithm transform (taking into consideration the Key Length 1049 attribute for this transform if present). This association persists 1050 even if the key is used later in the context of another SA with 1051 possibly different Encryption Algorithm transform. 1053 To have an ability to provide forward access control the GCKS 1054 provides each GM with a personal key at the time of registration. 1055 Besides several intermediate keys that form a key hierarchy and are 1056 shared among several GMs are provided by the GCKS. 1058 2.1.1. Default Key Wrap Key 1060 The default KWK (SK_w) is only used in the context of a single IKE 1061 SA. Every IKE SA (unicast or group rekey) will have its own SK_w. 1062 The SK_w is used with the algorithm from the Encryption Algorithm 1063 transform used for the SA the SK_w is used in. The size of SK_w MUST 1064 be of the key size of this Encryption Algorithm transform (taking 1065 into consideration the Key Length attribute for this transform if 1066 present). 1068 For the unicast IKE SA (used for the GM registration and optionally 1069 for GSA_INBAND_REKEY exchanges) the SK_w is computed as follows: 1071 SK_w = prf+(SK_d, "Key Wrap for G-IKEv2") 1073 where the string "Key Wrap for G-IKEv2" is 20 ASCII characters 1074 without null termination. 1076 For the multicast rekey SA the SK_w is provided along with other SA 1077 keys as defined in Section 2.4. 1079 2.2. GCKS Key Management Semantics 1081 Wrapped Key Download method allows the GCKS to employ various key 1082 management policies. 1084 o A simple key management policy - when the GCKS always sends group 1085 SA keys encrypted with the SK_w. 1087 o An LKH key management policy - when the GCKS provides each GM with 1088 an individual key at the time of GM registration (encrypted with 1089 SK_w). Then the GCKS forms an hierarchy of keys so that the group 1090 SA keys are encrypted with other keys which are encrypted with 1091 other keys and so on, tracing back to the individual GMs' keys. 1093 Other key policies may also be employed by the GCKS. 1095 2.2.1. Forward Access Control Requirements 1097 When group membership is altered using a group management algorithm 1098 new GSA TEKs (and their associated keys) are usually also needed. 1099 New GSAs and keys ensure that members who were denied access can no 1100 longer participate in the group. 1102 If forward access control is a desired property of the group, new GSA 1103 TEKs and the associated key packets in the KD payload MUST NOT be 1104 included in a G-IKEv2 rekey message which changes group membership. 1105 This is required because the GSA TEK policy and the associated key 1106 packets in the KD payload are not protected with the new KEK. A 1107 second G-IKEv2 rekey message can deliver the new GSA TEKS and their 1108 associated key packets because it will be protected with the new KEK, 1109 and thus will not be visible to the members who were denied access. 1111 If forward access control policy for the group includes keeping group 1112 policy changes from members that are denied access to the group, then 1113 two sequential G-IKEv2 rekey messages changing the group KEK MUST be 1114 sent by the GCKS. The first G-IKEv2 rekey message creates a new KEK 1115 for the group. Group members, which are denied access, will not be 1116 able to access the new KEK, but will see the group policy since the 1117 G-IKEv2 rekey message is protected under the current KEK. A 1118 subsequent G-IKEv2 rekey message containing the changed group policy 1119 and again changing the KEK allows complete forward access control. A 1120 G-IKEv2 rekey message MUST NOT change the policy without creating a 1121 new KEK. 1123 If other methods of using LKH or other group management algorithms 1124 are added to G-IKEv2, those methods MAY remove the above restrictions 1125 requiring multiple G-IKEv2 rekey messages, providing those methods 1126 specify how the forward access control policy is maintained within a 1127 single G-IKEv2 rekey message. 1129 2.3. GM Key Management Semantics 1131 This specification defines a GM Key Management semantics in such a 1132 way, that it doesn't depend on the key management policy employed by 1133 the GCKS. This allows having all the complexity of key management in 1134 the GCKS, which is free to implement various key management policies, 1135 such as direct transmitting of group SA keys or using some kind of 1136 key hierarchy (e.g. LKH). For all these policies the GMs' behavior 1137 is the same. 1139 Each key is identified by a 32-bit number called Key ID. Zero Key ID 1140 has a special meaning - it always contains keying material from which 1141 the group SA keys are taken. 1143 All keys in G-IKEv2 are transmitted in encrypted form, which format 1144 is defined in Section 3.5.1. This format specifies a Key ID (ID of a 1145 key that is encrypted in this attribute) and a KWK ID (ID of a key 1146 that was used to encrypt this attribute). Keys may be encrypted 1147 either with default KWK (SK_w) or with other keys, which the GM has 1148 received in the KEY_WRAP_KEY attributes. If a key was encrypted with 1149 SK_w, then the KWK ID field is set to zero, otherwise the KWK ID 1150 field identifies the key used for encryption. 1152 When a GM receives a message from the GCKS installing new data 1153 security or rekey SA, it will contain a KD payload with a SA_KEY 1154 attribute containing keying material for this SA. For a data 1155 security SA exactly one SA_KEY attribute will be present with both 1156 Key ID and KWK ID fields set to zero. This means that the default 1157 KWK (SK_w) should be used to extract this keying material. 1159 For a multicast rekey SA multiple SA_KEY attributes may be present 1160 depending on the key management policy employed by the GCKS. If 1161 multiple SA_KEY attributes are present then all of them MUST contain 1162 the same keying material encrypted using different keys. The GM in 1163 general is unaware of the GCKS's key management policy and can always 1164 use the same procedure to get the keys. In particular, the GM's task 1165 is to find a way to decrypt at least one of the SA_KEY attributes 1166 using either the SK_w or the keys from the KEY_WRAP_KEY attributes 1167 that are present in the same message or were receives in previous 1168 messages. 1170 We will use the term "Key Path" to describe an ordered sequence of 1171 keys where each subsequent key was used to encrypt the previous one. 1172 The GM keeps its own Key Path (called working Key Path) in the memory 1173 associated with each group it is registered to and update it when 1174 needed. When the GSA_REKEY message is received the GM processes the 1175 received SA_KEY attributes one by one trying to construct a new key 1176 path that starts from this attributes and ends with any key in the 1177 working Key Path or with the default KWK (SK_w). 1179 In the simplest case the SA_KEY attribute is encrypted with SK_w so 1180 that the new Key Path is empty. If more complex key management 1181 policies are used then the Key Path will contain intermediate keys, 1182 which will be from the KEY_WRAP_KEY attributes received in the same 1183 messages. If the GM is able to construct a new Key Path, then it is 1184 able to decrypt the SA_KEY attribute and use its content to form the 1185 SA keys. If it is unable to build a new Key Path, then in means that 1186 the GM is excluded from the group. 1188 Depending on the new Key Path the GM should do the following actions 1189 to be prepared for future key updates: 1191 o If the new Key Path is empty then no actions are needed. This may 1192 happen if no KEY_WRAP_KEY attributes from the received message 1193 were used. 1195 o If the new Key Path is non-empty and it ends up with the default 1196 KWK (SK_w), then the whole new Key Path is stored by the GM as the 1197 GM's working Key Path. This situation may only happen at the time 1198 the GM is registering to the group, when the GCKS is providing it 1199 with its personal key and the other keys from the key tree that 1200 are needed for this GM. These keys form an initial working Key 1201 Path. 1203 o In all other cases the new Key Path will end up where some key 1204 from the GM's working Key Path was used. In this case the new Key 1205 Path replaces the part of the GM's working Key Path from the 1206 beginning and up to (but not including) the key that the GM has 1207 used to decrypt the last key in the new Key Path. 1209 Appendix A contains an example of how this algorithm works in case of 1210 LKH key management policy. 1212 2.4. Group SA Keys 1214 Group SA keys are downloaded to GMs in the form of keying material. 1215 The keys are taken from this keying material as if they were 1216 concatenated to form it. 1218 For a data security SA the keys are taken in accordance to the third 1219 bullet from Section 2.17 of [RFC7296]. In particular, for the ESP 1220 and AH SAs the encryption key (if any) MUST be taken from the first 1221 bits of the keying material and the integrity key (if any) MUST be 1222 taken from the remaining bits. 1224 For a group rekey SA the following keys are taken from the keying 1225 material: 1227 SK_e | SK_a | SK_w = KEYMAT 1229 where SK_e and SK_a are the keys used for the Encryption Algorithm 1230 and the Integrity Algorithm transforms for the corresponding SA and 1231 SK_w is a default KWK for this SA. Note, that SK_w is also used with 1232 the Encryption Algorithm transform as well as SK_e. Note also, that 1233 if AEAD algorithm is used for encryption, then SK_a key will not be 1234 used (GM can use the formula above assuming the length of SK_a is 1235 zero). 1237 3. Header and Payload Formats 1239 The G-IKEv2 is an IKEv2 extension and thus inherits its wire format 1240 for data structures. However, the processing of some payloads are 1241 different and several new payloads are defined: Group Identification 1242 (IDg), Group Security Association (GSA) Key Download (KD). New 1243 exchange types GSA_AUTH, GSA_REGISTRATION, GSA_REKEY and 1244 GSA_INBAND_REKEY are also added. 1246 This section describes new payloads and the differences in processing 1247 of existing IKEv2 payloads. 1249 3.1. G-IKEv2 Header 1251 G-IKEv2 uses the same IKE header format as specified in [RFC7296] 1252 section 3.1. Major Version is 2 and Minor Version is 0 as in IKEv2. 1253 IKE SA Initiator's SPI, IKE SA Responder's SPI, Flags, Message ID, 1254 and Length are as specified in [RFC7296]. 1256 3.2. Group Identification Payload 1258 The Group Identification (IDg) payload allows the group member to 1259 indicate which group it wants to join. The payload is constructed by 1260 using the IKEv2 Identification Payload (section 3.5 of [RFC7296]). 1261 ID type ID_KEY_ID MUST be supported. ID types ID_IPV4_ADDR, ID_FQDN, 1262 ID_RFC822_ADDR, ID_IPV6_ADDR SHOULD be supported. ID types 1263 ID_DER_ASN1_DN and ID_DER_ASN1_GN are not expected to be used. The 1264 Payload Type for the Group Identification payload is fifty (50). 1266 3.3. Security Association - GM Supported Transforms Payload 1268 The Security Association - GM Supported Transforms Payload (SAg) 1269 payload declares which Transforms a GM is willing to accept. The 1270 payload is constructed using the format of the IKEv2 Security 1271 Association payload (section 3.3 of [RFC7296]). The Payload Type for 1272 SAg is identical to the SA Payload Type - thirty-three (33). 1274 3.4. Group Security Association Payload 1276 The Group Security Association (GSA) payload is used by the GCKS to 1277 assert security attributes for both Rekey and Data-security SAs. The 1278 Payload Type for the Group Security Association payload is fifty-one 1279 (51). 1281 1 2 3 1282 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 1283 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1284 | Next Payload |C| RESERVED | Payload Length | 1285 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1286 | | 1287 ~ ~ 1288 | | 1289 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1291 Figure 13: GSA Payload Format 1293 The Security Association Payload fields are defined as follows: 1295 o Next Payload, C, RESERVED, Payload Length fields comprise the 1296 IKEv2 Generic Payload Header and are defined in Section 3.2. of 1297 [RFC7296]. 1299 o Group Policies (variable) - A set of group policies for the group. 1301 3.4.1. Group Policies 1303 Croup policies are comprised of two types of policy - Group SA (GSA) 1304 policy and Group Associated (GA) policy. GSA policy defines 1305 parameters for the Security Association for the group. Depending on 1306 the employed security protocol GSA policies may further be classified 1307 as rekeying SA policy (GSA KEK) and data traffic SA policy (GSA TEK). 1308 GSA payload may contain zero or one GSA KEK policy, zero or more GSA 1309 TEK policies, and zero or one GA policy, where either one GSA KEK or 1310 GSA TEK policy MUST be present. 1312 This latitude allows various group policies to be accommodated. For 1313 example if the group policy does not require the use of a Rekey SA, 1314 the GCKS would not need to send a GSA KEK policy to the group member 1315 since all SA updates would be performed using the Registration SA. 1316 Alternatively, group policy might use a Rekey SA but choose to 1317 download a KEK to the group member only as part of the Registration 1318 SA. Therefore, the GSA KEK policy would not be necessary as part of 1319 the GSA_REKEY message. 1321 Specifying multiple GSA TEKs allows multiple related data streams 1322 (e.g., video, audio, and text) to be associated with a session, but 1323 each protected with an individual security association policy. 1325 A GAP allows for the distribution of group-wise policy, such as 1326 instructions for when to activate and de-activate SAs. 1328 Policies are distributed in substructures to the GSA payload. The 1329 format of the substructures is defined below in Section 3.4.2 (for 1330 GSA policy) and in Section 3.4.3 (for GA policy). The first octet of 1331 the substructure unambiguously determines its type - it is zero for 1332 GAP and non-zero (actually, it is the security protocol ID) for GSA 1333 policies. 1335 3.4.2. Group Security Association Policy Substructure 1337 The GSA policy substructure contains parameters for the SA used with 1338 this group. Depending on the security protocol the SA is either a 1339 rekey SA or a data security SA (ESP and AH). It is NOT RECOMMENDED 1340 that the GCKS distribute both ESP and AH policies for the same set of 1341 Traffic Selectors. 1343 1 2 3 1344 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 1345 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1346 | Protocol | SPI Size | Length | 1347 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1348 | | 1349 ~ SPI ~ 1350 | | 1351 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1352 | | 1353 ~ Source Traffic Selector ~ 1354 | | 1355 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1356 | | 1357 ~ Destination Traffic Selector ~ 1358 | | 1359 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1360 | | 1361 ~ ~ 1362 | | 1363 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1364 | | 1365 ~ ~ 1366 | | 1367 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1369 Figure 14: GSA Policy Substructure Format 1371 The GSA policy fields are defined as follows: 1373 o Protocol (1 octet) - Identifies the security protocol for this 1374 group SA. The values are defined in the IKEv2 Security Protocol 1375 Identifiers in [IKEV2-IANA]. The valid values for this field are: 1376 (GIKE_REKEY) for GSA KEK policy and 2 (AH) or 3 (ESP) for 1377 GSA TEK policy. 1379 o SPI Size (1 octet) - Size of Security Parameter Index (SPI) for 1380 the group SA. SPI size depends on the SA protocol. For 1381 GIKE_REKEY it is 16 octets, while for AH and ESP it is 4 octets. 1383 o Length (2 octets, unsigned integer) - Length of this substructure 1384 including the header. 1386 o SPI (variable) - Security Parameter Index for the group SA. The 1387 size of this field is determined by the SPI Size field. As 1388 described above, these SPIs are assigned by the GCKS. In case of 1389 GIKE_REKEY the SPI must be the IKEv2 Header SPI pair where the 1390 first 8 octets become the "Initiator's SPI" field in the G-IKEv2 1391 rekey message IKEv2 HDR, and the second 8 octets become the 1392 "Responder's SPI" in the same HDR. When selecting SPI the GCKS 1393 MUST make sure that the sole first 8 octets (corresponding to 1394 "Initiator's SPI" field in the IKEv2 header) uniquely identify the 1395 Rekey SA. 1397 o Source & Destination Traffic Selectors - (variable) - 1398 Substructures describing the source and destination of the network 1399 identities. The format for these substructures is defined in 1400 IKEv2 [RFC7296], section 3.13.1. For the group rekey SA (protocol 1401 GIKE_REKEY) the destination traffic selectors MUST define a single 1402 IP address, IP protocol and port the GSA_REKEY messages will be 1403 destined to. The source traffic selector in this case MUST either 1404 define a single IP address, IP protocol and port the GSA_REKEY 1405 messages will be originated from or be a wildcard selector. For 1406 the data security (AH and ESP) SAs the traffic selectors instead 1407 specify characteristics of the traffic to be protected by the 1408 corresponding SA. 1410 o GSA Transforms (variable) - A list of Transform Substructures 1411 specifies the policy information for the group SA. The format is 1412 defined in IKEv2 [RFC7296], section 3.3.2. The Last Substruc 1413 value in each Transform Substructure will be set to 3 except for 1414 the last one in the list, which is set to 0. Section 3.4.2.1 1415 describes using IKEv2 transforms in GSA policy substructure. 1417 o GSA Attributes (variable) - Contains policy attributes associated 1418 with the group SA. The following sections describe the possible 1419 attributes. Any or all attributes may be optional, depending on 1420 the group SA protocol and the group policy. Section 3.4.2.2 1421 defines attributes used in GSA policy. 1423 3.4.2.1. GSA Transforms 1425 GSA policy is defined by means of transforms in GSA policy 1426 substructure. For this purpose the transforms defined in [RFC7296] 1427 are used. In addition, new transform types are defined for using in 1428 G-IKEv2: Authentication Method (AUTH) and Group Key Management Method 1429 (GKM), see Section 6. 1431 Valid Transform Types depend on group SA protocol and are summarized 1432 in the table below. 1434 Protocol Mandatory Types Optional Types 1435 ---------------------------------------------------------- 1436 GIKE_REKEY ENCR, INTEG*, PRF, AUTH, GKM 1437 ESP ENCR INTEG 1438 AH INTEG 1440 Figure 15: Valid Transform Types 1442 (*) If AEAD encryption algorithm is used, then INTEG transform MUST 1443 NOT be specified, otherwise it MUST be specified. 1445 3.4.2.1.1. Authentication Method Transform 1447 The Authentication Method (AUTH) transform is used in the GIKE_REKEY 1448 policy to convey information of how GCKS will authenticate the 1449 GSA_REKEY messages. This values are from the IKEv2 Authentication 1450 Method registry [IKEV2-IANA]. Note, that this registry defines only 1451 256 possible values, so even that Transform ID field in the Transform 1452 substructure allows for 65536 possible values, in case of the 1453 Authentication Method transform the values 257-65535 MUST NOT be 1454 used. 1456 Among the currently defined authentication methods in the IKEv2 1457 Authentication Method registry, only the following are allowed to be 1458 used in the Authentication Method transform: Shared Key Message 1459 Integrity Code, NULL Authentication and Digital Signature. Other 1460 currently defined authentication methods MUST NOT be used. The 1461 following semantics is associated with each of the allowed methods. 1463 Shared Key Message Integrity Code - GCKS will authenticates the 1464 GSA_REKEY messages by means of shared secret. In this case the 1465 GCKS MUST include the AUTH_KEY attribute containing the shared key 1466 into the KD payload at the time the GM is registered to the group. 1468 NULL Authentication - No additional authentication of the 1469 GSA_REKEY messages will be provided by the GCKS (besides the 1470 ability for the GMs to correctly decrypt them and verify their 1471 ICV). In this case the GCKS MUST NOT include the AUTH_KEY 1472 attribute into the KD payload. 1474 Digital Signature - Digital signatures will be used by the GCKS to 1475 authenticate the GSA_REKEY messages. In this case the GCKS MUST 1476 include the AUTH_KEY attribute containing the public key into the 1477 KD payload at the time the GM is registered to the group. To 1478 specify the details of the signature algorithm a new attribute 1479 Algorithm Identifier () is defined. This attribute 1480 contains DER-encoded ASN.1 object AlgorithmIdentifier, which would 1481 specify the signature algorithm and the hash function that the 1482 GCKS will use for authentication. The AlgorithmIdentifier object 1483 is defined in section 4.1.1.2 of [RFC5280], see also [RFC7427] for 1484 the list of common AlgorithmIdentifier values used in IKEv2. In 1485 case of using digital signature the GCKS MUST include the 1486 Algorithm Identifier attribute in the Authentication Method 1487 transform. 1489 The type of the Authentication Method Transform is . 1491 3.4.2.1.2. Group Key Management Method Transform 1493 The Group Key Management Method (GKM) transform is used in the 1494 GIKE_REKEY policy to convey information of how GCKS will manage the 1495 group keys to provide forward and backward access control (i.e., used 1496 to exclude group members). Possible key management methods are 1497 defined in a new IKEv2 registry "Transform Type - Group Key 1498 Management Methods" (see Section 6). This document defines one 1499 values for this registry: 1501 Wrapped Key Download () - Keys are downloaded by GCKS 1502 to the GMs in encrypted form. This algorithm may provide forward 1503 and backward access control if some form of key hierarchy is used 1504 and each GM is provided with a personal key at the time of 1505 registration. Otherwise no access control is provided. 1507 The type of the Group Key Management Method transform is . 1510 3.4.2.2. GSA Attributes 1512 GSA attributes are generally used to provide GMs with additional 1513 parameters for the GSA policy. Unlike security parameters 1514 distributed via transforms, which are expected not to change over 1515 time (unless policy changes), the parameters distributed via GSA 1516 attributes may depend on the time the distribution takes place, on 1517 the existence of others group SAs or on other conditions. 1519 This document creates a new IKEv2 IANA registry for the types of the 1520 GSA attributes which is initially filled as described in Section 6. 1521 In particular, the following attributes are initially added. 1523 GSA Attributes Value Type Multiple Used In 1524 --------------------------------------------------------------------- 1525 Reserved 0 1526 GSA_KEY_LIFETIME 1 V N (GIKE_REKEY, AH, ESP) 1527 GSA_INITIAL_MESSAGE_ID 2 V N (GIKE_REKEY) 1528 GSA_NEXT_SPI 3 V Y (GIKE_REKEY, AH, ESP) 1529 The attributes must follow the format defined in the IKEv2 [RFC7296] 1530 section 3.3.5. In the table, attributes that are defined as TV are 1531 marked as Basic (B); attributes that are defined as TLV are marked as 1532 Variable (V). 1534 3.4.2.2.1. GSA_KEY_LIFETIME Attribute 1536 The GSA_KEY_LIFETIME attribute specifies the maximum time for which 1537 the group SA is valid. The value is a 4 octet number defining a 1538 valid time period in seconds. A single attribute of this type MUST 1539 be included into any GSA policy substructure. 1541 When the lifetime expires, the group security association and all 1542 associated keys MUST be deleted. The GCKS may delete the SA at any 1543 time before the end of the valid period. 1545 3.4.2.2.2. GSA_INITIAL_MESSAGE_ID Attribute 1547 The GSA_INITIAL_MESSAGE_ID attribute defines the initial Message ID 1548 to be used by the GCKS in the GSA_REKEY messages. The Message ID is 1549 a 4 octet unsigned integer in network byte order. 1551 A single attribute of this type MUST be included into the GSA KEK 1552 policy substructure if the initial Message ID is non-zero. Note, 1553 that it is always the case if GMs join the group after some multicast 1554 rekey operations have already taken place, so in these cases this 1555 attribute will be included into the GSA policy at the time of GMs' 1556 registration. 1558 3.4.2.2.3. GSA_NEXT_SPI Attribute 1560 The optional GSA_NEXT_SPI attribute contains SPI that the GCKS 1561 reserved for the next group SA replacing this group SA. The length 1562 of the attribute data is determined by the SPI Size field in the GSA 1563 Policy substructure the attribute resides in (see Section 3.4.2), and 1564 the attribute data contains SPI as it would appear on the network. 1565 Multiple attributes of this type MAY be included, meaning that any of 1566 the supplied SPIs can be used in the replacement group SA. 1568 The GM may store these values and if later the GM starts receiving 1569 group SA messages with one of these SPIs without seeing a rekey 1570 message over the current rekey SA, this may be used as an indication, 1571 that the rekey message got lost on its way to this GM. In this case 1572 the GM SHOULD re-register to the group. 1574 Note, that this method of detecting lost rekey messages can only be 1575 used by passive GMs, i.e. those, that only listen and don't send 1576 data. There is also no point to include this attribute in the 1577 GSA_INBAND_REKEY messages, since they use reliable transport. Note 1578 also, that the GCKS is free to forget its promises and not to use the 1579 SPIs it sent in the GSA_NEXT_SPI attributes before (e.g. in case of 1580 the GCKS reboot), so the GM must only treat these information as a 1581 "best effort" made by GCKS to prepare for future rekeys. 1583 3.4.3. Group Associated Policy Substructure 1585 Group specific policy that does not belong to any SA policy can be 1586 distributed to all group member using Group Associated Policy (GAP) 1587 substructure. 1589 The GAP substructure is defined as follows: 1591 1 2 3 1592 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 1593 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1594 | ZERO | Length | 1595 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1596 | | 1597 ~ ~ 1598 | | 1599 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1601 Figure 16: GAP Substructure Format 1603 The GAP substructure fields are defined as follows: 1605 o ZERO (2 octets) - MUST be zero. 1607 o Length (2 octets, unsigned integer) - Length of this substructure 1608 including the header. 1610 o GAP Attributes (variable) - Contains policy attributes associated 1611 with no specific SA. The following sections describe the possible 1612 attributes. Any or all attributes may be optional, depending on 1613 the group policy. 1615 This document creates a new IKEv2 IANA registry for the types of the 1616 GAP attributes which is initially filled as described in Section 6. 1617 In particular, the following attributes are initially added. 1619 GAP Attributes Value Type Multiple 1620 ---------------------------------------------------- 1621 Reserved 0 1622 GAP_ATD 1 B N 1623 GAP_DTD 2 B N 1624 GAP_SID_BITS 3 B N 1626 The attributes must follow the format defined in the IKEv2 [RFC7296] 1627 section 3.3.5. In the table, attributes that are defined as TV are 1628 marked as Basic (B); attributes that are defined as TLV are marked as 1629 Variable (V). 1631 3.4.3.1. GAP_ATD And GAP_DTD Attributes 1633 Section 4.2.1 of [RFC5374] specifies a key rollover method that 1634 requires two values be provided to group members - Activation Time 1635 Delay (ATD) and Deactivation Time Delay (DTD). 1637 The GAP_ATD attribute allows a GCKS to set the Activation Time Delay 1638 for data security SAs of the group. The ATD defines how long active 1639 members of the group (those who sends traffic) should wait after 1640 receiving new SAs before staring sending traffic over them. Note, 1641 that to achieve smooth rollover passive members of the group should 1642 activate the SAs immediately once they receive them. 1644 The GAP_DTD attribute allows the GCKS to set the Deactivation Time 1645 Delay for previously distributed SAs. The DTD defines how long after 1646 receiving a request to delete data security SAs passive group members 1647 should wait before actually deleting them. Note that active members 1648 of the group should stop sending traffic over these old SAs once new 1649 replacement SAs are activated (after time specified in the GAP_ATD 1650 attribute). 1652 The GAP_ATD and GAP_DTD attributes contain 16 bit unsigned integer in 1653 a network byte order, specifying the delay in seconds. These 1654 attributes are OPTIONAL. If one of them or both are not sent by the 1655 GCKS, the GMs should use default values for activation and 1656 deactivation time delays. 1658 3.4.3.2. GAP_SID_BITS Attribute 1660 The GAP_SID_BITS attribute declares how many bits of the cipher nonce 1661 are taken to represent an SID value. The bits are applied as the 1662 most significant bits of the IV, as shown in Figure 1 of [RFC6054] 1663 and specified in Section 1.4.6.2. Guidance for a GCKS choosing the 1664 NUMBER_OF_SID_BITS is provided in Section 3 of [RFC6054]. This value 1665 is applied to each SID value distributed in the KD payload. 1667 The GCKS MUST include this attribute if there are more than one 1668 sender in the group and any of the data security SAs use counter- 1669 based cipher mode. The number of SID bits is represented as 16 bit 1670 unsigned integer in network byte order. 1672 3.5. Key Download Payload 1674 The Key Download (KD) payload contains the group keys for the group 1675 specified in the GSA Payload. The Payload Type for the Key Download 1676 payload is fifty-two (52). 1678 1 2 3 1679 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 1680 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1681 | Next Payload |C| RESERVED | Length | 1682 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1683 | | 1684 ~ ~ 1685 | | 1686 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1688 Figure 17: Key Download Payload Format 1690 The Key Download payload fields are defined as follows: 1692 o Next Payload, C, RESERVED, Payload Length fields comprise the 1693 IKEv2 Generic Payload Header and are defined in Section 3.2. of 1694 [RFC7296]. 1696 o Key Packets (variable) - Contains Group Key Packet and Member Key 1697 Packet substructures. Each Key Packet contains keys for a single 1698 group rekey or data security SA or a keys and security parameters 1699 for a GM. 1701 Two types of Key Packets are used - Group Key Packet and Member Key 1702 Packet. 1704 3.5.1. Wrapped Key Format 1706 The symmetric keys in G-IKEv2 are never sent in clear. They are 1707 always encrypted with other keys using the format called Wrapped Key 1708 that is shown below (Figure 18). 1710 The keys are encrypted using algorithm that is used to encrypt the 1711 message the keys are sent in. It means, that in case of unicast IKE 1712 SA (used for GMs registration and rekeying using GSA_INBAND_REKEY) 1713 the encryption algorithm will be the one negotiated during the SA 1714 establishment, while for the GSA_REKEY messages the algorithm will be 1715 provided by the GCKS in the Encryption Algorithm transform in the GSA 1716 payload when this multicast SA was being established (not in the same 1717 GSA_REKEY message). 1719 If AEAD mode is used for encryption, then for the purpose of key 1720 encryption the authentication tag MUST NOT be used (both not 1721 calculated and not verified), since the G-IKEv2 provides 1722 authentication of all its messages. In addition there is no AAD in 1723 this case. If encryption algorithm requires padding, then the 1724 encrypted key MUST be padded before encryption to have the required 1725 size. If the encryption algorithm doesn't define the padding 1726 content, then the following scheme SHOULD be used: the Padding bytes 1727 are initialized with a series of (unsigned, 1-byte) integer values. 1728 The first padding byte appended to the plaintext is numbered 1, with 1729 subsequent padding bytes making up a monotonically increasing 1730 sequence: 1, 2, 3, .... The length of the padding is not transmitted 1731 and is implicitly determined, since the length of the key is known. 1733 1 2 3 1734 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 1735 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1736 | Key ID | 1737 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1738 | KWK ID | 1739 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1740 | | 1741 ~ IV ~ 1742 | | 1743 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1744 | | 1745 ~ Encrypted Key ~ 1746 | | 1747 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1749 Figure 18: Wrapped Key Format 1751 The Wrapped Key fields are defined as follows: 1753 o Key ID (4 octets) - ID of the encrypted key. The value zero means 1754 that the encrypted key contains keying material for the group SA, 1755 otherwise it contains some intermediate key. 1757 o Key Wrap Key (KWK) ID (4 octets) - ID of the key that was used to 1758 encrypt this key. The value zero means that the default KWK was 1759 used to encrypt the key, otherwise some other key was used. 1761 o IV (variable) - Initialization Vector used for encryption. The 1762 size and the content of IV is defined by the encryption algorithm 1763 employed. 1765 o Encrypted Key (variable) - The encrypted key bits. These bits may 1766 comprise either a single encrypted key or a result of encryption 1767 of a concatenation of keys (key material) for several algorithms. 1769 3.5.2. Group Key Packet Substructure 1771 Group Key Packet substructure contains SA key information. This key 1772 information is associated with some group SAs: either with data 1773 security SAs or with group rekey SA. 1775 1 2 3 1776 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 1777 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1778 | Protocol | SPI Size | Length | 1779 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1780 | | 1781 ~ SPI ~ 1782 | | 1783 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1784 | | 1785 ~ ~ 1786 | | 1787 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1789 Figure 19: Group Key Packet Substructure Format 1791 o Protocol (1 octet) - Identifies the security protocol for this key 1792 packet. The values are defined in the IKEv2 Security Protocol 1793 Identifiers in [IKEV2-IANA]. The valid values for this field are: 1794 (GIKE_REKEY) for KEK Key packet and 2 (AH) or 3 (ESP) for 1795 TEK key packet. 1797 o SPI Size (1 octet) - Size of Security Parameter Index (SPI) for 1798 the corresponding SA. SPI size depends on the security protocol. 1799 For GIKE_REKEY it is 16 octets, while for AH and ESP it is 4 1800 octets. 1802 o Length (2 octets, unsigned integer) - Length of this substructure 1803 including the header. 1805 o SPI (variable) - Security Parameter Index for the corresponding 1806 SA. The size of this field is determined by the SPI Size field. 1807 In case of GIKE_REKEY the SPI must be the IKEv2 Header SPI pair 1808 where the first 8 octets become the "Initiator's SPI" field in the 1809 G-IKEv2 rekey message IKEv2 HDR, and the second 8 octets become 1810 the "Responder's SPI" in the same HDR. When selecting SPI the 1811 GCKS MUST make sure that the sole first 8 octets (corresponding to 1812 "Initiator's SPI" field in the IKEv2 header) uniquely identify the 1813 Rekey SA. 1815 o Group Key Download Attributes (variable length) - Contains Key 1816 information for the corresponding SA. 1818 This document creates a new IKEv2 IANA registry for the types of the 1819 Group Key Download attributes which is initially filled as described 1820 in Section 6. In particular, the following attributes are initially 1821 added. 1823 GKD Attributes Value Type Multiple Used In 1824 ------------------------------------------------------------ 1825 Reserved 0 1826 SA_KEY 1 V Y (GIKE_REKEY) 1827 N (AH, ESP) 1829 The attributes must follow the format defined in the IKEv2 [RFC7296] 1830 section 3.3.5. In the table, attributes that are defined as TV are 1831 marked as Basic (B); attributes that are defined as TLV are marked as 1832 Variable (V). 1834 3.5.2.1. SA_KEY Attribute 1836 The SA_KEY attribute contains a keying material for the corresponding 1837 SA. The content of the attribute is formatted according to 1838 Section 3.5.1 with a precondition that the Key ID field MUST be zero. 1839 The size of the keying material MUST be equal to the total size of 1840 the keys needed to be taken from this keying material (see 1841 Section 2.4) for the corresponding SA. 1843 If the Key Packet is for a data security SA (AH or ESP protocols), 1844 then exactly one SA_KEY attribute MUST be present with both Key ID 1845 and KWK ID fields set to zero. 1847 If the Key Packet is for a rekey SA (GIKE_REKEY protocol), then at 1848 least one SA_KEY attribute with zero Key ID MUST be present. 1849 Depending on GCKS key management policy more SA_KEY attributes MAY be 1850 present. 1852 3.5.3. Member Key Packet Substructure 1854 The Member Key Packet substructure contains keys and other parameters 1855 that are specific for the member of the group and are not associated 1856 with any particular group SA. 1858 1 2 3 1859 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 1860 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1861 | ZERO | Length | 1862 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1863 | | 1864 ~ ~ 1865 | | 1866 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1868 Figure 20: Member Key Packet Substructure Format 1870 The Member Key Packet substructure fields are defined as follows: 1872 o ZERO (2 octets) - MUST be zero. 1874 o Length (2 octets, unsigned integer) - Length of this substructure 1875 including the header. 1877 o Member Key Download Attributes (variable length) - Contains Key 1878 information and other parameters exclusively for a particular 1879 member of the group. 1881 Member Key Packet substructure contains sensitive information for a 1882 single GM, for this reason it MUST NOT be sent in GSA_REKEY messages 1883 and MUST only be sent via unicast SA at the time the GM registers to 1884 the group (in either GSA_AUTH or GSA_REGISTRATION exchanges). 1886 This document creates a new IKEv2 IANA registry for the types of the 1887 Member Key Download attributes which is initially filled as described 1888 in Section 6. In particular, the following attributes are initially 1889 added. 1891 MKD Attributes Value Type Multiple 1892 ------------------------------------------------ 1893 Reserved 0 1894 KEY_WRAP_KEY 1 V Y 1895 GM_SID 2 V Y 1896 AUTH_KEY 3 V N 1898 The attributes must follow the format defined in the IKEv2 [RFC7296] 1899 section 3.3.5. In the table, attributes that are defined as TV are 1900 marked as Basic (B); attributes that are defined as TLV are marked as 1901 Variable (V). 1903 3.5.3.1. KEY_WRAP_KEY Attribute 1905 The KEY_WRAP_KEY attribute contains a key that is used to encrypt 1906 other keys. One or more the these attributes are sent to GMs if the 1907 GCKS key management policy relies on some key hierarchy (e.g. LKH). 1909 The content of the attribute has a format defined in Section 3.5.1 1910 with a precondition that the Key ID field MUST NOT be zero. The 1911 algorithm associated with the key is from the Encryption Transform 1912 for the SA the KEY_WRAP_KEY attributes was sent in. The size of the 1913 key MUST be equal to the key size for this algorithm. 1915 Multiple instances of the KEY_WRAP_KEY attributes MAY be present in 1916 the key packet. 1918 3.5.3.2. GM_SID Attribute 1920 The GM_SID attribute is used to download one or more Sender-ID (SID) 1921 values for the exclusive use of a group member. One or more of this 1922 attributes MUST be sent by the GCKS if the GM informed the GCKS that 1923 it would be a sender (by inclusion the SENDER notification to the 1924 request) and at least one of the data security SAs included in the 1925 GSA payload uses counter-based mode of encryption. 1927 If the GMs has requested multiple SID values in the SENDER 1928 notification, then the GCKS SHOULD provide it with the requested 1929 number of SIDs by sending multiple instances of the GM_SID attribute. 1930 The GCKS MAY send fewer SIDs than requested by the GM (e.g. if it is 1931 running out of SIDs), but it MUST NOT send more than requested. 1933 3.5.3.3. AUTH_KEY Attribute 1935 The AUTH_KEY attribute contains the key that is used to authenticate 1936 the GSA_REKEY messages. The content of the attribute depends on the 1937 authentication method the GCKS specified in the Authentication Method 1938 transform in the GSA payload. 1940 o If a shared secret is used for the GSA_REKEY messages 1941 authentication then the content of the AUTH_KEY attribute is the 1942 shared secret that MUST be represented in the form of Wrapped Key 1943 (see Section 3.5.1) with zero KWK ID. The Key ID in this case is 1944 arbitrary and MUST be ignored by the GM. 1946 o If digital signatures are used for the GSA_REKEY messages 1947 authentication then the content of the AUTH_KEY attribute is a 1948 public key used for digital signature authentication. The public 1949 key MUST be represented as DER-encoded ASN.1 object 1950 SubjectPublicKeyInfo, defined in section 4.1.2.7 of [RFC5280]. 1952 The signature algorithm that will use this key was specified in 1953 the Algorithm Identifier attribute of the Authentication Method 1954 transform. The key MUST be compatible with this algorithm. An 1955 RSA public key format is defined in [RFC3447], Section A.1. DSS 1956 public key format is defined in [RFC3279] Section 2.3.2. For 1957 ECDSA Public keys, use format described in [RFC5480] Section 2. 1958 Other algorithms added to the IKEv2 Authentication Method registry 1959 are also expected to include a format of the SubjectPublicKeyInfo 1960 object included in the algorithm specification. 1962 Multiple instances of the AUTH_KEY attributes MUST NOT be sent. 1964 3.6. Delete Payload 1966 There are occasions when the GCKS may want to signal to group members 1967 to delete policy at the end of a broadcast, if group policy has 1968 changed, or the GCKS needs to reset the policy and keying material 1969 for the group due to an emergency. Deletion of keys MAY be 1970 accomplished by sending an IKEv2 Delete Payload, section 3.11 of 1971 [RFC7296] as part of a registration or rekey Exchange. Whenever an 1972 SA is to be deleted, the GKCS SHOULD send the Delete Payload in both 1973 registration and rekey exchanges, because GMs with previous group 1974 policy may contact the GCKS using either exchange. 1976 The Protocol ID MUST be GIKE_REKEY () for GSA_REKEY pseudo- 1977 exchange, 2 for AH or 3 for ESP. Note that only one protocol id 1978 value can be defined in a Delete payload. If a TEK and a KEK SA for 1979 GSA_REKEY pseudo-exchange must be deleted, they must be sent in 1980 different Delete payloads. Similarly, if a TEK specifying ESP and a 1981 TEK specifying AH need to be deleted, they must be sent in different 1982 Delete payloads. 1984 There may be circumstances where the GCKS may want to reset the 1985 policy and keying material for the group. The GCKS can signal 1986 deletion of all policy of a particular TEK by sending a TEK with a 1987 SPI value equal to zero in the delete payload. In the event that the 1988 administrator is no longer confident in the integrity of the group 1989 they may wish to remove all KEK and all the TEKs in the group. This 1990 is done by having the GCKS send a delete payload with a SPI of zero 1991 and a Protocol-ID of AH or ESP to delete all TEKs, followed by 1992 another delete payload with a SPI value of zero and Protocol-ID of 1993 KEK SA to delete the KEK SA. 1995 3.7. Notify Payload 1997 G-IKEv2 uses the same Notify payload as specified in [RFC7296], 1998 section 3.10. 2000 There are additional Notify Message types introduced by G-IKEv2 to 2001 communicate error conditions and status (see Section 6). 2003 o INVALID_GROUP_ID (45) - error type notification that indicates 2004 that the group id sent during the registration process is invalid. 2005 The Protocol ID and SPI Size fields in the Notify payload MUST be 2006 zero. There is no data associated with this notification and the 2007 content of the Notification Data field MUST be ignored on receipt. 2009 o AUTHORIZATION_FAILED (46) - error type notification that is sent 2010 in the response to a GSA_AUTH message when authorization failed. 2011 The Protocol ID and SPI Size fields in the Notify payload MUST be 2012 zero. There is no data associated with this notification and the 2013 content of the Notification Data field MUST be ignored on receipt. 2015 o REGISTRATION_FAILED () - error type notification that is sent 2016 by the GCKS when the GM registration request cannot be satisfied. 2017 The Protocol ID and SPI Size fields in the Notify payload MUST be 2018 zero. There is no data associated with this notification and the 2019 content of the Notification Data field MUST be ignored on receipt. 2021 o SENDER (16429) - status type notification that is sent in the 2022 GSA_AUTH or the GSA_REGISTRATION exchanges to indicate that the GM 2023 intends to be sender of data traffic. The data includes a count 2024 of how many SID values the GM desires. The count MUST be 4 octets 2025 long and contain the big endian representation of the number of 2026 requested SIDs. The Protocol ID and SPI Size fields in the Notify 2027 payload MUST be zero. 2029 o REKEY_IS_NEEDED () - status type notification that is sent in 2030 the GSA_AUTH response message to indicate that the GM must perform 2031 an immediate rekey of IKE SA to make it secure against quantum 2032 computers and then start a registration request over. The 2033 Protocol ID and SPI Size fields in the Notify payload MUST be 2034 zero. There is no data associated with this notification and the 2035 content of the Notification Data field MUST be ignored on receipt. 2037 3.7.1. USE_TRANSPORT_MODE Notification 2039 This specification uses USE_TRANSPORT_MODE notification defined in 2040 section 3.10.1 of [RFC7296] to specify which mode data security SAs 2041 should be created in. The GCKS MUST include one USE_TRANSPORT_MODE 2042 notification in a message containing the GSA payload for every data 2043 security SAs specified in this payload that is to be created in 2044 transport mode. In other words, there must be as many these 2045 notifications included in the message as many SAs are created in 2046 transport mode. The Protocol ID, SPI Size and SPI fields of the 2047 Notify Payload MUST correctly specify each such SA. 2049 3.8. Authentication Payload 2051 G-IKEv2 uses the same Authentication payload as specified in 2052 [RFC7296], section 3.8, to authenticate the rekey message. However, 2053 if it is used in the GSA_REKEY messages the content of the payload is 2054 computed differently, as described in Section 1.4.5.1.1. 2056 4. Interaction with other IKEv2 Protocol Extensions 2058 A number of IKEv2 extensions is defined that can be used to extend 2059 protocol functionality. G-IKEv2 is compatible with most of them. In 2060 particular, EAP authentication defined in [RFC7296] can be used to 2061 establish registration IKE SA, as well as Secure Password 2062 authentication ([RFC6467]). G-IKEv2 is compatible with and can use 2063 IKEv2 Session Resumption [RFC5723] except that a GM would include the 2064 initial ticket request in a GSA_AUTH exchange instead of an IKE_AUTH 2065 exchange. G-IKEv2 is also compatible with Multiple Key Exchanges in 2066 IKEv2 framework, defined in [I-D.ietf-ipsecme-ikev2-multiple-ke]. 2068 Some IKEv2 extensions however require special handling if used in 2069 G-IKEv2. 2071 4.1. Mixing Preshared Keys in IKEv2 for Post-quantum Security 2073 G-IKEv2 can take advantage of the protection provided by Postquantum 2074 Preshared Keys (PPK) for IKEv2 [RFC8784]. However, the use of PPK 2075 leaves the initial IKE SA susceptible to quantum computer (QC) 2076 attacks. For this reason an alternative approach for using PPK in 2077 IKEv2 defined in [I-D.smyslov-ipsecme-ikev2-qr-alt] SHOULD be used. 2079 If the alternative approach is not supported by the peers, then the 2080 GCKS MUST NOT send GSA and KD payloads in the GSA_AUTH response 2081 message. Instead, the GCKS MUST return a new notification 2082 REKEY_IS_NEEDED. Upon receiving this notification in the GSA_AUTH 2083 response the GM MUST perform an IKE SA rekey and then initiate a new 2084 GSA_REGISTRATION request for the same group. Below are possible 2085 scenarios involving using PPK. 2087 The GM starts the IKE_SA_INIT exchange requesting using PPK, and the 2088 GCKS responds with agreement to do it, or aborts according to its 2089 "mandatory_or_not" flag: 2091 Initiator (Member) Responder (GCKS) 2092 -------------------- ------------------ 2093 HDR, SAi1, KEi, Ni, N(USE_PPK) --> 2094 <-- DR, SAr1, KEr, Nr, [CERTREQ], 2095 N(USE_PPK) 2097 Figure 21: IKE_SA_INIT Exchange requesting using PPK 2099 The GM then starts the GSA_AUTH exchange with the PPK_ID; if using 2100 PPK is not mandatory for the GM, the NO_PPK_AUTH notification is 2101 included in the request: 2103 Initiator (Member) Responder (GCKS) 2104 -------------------- ------------------ 2105 HDR, SK{IDi, AUTH, IDg, 2106 N(PPK_IDENTITY), N(NO_PPK_AUTH)} --> 2108 Figure 22: GSA_AUTH Request using PPK 2110 If the GCKS has no such PPK and using PPK is not mandatory for it and 2111 the NO_PPK_AUTH is included, then the GCKS continues without PPK; in 2112 this case no rekey is needed: 2114 Initiator (Member) Responder (GCKS) 2115 -------------------- ------------------ 2116 <-- HDR, SK{IDr, AUTH, GSA, KD} 2118 Figure 23: GSA_AUTH Response using no PPK 2120 If the GCKS has no such PPK and either the NO_PPK_AUTH is missing or 2121 using PPK is mandatory for the GCKS, the GCKS aborts the exchange: 2123 Initiator (Member) Responder (GCKS) 2124 -------------------- ------------------ 2125 <-- HDR, SK{N(AUTHENTICATION_FAILED)} 2127 Figure 24: GSA_AUTH Error Response 2129 Assuming the GCKS has the proper PPK it continues with a request to 2130 the GM to immediately perform a rekey by sending the REKEY_IS_NEEDED 2131 notification: 2133 Initiator (Member) Responder (GCKS) 2134 -------------------- ------------------ 2135 <-- HDR, SK{IDr, AUTH, N(PPK_IDENTITY), 2136 N(REKEY_IS_NEEDED) } 2138 Figure 25: GSA_AUTH Response using PPK 2140 The GM initiates the CREATE_CHILD_SA exchange to rekey the initial 2141 IKE SA and then makes a new registration request for the same group 2142 over the new IKE SA: 2144 Initiator (Member) Responder (GCKS) 2145 -------------------- ------------------ 2146 HDR, SK{SA, Ni, KEi} --> 2147 <-- HDR, SK{SA, Nr, KEr} 2148 HDR, SK{IDg} ---> 2149 <-- HDR, SK{GSA, KD} 2151 Figure 26: Rekeying IKE SA followed by GSA_REGISTRATION Exchange 2153 5. Security Considerations 2155 5.1. GSA Registration and Secure Channel 2157 G-IKEv2 registration exchange uses IKEv2 IKE_SA_INIT protocols, 2158 inheriting all the security considerations documented in [RFC7296] 2159 section 5 Security Considerations, including authentication, 2160 confidentiality, protection against man-in-the-middle, protection 2161 against replay/reflection attacks, and denial of service protection. 2162 The GSA_AUTH and GSA_REGISTRATION exchanges also take advantage of 2163 those protections. In addition, G-IKEv2 brings in the capability to 2164 authorize a particular group member regardless of whether they have 2165 the IKEv2 credentials. 2167 5.2. GSA Maintenance Channel 2169 The GSA maintenance channel is cryptographically and integrity 2170 protected using the cryptographic algorithm and key negotiated in the 2171 GSA member registration exchanged. 2173 5.2.1. Authentication/Authorization 2175 Authentication is implicit, the public key of the identity is 2176 distributed during the registration, and the receiver of the rekey 2177 message uses that public key and identity to verify the message came 2178 from the authorized GCKS. 2180 5.2.2. Confidentiality 2182 Confidentiality is provided by distributing a confidentiality key as 2183 part of the GSA member registration exchange. 2185 5.2.3. Man-in-the-Middle Attack Protection 2187 GSA maintenance channel is integrity protected by using a digital 2188 signature. 2190 5.2.4. Replay/Reflection Attack Protection 2192 The GSA_REKEY message includes a monotonically increasing sequence 2193 number to protect against replay and reflection attacks. A group 2194 member will recognize a replayed message by comparing the Message ID 2195 number to that of the last received rekey message, any rekey message 2196 containing a Message ID number less than or equal to the last 2197 received value MUST be discarded. Implementations should keep a 2198 record of recently received GSA rekey messages for this comparison. 2200 6. IANA Considerations 2202 6.1. New Registries 2204 A new set of registries is created for G-IKEv2 on IKEv2 parameters 2205 page [IKEV2-IANA]. The terms Reserved, Expert Review and Private Use 2206 are to be applied as defined in [RFC8126]. 2208 This document creates a new IANA registry "Transform Type - 2209 Group Key Management Methods". The initial values of the new 2210 registry are: 2212 Value Group Key Management Method 2213 ------------------------------------------------------- 2214 Reserved 0 2215 Wrapped Key Download 1 2216 Unassigned 2-1023 2217 Private Use 1024-65535 2219 Changes and additions to the unassigned range of this registry are by 2220 the Expert Review Policy [RFC8126]. 2222 This document creates a new IANA registry "GSA Attributes". The 2223 initial values of the new registry are: 2225 GSA Attributes Value Type Multiple Used In 2226 --------------------------------------------------------------------- 2227 Reserved 0 2228 GSA_KEY_LIFETIME 1 V N (GIKE_REKEY, AH, ESP) 2229 GSA_INITIAL_MESSAGE_ID 2 V N (GIKE_REKEY) 2230 GSA_NEXT_SPI 3 V Y (GIKE_REKEY, AH, ESP) 2231 Unassigned 5-16383 2232 Private Use 16384-32767 2233 Changes and additions to the unassigned range of this registry are by 2234 the Expert Review Policy [RFC8126]. 2236 This document creates a new IANA registry "GAP Attributes". The 2237 initial values of the new registry are: 2239 GAP Attributes Value Type Multiple 2240 ---------------------------------------------------- 2241 Reserved 0 2242 GAP_ATD 1 B N 2243 GAP_DTD 2 B N 2244 GAP_SID_BITS 3 B N 2245 Unassigned 4-16383 2246 Private Use 16384-32767 2248 Changes and additions to the unassigned range of this registry are by 2249 the Expert Review Policy [RFC8126]. 2251 This document creates a new IANA registry "Group Key Download 2252 Attributes". The initial values of the new registry are: 2254 GKD Attributes Value Type Multiple Used In 2255 ------------------------------------------------------------ 2256 Reserved 0 2257 SA_KEY 1 V Y (GIKE_REKEY) 2258 N (AH, ESP) 2259 Unassigned 2-16383 2260 Private Use 16384-32767 2262 Changes and additions to the unassigned range of this registry are by 2263 the Expert Review Policy [RFC8126]. 2265 This document creates a new IANA registry "Member Key Download 2266 Attributes". The initial values of the new registry are: 2268 MKD Attributes Value Type Multiple 2269 ------------------------------------------------ 2270 Reserved 0 2271 KEY_WRAP_KEY 1 V Y 2272 GM_SID 2 V Y 2273 AUTH_KEY 3 V N 2274 Unassigned 4-16383 2275 Private Use 16384-32767 2277 Changes and additions to the unassigned range of this registry are by 2278 the Expert Review Policy [RFC8126]. 2280 6.2. Changes in the Existing IKEv2 Registries 2282 This document defines new Exchange Types in the "IKEv2 Exchange 2283 Types" registry: 2285 Value Exchange Type 2286 ---------------------------- 2287 39 GSA_AUTH 2288 40 GSA_REGISTRATION 2289 41 GSA_REKEY 2290 GSA_INBAND_REKEY 2292 This document defines new Payload Types in the "IKEv2 Payload Types" 2293 registry: 2295 Value Next Payload Type Notation 2296 ---------------------------------------------------- 2297 50 Group Identification IDg 2298 51 Group Security Association GSA 2299 52 Key Download KD 2301 This document defines a new Security Protocol Identifier in the 2302 "IKEv2 Security Protocol Identifiers" registry: 2304 GIKE_REKEY 2306 This document defines new Transform Types in the "Transform Type 2307 Values" registry and changes the "Used In" column for the existing 2308 allocations: 2310 Type Description Used In 2311 --------------------------------------------------------------------- 2312 1 Encryption Algorithm (ENCR) (IKE, GIKE_REKEY and ESP) 2313 2 Pseudo-random Function (PRF) (IKE, GIKE_REKEY) 2314 3 Integrity Algorithm (INTEG) (IKE, GIKE_REKEY, AH, 2315 optional in ESP) 2316 4 Diffie-Hellman Group (D-H) (IKE, optional in AH, ESP) 2317 5 Extended Sequence Numbers (ESN) (AH and ESP) 2318 Authentication Method (AUTH) (GIKE_REKEY) 2319 Group Key Management Method (GKM) (GIKE_REKEY) 2321 This document defines a new Attribute Type in the "IKEv2 Transform 2322 Attribute Types" registry: 2324 Value Attribute Type Format 2325 ---------------------------------------------- 2326 Algorithm Identifier TLV 2327 This document defines new Notify Message Types in the "Notify Message 2328 Types - Status Types" registry: 2330 Value Notify Messages - Status Types 2331 ------------------------------------------ 2332 16429 SENDER 2334 The Notify type with the value 16429 was allocated earlier in the 2335 development of G-IKEv2 document with the name SENDER_REQUEST_ID. 2336 This specification changes its name to SENDER. 2338 This document defines new Notify Message Types in the "Notify Message 2339 Types - Error Types" registry: 2341 Value Notify Messages - Error Types 2342 ----------------------------------------- 2343 45 INVALID_GROUP_ID 2344 46 AUTHORIZATION_FAILED 2345 REGISTRATION_FAILED 2347 7. Acknowledgements 2349 The authors thank Lakshminath Dondeti and Jing Xiang for first 2350 exploring the use of IKEv2 for group key management and providing the 2351 basis behind the protocol. Mike Sullenberger and Amjad Inamdar were 2352 instrumental in helping resolve many issues in several versions of 2353 the document. 2355 8. Contributors 2357 The following individuals made substantial contributions to early 2358 versions of this memo. 2360 Sheela Rowles 2361 Cisco Systems 2362 170 W. Tasman Drive 2363 San Jose, California 95134-1706 2364 USA 2366 Phone: +1-408-527-7677 2367 Email: sheela@cisco.com 2368 Aldous Yeung 2369 Cisco Systems 2370 170 W. Tasman Drive 2371 San Jose, California 95134-1706 2372 USA 2374 Phone: +1-408-853-2032 2375 Email: cyyeung@cisco.com 2377 Paulina Tran 2378 Cisco Systems 2379 170 W. Tasman Drive 2380 San Jose, California 95134-1706 2381 USA 2383 Phone: +1-408-526-8902 2384 Email: ptran@cisco.com 2386 Yoav Nir 2387 Dell EMC 2388 9 Andrei Sakharov St 2389 Haifa 3190500 2390 Israel 2392 Email: ynir.ietf@gmail.com 2394 9. References 2396 9.1. Normative References 2398 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 2399 Requirement Levels", BCP 14, RFC 2119, 2400 DOI 10.17487/RFC2119, March 1997, 2401 . 2403 [RFC2627] Wallner, D., Harder, E., and R. Agee, "Key Management for 2404 Multicast: Issues and Architectures", RFC 2627, 2405 DOI 10.17487/RFC2627, June 1999, 2406 . 2408 [RFC3740] Hardjono, T. and B. Weis, "The Multicast Group Security 2409 Architecture", RFC 3740, DOI 10.17487/RFC3740, March 2004, 2410 . 2412 [RFC4046] Baugher, M., Canetti, R., Dondeti, L., and F. Lindholm, 2413 "Multicast Security (MSEC) Group Key Management 2414 Architecture", RFC 4046, DOI 10.17487/RFC4046, April 2005, 2415 . 2417 [RFC4301] Kent, S. and K. Seo, "Security Architecture for the 2418 Internet Protocol", RFC 4301, DOI 10.17487/RFC4301, 2419 December 2005, . 2421 [RFC5280] Cooper, D., Santesson, S., Farrell, S., Boeyen, S., 2422 Housley, R., and W. Polk, "Internet X.509 Public Key 2423 Infrastructure Certificate and Certificate Revocation List 2424 (CRL) Profile", RFC 5280, DOI 10.17487/RFC5280, May 2008, 2425 . 2427 [RFC6054] McGrew, D. and B. Weis, "Using Counter Modes with 2428 Encapsulating Security Payload (ESP) and Authentication 2429 Header (AH) to Protect Group Traffic", RFC 6054, 2430 DOI 10.17487/RFC6054, November 2010, 2431 . 2433 [RFC7296] Kaufman, C., Hoffman, P., Nir, Y., Eronen, P., and T. 2434 Kivinen, "Internet Key Exchange Protocol Version 2 2435 (IKEv2)", STD 79, RFC 7296, DOI 10.17487/RFC7296, October 2436 2014, . 2438 [RFC8126] Cotton, M., Leiba, B., and T. Narten, "Guidelines for 2439 Writing an IANA Considerations Section in RFCs", BCP 26, 2440 RFC 8126, DOI 10.17487/RFC8126, June 2017, 2441 . 2443 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 2444 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, 2445 May 2017, . 2447 9.2. Informative References 2449 [I-D.ietf-ipsecme-ikev2-multiple-ke] 2450 Tjhai, C., Tomlinson, M., grbartle@cisco.com, g., Fluhrer, 2451 S., Geest, D., Garcia-Morchon, O., and V. Smyslov, 2452 "Multiple Key Exchanges in IKEv2", draft-ietf-ipsecme- 2453 ikev2-multiple-ke-00 (work in progress), January 2020. 2455 [I-D.smyslov-ipsecme-ikev2-qr-alt] 2456 Smyslov, V., "Alternative Approach for Mixing Preshared 2457 Keys in IKEv2 for Post-quantum Security", draft-smyslov- 2458 ipsecme-ikev2-qr-alt-01 (work in progress), February 2020. 2460 [IKEV2-IANA] 2461 IANA, "Internet Key Exchange Version 2 (IKEv2) 2462 Parameters", . 2465 [NNL] Naor, D., Noal, M., and J. Lotspiech, "Revocation and 2466 Tracing Schemes for Stateless Receivers", Advances in 2467 Cryptology, Crypto '01, Springer-Verlag LNCS 2139, 2001, 2468 pp. 41-62, 2001, 2469 . 2471 [OFT] McGrew, D. and A. Sherman, "Key Establishment in Large 2472 Dynamic Groups Using One-Way Function Trees", Manuscript, 2473 submitted to IEEE Transactions on Software Engineering, 2474 1998, . 2477 [RFC2409] Harkins, D. and D. Carrel, "The Internet Key Exchange 2478 (IKE)", RFC 2409, DOI 10.17487/RFC2409, November 1998, 2479 . 2481 [RFC3279] Bassham, L., Polk, W., and R. Housley, "Algorithms and 2482 Identifiers for the Internet X.509 Public Key 2483 Infrastructure Certificate and Certificate Revocation List 2484 (CRL) Profile", RFC 3279, DOI 10.17487/RFC3279, April 2485 2002, . 2487 [RFC3447] Jonsson, J. and B. Kaliski, "Public-Key Cryptography 2488 Standards (PKCS) #1: RSA Cryptography Specifications 2489 Version 2.1", RFC 3447, DOI 10.17487/RFC3447, February 2490 2003, . 2492 [RFC3686] Housley, R., "Using Advanced Encryption Standard (AES) 2493 Counter Mode With IPsec Encapsulating Security Payload 2494 (ESP)", RFC 3686, DOI 10.17487/RFC3686, January 2004, 2495 . 2497 [RFC4106] Viega, J. and D. McGrew, "The Use of Galois/Counter Mode 2498 (GCM) in IPsec Encapsulating Security Payload (ESP)", 2499 RFC 4106, DOI 10.17487/RFC4106, June 2005, 2500 . 2502 [RFC4309] Housley, R., "Using Advanced Encryption Standard (AES) CCM 2503 Mode with IPsec Encapsulating Security Payload (ESP)", 2504 RFC 4309, DOI 10.17487/RFC4309, December 2005, 2505 . 2507 [RFC4543] McGrew, D. and J. Viega, "The Use of Galois Message 2508 Authentication Code (GMAC) in IPsec ESP and AH", RFC 4543, 2509 DOI 10.17487/RFC4543, May 2006, 2510 . 2512 [RFC5374] Weis, B., Gross, G., and D. Ignjatic, "Multicast 2513 Extensions to the Security Architecture for the Internet 2514 Protocol", RFC 5374, DOI 10.17487/RFC5374, November 2008, 2515 . 2517 [RFC5480] Turner, S., Brown, D., Yiu, K., Housley, R., and T. Polk, 2518 "Elliptic Curve Cryptography Subject Public Key 2519 Information", RFC 5480, DOI 10.17487/RFC5480, March 2009, 2520 . 2522 [RFC5723] Sheffer, Y. and H. Tschofenig, "Internet Key Exchange 2523 Protocol Version 2 (IKEv2) Session Resumption", RFC 5723, 2524 DOI 10.17487/RFC5723, January 2010, 2525 . 2527 [RFC6407] Weis, B., Rowles, S., and T. Hardjono, "The Group Domain 2528 of Interpretation", RFC 6407, DOI 10.17487/RFC6407, 2529 October 2011, . 2531 [RFC6467] Kivinen, T., "Secure Password Framework for Internet Key 2532 Exchange Version 2 (IKEv2)", RFC 6467, 2533 DOI 10.17487/RFC6467, December 2011, 2534 . 2536 [RFC7383] Smyslov, V., "Internet Key Exchange Protocol Version 2 2537 (IKEv2) Message Fragmentation", RFC 7383, 2538 DOI 10.17487/RFC7383, November 2014, 2539 . 2541 [RFC7427] Kivinen, T. and J. Snyder, "Signature Authentication in 2542 the Internet Key Exchange Version 2 (IKEv2)", RFC 7427, 2543 DOI 10.17487/RFC7427, January 2015, 2544 . 2546 [RFC7634] Nir, Y., "ChaCha20, Poly1305, and Their Use in the 2547 Internet Key Exchange Protocol (IKE) and IPsec", RFC 7634, 2548 DOI 10.17487/RFC7634, August 2015, 2549 . 2551 [RFC8229] Pauly, T., Touati, S., and R. Mantha, "TCP Encapsulation 2552 of IKE and IPsec Packets", RFC 8229, DOI 10.17487/RFC8229, 2553 August 2017, . 2555 [RFC8784] Fluhrer, S., Kampanakis, P., McGrew, D., and V. Smyslov, 2556 "Mixing Preshared Keys in the Internet Key Exchange 2557 Protocol Version 2 (IKEv2) for Post-quantum Security", 2558 RFC 8784, DOI 10.17487/RFC8784, June 2020, 2559 . 2561 Appendix A. Use of LKH in G-IKEv2 2563 Section 5.4 of [RFC2627] describes the LKH architecture, and how a 2564 GCKS uses LKH to exclude group members. This section clarifies how 2565 the LKH architecture is used with G-IKEv2. 2567 A.1. Notation 2569 In this section we will use the notation X{Y} where a key with ID Y 2570 is encrypted with the key with ID X. The notation 0{Y} means that 2571 the default wrap key (SK_w) is used to encrypt key Y, and the 2572 notation X{0} means key X is used to encrypt the group SA key. Note, 2573 that 0{0} means that the group SA key is encrypted with default wrap 2574 key. 2576 The content of the KD payload will be shown as a sequence of Key 2577 Packets. The Group Key Packet substructure will be denoted as SAn(), 2578 when n is an SPI for the SA, and The Member Key Packet substructure 2579 will be denoted as GM(). The content of the Key Packets is shown as 2580 SA_KEY and KEY_WRAP_KEY attributes with the notation described above. 2581 Here is the example of KD payload. 2583 KD(SA1(X{0}),GM(Y{X},Z{Y},0{Z}) 2585 For simplicity any other attributes in the KD payload are omitted. 2587 We will also use the notation X->Y->Z to describe the Key Path, i.e. 2588 the relation between the keys. In this case the keys had the 2589 following relation: Z{Y}, Y{X}. 2591 A.2. Group Creation 2593 When a GCKS forms a group, it creates a key tree as shown in the 2594 figure below. The key tree contains logical keys (which are 2595 represented as the values of their Key IDs in the figure) and a 2596 private key shared with only a single GM (the GMs are represented as 2597 letters followed by the corresponding key ID in parentheses in the 2598 figure). The root of the tree contains the multicast rekey SA key 2599 (which is represented as SAn(0), showing that its Key ID is always 2600 zero). The figure below assumes that the Key IDs are assigned 2601 sequentially; this is not a requirement and only used for 2602 illustrative purposes. The GCKS may create a complete tree as shown, 2603 or a partial tree which is created on demand as members join the 2604 group. 2606 SA1(0) 2607 +------------------------------+ 2608 1 2 2609 +---------------+ +---------------+ 2610 3 4 5 6 2611 +-------+ +-------+ +--------+ +--------+ 2612 A(7) B(8) C(9) D(10) E(11) F(12) G(13) H(14) 2614 Figure 27: Initial LKH tree 2616 When GM A joins the group, the GCKS provides it with the keys in the 2617 KEY_WRAP_KEY attributes in the KD payload of the GSA_AUTH or 2618 GSA_REGISTRATION exchange. Given the tree shown in figure above, the 2619 KD payload will be: 2621 KD(SA1(1{0}),GM(3{1},7{3},0{7}) 2623 KD Payload for the Group Member A 2625 From these attributes the GM A will construct the Key Path 2626 0->1->3->7->0 and since it ends up with SK_w, it will use all the 2627 KEY_WRAP_KEY attributes present in the path as its working Key Path: 2628 1->3->7. 2630 Similarly, when other GMs will be joining the group they will be 2631 provided with the corresponding keys, so after all the GMs will have 2632 the following working Key Paths: 2634 A: 1->3->7 B: 1->3->8 C: 1->4->9, D: 1->4->10 2635 E: 2->5->11 F: 2->5->12 G: 2->6->13 H: 2->6->14 2637 A.3. Simple Group SA Rekey 2639 If the GCKS performs a simple SA rekey without changing group 2640 membership, it will only send Group Key Packet in the KD payload with 2641 a new SA key encrypted with the default KWK. 2643 KD(SA2(0{0})) 2645 KD Payload for the Group Member F 2647 All the GMs will be able to decrypt it and no changes in their 2648 working Key Paths will take place. 2650 A.4. Group Member Exclusion 2652 If the GKCS has reason to believe that a GM should be excluded, then 2653 it can do so by sending a GSA_REKEY message that includes a set of 2654 GM_KEY attributes which would allow all GMs except for the excluded 2655 one to get a new SA key. 2657 In the example below the GCKS excludes GM F. For this purpose it 2658 changes the key tree as follows, replacing the key 2 with the key 15 2659 and the key 5 with the key 16. It also a new SA key for a new SA3. 2661 SA3(0) 2662 +------------------------------+ 2663 1 15 2664 +---------------+ +---------------+ 2665 3 4 16 6 2666 +-------+ +-------+ +---- +--------+ 2667 A(7) B(8) C(9) D(10) E(11) F(12) G(13) H(14) 2669 Figure 28: LKH tree after F has been excluded 2671 Then it sends the following KD payload for the new rekey SA3: 2673 KD(SA3(1{0},SA3(15{0})),GM(6{15},16{15},11{16}) 2675 KD Payload for the Group Member F 2677 While processing this KD payload: 2679 o GMs A, B, C and D will be able to decrypt the SA_KEY attribute 2680 1{0} by using the "1" key from their key path. Since no new 2681 GM_KEY attributes are in the new Key Path, they won't update their 2682 working Key Paths. 2684 o GMs G and H will construct new Key Path 15->0 and will be able to 2685 decrypt the new GM_KEY 15 using the key 6 from their working Key 2686 Paths. So, they will update their working Key Paths replacing 2687 their beginnings up to the key 6 with the new Key Path (thus 2688 replacing the key 2 with the key 15). 2690 o GM E will construct new Key Path 16->15->0 and will be able to 2691 decrypt the new GM_KEY 16 using the key 11 from its working Key 2692 Path. So, it will update its working Key Path replacing its 2693 beginnings up to the key 11 with the new Key Path (thus replacing 2694 the key 2 with the key 15 and the key 5 with the key 16). 2696 o GM F won't be able to construct any Key Path leading to any key he 2697 possesses, so it will be unable to decrypt the new SA key for the 2698 SA3 and thus it will be excluded from the group once the GCKS 2699 starts sending TEK keys using SA3. 2701 Finally, the GMs will have the following working Key Paths: 2703 A: 1->3->7 B: 1->3->8 C: 1->4->9, D: 1->4->10 2704 E: 15->16->11 F: excluded G: 15->6->13 H: 15->6->14 2706 Authors' Addresses 2708 Valery Smyslov 2709 ELVIS-PLUS 2710 PO Box 81 2711 Moscow (Zelenograd) 124460 2712 Russian Federation 2714 Phone: +7 495 276 0211 2715 Email: svan@elvis.ru 2717 Brian Weis 2718 Independent 2719 USA 2721 Email: bew.stds@gmail.com