<?xml version="1.0" encoding="US-ASCII"?>
<?xml-stylesheet type='text/xsl' href='./rfc2629.xslt' ?>

<!DOCTYPE rfc SYSTEM "rfc2629.dtd" [
<!ENTITY rfc2119 SYSTEM "http://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.2119.xml">
<!ENTITY rfc7296 SYSTEM "http://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.7296.xml">
<!ENTITY rfc7427 SYSTEM "http://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.7427.xml">
<!ENTITY rfc8032 SYSTEM "http://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8032.xml">
<!ENTITY rfc8174 SYSTEM "http://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8174.xml">
<!ENTITY rfc8410 SYSTEM "http://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8410.xml">
]>

<?rfc toc="yes"?>
<?rfc symrefs="yes"?>
<?rfc compact="yes" ?>
<?rfc subcompact="no" ?>
<?rfc sortrefs="yes" ?>

<rfc number="8420" ipr="trust200902" category="std" submissionType="IETF" consensus="yes">
  <front>
    <title abbrev="EdDSA in IKEv2">Using the Edwards-Curve Digital Signature
    Algorithm (EdDSA) in the Internet Key Exchange Protocol Version 2 (IKEv2)
</title>
    <author initials="Y." surname="Nir" fullname="Yoav Nir">
      <organization >Dell EMC</organization>
      <address>
        <postal>
          <street>9 Andrei Sakharov St</street>
          <city>Haifa</city>
          <code>3190500</code>
          <country>Israel</country>
        </postal>
        <email>ynir.ietf@gmail.com</email>
      </address>
    </author>

    <date month="August" year="2018"/>

    <area>Security</area>
    <workgroup>IPSecME Working Group</workgroup>

    <abstract>
      <t> This document describes the use of the Edwards-curve Digital 
        Signature Algorithm (EdDSA) in the Internet Key Exchange Protocol Version 2 (IKEv2).
</t>
    </abstract>
  </front>

  <middle>

    <!-- ================================================================= -->

    <section anchor="introduction" title="Introduction">
      <t> The Internet Key Exchange Protocol Version 2 <xref target="RFC7296" /> can use 
        arbitrary signature algorithms as described in 
        <xref target="RFC7427" />.  <xref target="RFC7427" /> defines the 
        SIGNATURE_HASH_ALGORITHMS notification where each side of the IKE 
        negotiation lists its supported hash algorithms. This assumes that all 
        signature schemes involve a hashing phase followed by a signature 
        phase. This made sense because most signature algorithms either cannot 
        sign messages bigger than their key or truncate messages bigger than 
        their key.</t>
      <t> EdDSA <xref target="RFC8032" /> defines signature methods that do 
        not require prehashing of the message. Unlike other methods, these 
        accept messages of arbitrary size, so no prehashing is required. These 
        methods are called Ed25519 and Ed448; they use the 
        Edwards 25519 and the Edwards 448 ("Goldilocks") curves,
	respectively. 


Although that 
document also defines prehashed versions of these algorithms, those 
versions are not recommended for protocols where there is minimal
burden in buffering the entire message so as to make it practical to make two
passes over the message.
This is true of IKEv2.

See Section 8.5 of <xref
	target="RFC8032" />
        for that recommendation.</t>

      <t> EdDSA defines the binary format of the signatures that should be used 
        in the "Signature Value" field of the Authentication Data Format in 
        Section 3 of RFC 8032. 


<xref target="RFC8410"/>
        defines the object identifiers (OIDs) for these signature methods. For 
        convenience, these OIDs are repeated in <xref target="the_oids"/>.</t>
      <t> In order to signal within IKE that no hashing needs to be done, we 
        define a new value in the SIGNATURE_HASH_ALGORITHMS notification to
        indicate that no hashing is performed.</t> 
      <section anchor="mustshouldmay" title="Conventions Used in This Document">

        <t>
    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&nbsp;14 <xref target="RFC2119"/> <xref target="RFC8174"/> 
    when, and only when, they appear in all capitals, as shown here.
        </t>


      </section>
    </section>
    <section anchor="identity" title='The "Identity" Hash Identifier'>
      <t> This document defines a new value called "Identity" (5) in 
        the "IKEv2 Hash Algorithms" registry for use in the 
        SIGNATURE_HASH_ALGORITHMS notification. Inserting this new value into 
        the notification indicates that the receiver supports at least one 
        signature algorithm that accepts messages of arbitrary size such as 
        Ed25519 and Ed448.</t>
      <t> Ed25519 and Ed448 are only defined with the "Identity" hash and MUST 
        NOT be sent to a receiver that has not indicated support for the 
        "Identity" hash.</t> 
      <t> The prehashed versions of Ed25519 and Ed448 (Ed25519ph and Ed448ph, 
        respectively) MUST NOT be used in IKE.</t>
    </section>
    <section anchor="security" title="Security Considerations">
      <t> The new "Identity" value is needed only for signature algorithms that 
        accept an input of arbitrary size. It MUST NOT be used if none of the 
        supported and configured algorithms have this property. On the other 
        hand, there is no good reason to prehash the inputs where the signature 
        algorithm has that property. For this reason, implementations MUST have 
        the "Identity" value in the SIGNATURE_HASH_ALGORITHMS notification when 
        EdDSA is supported and configured. Implementations SHOULD NOT have 
        other hash algorithms in the notification if all supported and 
        configured signature algorithms have this property.</t>
    </section>
    <section anchor="iana" title="IANA Considerations">  
      <t> IANA has assigned the value 5 for the algorithm with the name 
        "Identity" in the "IKEv2 Hash Algorithms" registry with this document
        as reference.</t>
    </section>
  </middle>

  <!-- ====================================================================== -->

  <back>
    <references title="Normative References"> 

      &rfc2119;
      &rfc7296;
      &rfc7427;
      &rfc8032;
      &rfc8174;

<!--draft-ietf-curdle-pkix-04 now RFC 8410 -->
&rfc8410;

    </references>


    <!-- ====================================================================== -->

    <section anchor="the_oids" title="ASN.1 Objects">


      <t> <xref target="RFC8410"/> is the normative reference for the ASN.1 objects for Ed25519 and Ed448.
They are repeated below for 
        convenience.</t>

      <section anchor="oid_ed25519" title="ASN.1 Object for Ed25519">
        <t>id-Ed25519   OBJECT IDENTIFIER ::= { 1.3.101.112 }</t>
        <t>Parameters are absent. Length is 7 bytes.</t>
        <t>Binary encoding: 3005 0603 2B65 70</t>
      </section>
      <section anchor="oid_ed448" title="ASN.1 Object for Ed448">
        <t>id-Ed448     OBJECT IDENTIFIER ::= { 1.3.101.113 }</t>
        <t>Parameters are absent. Length is 7 bytes.</t>
        <t>Binary encoding: 3005 0603 2B65 71</t>
      </section>
    </section>

  </back>
</rfc>
