Internet-Draft | TODO - Abbreviation | October 2024 |
Lopez-Perez, et al. | Expires 21 April 2025 | [Page] |
This document specifies the Pre-Shared Key (PSK) authentication method for the Ephemeral Diffie-Hellman Over COSE (EDHOC) key exchange protocol. It describes the authentication processes, message flows, and security considerations of this authentication method.¶
This note is to be removed before publishing as an RFC.¶
The latest revision of this draft can be found at https://elsalopez133.github.io/draft-lopez-lake-edhoc-psk/#go.draft-lopez-lake-edhoc-psk.html. Status information for this document may be found at https://datatracker.ietf.org/doc/draft-lopez-lake-edhoc-psk/.¶
Discussion of this document takes place on the LAKE Working Group mailing list (mailto:[email protected]), which is archived at https://example.com/WG. Subscribe at https://www.ietf.org/mailman/listinfo/lake/.¶
Source for this draft and an issue tracker can be found at https://github.com/ElsaLopez133/draft-lopez-lake-psk.¶
This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79.¶
Internet-Drafts are working documents of the Internet Engineering Task Force (IETF). Note that other groups may also distribute working documents as Internet-Drafts. The list of current Internet-Drafts is at https://datatracker.ietf.org/drafts/current/.¶
Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress."¶
This Internet-Draft will expire on 21 April 2025.¶
Copyright (c) 2024 IETF Trust and the persons identified as the document authors. All rights reserved.¶
This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (https://trustee.ietf.org/license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Revised BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Revised BSD License.¶
Pre-shared key (PSK) authentication method provides a balance between security and computational efficiency. This authentication method was proposed in the first I-Ds of Ephemeral Diffie-Hellman Over COSE (EDHOC) [RFC9528], and was ruled out to speed out the development process. However, there is now a renewed effort to reintroduce PSK authentication, making this draft an update to the [RFC9528].¶
EDHOC with PSK authentication could be beneficial for existing systems where two nodes have been provided with a PSK from other parties out of band. This allows the nodes to perform ephemeral Diffie-Hellman to achieve Perfect Forward Secrecy (PFS), ensuring that past communications remain secure even if the PSK is compromised. The authentication provided by EDHOC prevents eavesdropping by on-path attackers, as they would need to be active participants in the communication to intercept and potentially tamper with the session. Examples could be Generic Bootstrapping Architecture (GBA) and Authenticated Key Management Architecture (AKMA) in mobile systems, or Peer and Authenticator in EAP.¶
Another prominent use case of PSK authentication in the EDHOC protocol is session resumption. This allows previously connected parties to quickly reestablish secure communication using pre-shared keys from their earlier session, reducing the overhead of full key exchange. This efficiency is beneficial in scenarios where frequent key updates are needed, such in resource-constrained environments or applications requiring high-frequency secure communications. The use of PSK authentication in EDHOC ensures that session key can be refreshed without heavy computational overhead, typically associated with public key operations, thus optimizing both performance and security.¶
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all capitals, as shown here.¶
In this method, the Pre-Shared Key identifier (ID_CRED_PSK) is sent in message_3. The ID_CRED_PSK allows retrieval of CRED_PSK, a COSE object that contains the PSK. Through this document we will refer to the Pre-Shared Key authentication method as EDHOC-PSK.¶
Initiator and Responder are assumed to have a PSK with good amount of randomness and the requirements that:¶
Only the Initiator and the Responder have access to the PSK.¶
The Responder is able to retrieve the PSK using ID_CRED_PSK.¶
where:¶
ID_CRED_PSK is a COSE header map containing header parameters that can identify a pre-shared key. For example:¶
ID_CRED_PSK = {4 : h'lf' }¶
CRED_PSK is a COSE_Key compatible credential, encoded as a CCS or CWT. For example:¶
{ /CCS/ 2 : "mydotbot", /sub/ 8 : { /cnf/ 1 : { /COSE_Key/ 1 : 4, /kty/ 2 : h'32', /kid/ -1 : h'50930FF462A77A3540CF546325DEA214' /k/ } } }¶
The purpose of ID_CRED_PSK is to facilitate the retrieval of the PSK. It is RECOMMENDED that it uniquely identifies the CRED_PSK as the recipient might otherwise have to try several keys. If ID_CRED_PSK contains a single 'kid' parameter, then the compact encoding is applied; see Section 3.5.3.2 of [RFC9528]. The authentication credential CRED_PSK substitutes CRED_I and CRED_R specified in [RFC9529], and, when applicable, MUST follow the same guidelines described in Sections 3.5.2 and 3.5.3 of [RFC9528].¶
The ID_CRED_PSK is sent in message_3, encrypted using a key derived from the ephemeral shared secret, G_XY. The Responder authenticates the Initiator first. Figure 1 shows the message flow of PSK authentication method.¶
This approach provides protection against passive attackers for both Initiator and Responder. message_4 remains optional, but is needed to to authenticate the Responder and achieve mutual authentication in EDHOC if not relaying on external applications, such as OSCORE. With this fourth message, the protocol achieves both explicit key confirmation and mutual authentication.¶
The pseudorandom keys (PRKs) used for PSK authentication method in EDHOC are derived using EDHOC_Extract, as done in [RFC9528].¶
PRK = EDHOC_Extract( salt, IKM )¶
where the salt and input keying material (IKM) are defined for each key. The definition of EDHOC_Extract depends on the EDHOC hash algorithm selected in the cipher suite.¶
Figure 2 lists the key derivations that differ from those specified in Section 4.1.2 of [RFC9528].¶
where:¶
This section specifies the differences on the message formatting compared to [RFC9528].¶
message_2 SHALL be a CBOR sequence, defined as:¶
message_2 = ( G_Y_CIPHERTEXT_2 : bstr, )¶
where:¶
message_3 SHALL be a CBOR Sequence, as defined below:¶
message_3 = ( CIPHERTEXT_3: bstr, )¶
where:¶
CIPHERTEXT_3 is a concatenation of two different ciphertexts:¶
CIPHERTEXT_3A is bit string calculated with a binary additive stream cipher, using a KESYSTREAM_3 generated with EDHOC_Expand and the following plaintext:¶
PLAINTEXT_3A = ( ID_CRED_PSK )¶
CIPHERTEXT_3B is a COSE_Encrypt0 object as defined in Sections 5.2 and 5.3 of [RFC9052], with the EDHOC AEAD algorithm of the selected cipher suite, using the encryption key K_3, the initialization vector IV_3 (if used by the AEAD algorithm), the parameters described in Section 5.2 of [RFC9528], plaintext PLAINTEXT_3B and the following parameters as input:¶
The Initiator computes TH_4 = H( TH_3, ID_CRED_PSK, PLAINTEXT_3, CRED_PSK ), defined in Section 5.2.¶
message_4 is mandatory and is a CBOR sequence, defined as:¶
message_4 = ( CIPHERTEXT_4 : bstr, )¶
A fourth message is mandatory for Responder's authentication. The Initiator MUST NOT persistently store PRK_out or application keys until the Initiator has verified message_4 or a message protected with a derived application key, such as an OSCORE message, from the Responder and the application has authenticated the Responder.¶
When evaluating the security considerations, it is important to differentiate between the initial handshake and session resumption phases.¶
Initial Handshake: a fresh CRED_PSK is used to establish a secure connection.¶
Session Resumption: the same PSK identifier (ID_CRED_PSK) is reused each time EDHOC is executed. While this enhances efficiency and reduces the overhead of key exchanges, it presents privacy risks if not managed properly. Over multiple resumption sessions, initiating a full EDHOC session changes the resumption PSK, resulting in a new ID_CRED_PSK. The periodic renewal of the CRED_PSK and ID_CRED_PSK helps mitigate long-term privacy risks associated with static key identifiers.¶
The current EDHOC methods protect the Initiator’s identity against active attackers and the Responder’s identity against passive attackers (See Section 9.1 of [RFC9528]). With EDHOC-PSK authentication method, both the Initiator's and Responder's identities are protected against passive attackers, but not against active attackers.¶
The current EDHOC protocol consists of three mandatory messages and an optional fourth message. In the case of EDHOC-PSK authentication method, message_4 remains optional, but mutual authentication is not guaranteed without it, or an OSCORE message or any application data that confirms that the Responder owns the PSK. Additionally, with this fourth message the protocol achieves explicit key confirmation in addition to mutual authentication.¶
For use cases involving the transmission of application data, application data can be sent concurrently with message_3, maintaining the protocol's efficiency. In applications such as EAP-EDHOC, where application data is not sent, message_4 is mandatory. Thus, EDHOC-PSK authentication method doe snot include any extra messages. Other implementations may continue using OSCORE in place of EDHOC message_4, with a required change in the protocol's language to: The Initiator SHALL NOT persistently store PRK_out or application keys until the Initiator has verified message_4 or a message protected with a derived application key, such as an OSCORE message.¶
This change ensures that key materials are only stored once their integrity and authenticity are confirmed, thereby enhancing privacy by preventing early storage of potentially compromised keys.¶
Lastly, whether the Initiator or Responder authenticates first is not relevant when using symmetric keys. This consideration was important for the privacy properties when using asymmetric authentication but is not significant in the context of symmetric key usage.¶
This document has no IANA actions.¶
TODO acknowledge.¶