<?xml version="1.0" encoding="US-ASCII"?>
<!DOCTYPE rfc SYSTEM "rfc2629.dtd" [
<!ENTITY RFC2119 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.2119.xml">
<!ENTITY RFC4034 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.4034.xml">
<!ENTITY RFC5890 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.5890.xml">
<!ENTITY RFC6698 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.6698.xml">
<!ENTITY RFC6982 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.6982.xml">
<!ENTITY RFC7296 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.7296.xml">
<!ENTITY RFC8174 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.8174.xml">
<!ENTITY RFC7942 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.7942.xml">
]>
<?xml-stylesheet type='text/xsl' href='rfc2629.xslt' ?>
<?rfc strict="yes" ?>
<?rfc toc="yes"?>
<?rfc tocdepth="4"?>
<?rfc symrefs="yes"?>
<?rfc sortrefs="yes" ?>
<?rfc compact="yes" ?>
<?rfc subcompact="no" ?>
<rfc ipr="trust200902" updates="" obsoletes="" category="std" docName="draft-pwouters-ipsecme-child-pfs-info-00">
  <front>
    <title>IKEv2 support for Child SA PFS policy notification</title>
    <author initials="P." surname="Wouters" fullname="Paul Wouters">
      <organization>Aiven</organization>
      <address>
        <email>paul.wouters@aiven.io</email>
      </address>
    </author>
    <date/>
    <area>General</area>
    <workgroup>Network</workgroup>
    <keyword>IKEv2</keyword>
    <keyword>IPsec</keyword>
    <abstract>
      <t>
       This document defines the CHILD_PFS_INFO Notify Message Status Type Payload
       for the Internet Key Exchange Protocol Version 2 (IKEv2) to support exchanging
       the policy for the Perfect Forward Secrecy (PFS) and Key Exchange (KE) method
       setting of the initial Child SA.
      </t>
    </abstract>
  </front>
  <middle>
    <section title="Introduction">
      <t>
       The IKEv2 <xref target="RFC7296"/> protocol uses the Keying Exchange (KE)
       payload, formerly known as the Diffie-Hellman Group Transform payload
       to create an ephemeral IKE connection. During an IKE rekey, a new KE payload
       is used to create a new ephemeral IKE connection, resulting in Perfect
       Forward Secrecy (PFS).</t>
      <t>
       A Child SA optionally uses its own PFS settings by including its own KE
       payload and list of acceptable Keying Exchange methods. During Child SA
       rekeys, KE payloads of acceptable eying Exchange methods are exchanged to
       create PFS.</t>
      <t>The Initial Exchanges establish both an IKE SA and a Child SA using the
       Keying Exchange method negotiated for the IKE SA. Thus, after the Initial
       Exchange, the peers are not aware of each others PFS requirements for the
       existing Child SA. It is common practise to either not do PFS for Child SAs,
       or to only use the same KE methods for both the IKE SA and all Child SAs.
       But it is currently not possible to know this when the initial Child SA
       is established. The peers find out about this problem only at the next
       Child SA rekey, which is typically 1 to 8 hours later. </t>
      <t>
       This document introduces the CHILD_PFS_INFO Notify payload to exchange
       this information during the Initial Exchanges</t> 

      <section title="Requirements Language">
        <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
       14 <xref target="RFC2119"/> <xref target="RFC8174"/> when, and only
       when, they appear in all capitals, as shown here.
      </t>
      </section>
    <section title="Payload Format" anchor="payload_formats">
      <t>
      All multi-octet fields representing integers are laid out in big
      endian order (also known as "most significant byte first", or
      "network byte order").
     </t>
    </section>
    </section>
      <section title="CHILD_PFS_INFO Notify Status Message Payload" anchor="child_pfs_notify_payload">
        <figure align="center">
          <artwork align="left"><![CDATA[
                    1                   2                   3
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
+-+-----------------------------+-------------------------------+
! Next Payload  !C!  RESERVED   !         Payload Length        !
+---------------+---------------+-------------------------------+
!  Protocol ID  !   SPI Size    !      Notify Message Type      !
+---------------+---------------+-------------------------------+
~ Key Eexchange methods list (KE list)                          ~
+-------------------------------+-------------------------------+
            ]]></artwork>
        </figure>
        <t>
          <list style="symbols">
            <t>Protocol ID (1 octet) - MUST be 0. MUST be ignored if not 0.</t>
            <t>SPI Size (1 octet) - MUST be 0. MUST be ignored if not 0.</t>
            <t>Notify Status Message Type (2 octets) - set to [TBD1]</t>
            <t>list of one or more Key Exchange Methods</t>
          </list>
        </t>
      <t>The Key Exchange method list (KE list) contains KE values from the IANA
         "Transform Type 4 - Key Exchange Method Transform IDs" registry.
         Each entry is two octets. If the KE list payload is a not a multiple of
         two, the entire payload MUST be ignored.</t>
      </section>

    <section title="Usage of the CHILD_PFS_INFO Notify" anchor="usage">
    <t>The CHILD_PFS_INFO Notify payload is only sent during the IKE_AUTH
       Exchange that also contains the Key Exchange Method (KE) transform type.
       This is typically the last (or only) IKE_AUTH Exchange. When creating
       additional Child SA's using the CREATE_CHILD_SA Exchange, the Exchange
       already contains an optional KE payload and list of Key Exchange Method
       Transform IDs. When rekeying such existing additional Child SA, a proper KE value (NONE
       or otherwise) is already learned from the initial establishment of the Child SA during
       the initial CREATE_CHILD_SA Exchange and no CHILD_PFS_INFO is required.</t>
    <t>If PFS is completely disallowed, the KE list contains only the value 0 (NONE). If
       PFS is optional but allowed, the KE list contains the value 0 (NONE) as
       well as the other accepted values, eg 19 for "256-bit random ECP group".</t>
    <t>Unknown KE list entries MUST be ignored.</t>
    <t>A peer MUST return NO_PROPOSAL_CHOSEN if the CHILD_PFS_NOTIFY values
       received does not include an acceptable value that can be used for
       the KE payload and Transform Type 4 during a Child SA rekey. This ensures that
       incomptabile peers will immediately fail the initial negotiation.</t>
      </section>

    <section title="Operational Considerations" anchor="ops_consider">
      <t>
       This document is a result of Operational Considers that have shown peers can run
       into broken IPsec connections at rekey time. These are not obvious to the administrators
       as these usually do not sit around for a few hours to wait and see if the rekey process
       worked successfully. The CHILD_PFS_INFO results in immediate negotiation failure that
       can be repaired before taking the IPsec connection into production.
      </t>
      <t>
       During rekey, the cryptographic strength of a rekeyed Child SA SHOULD remain
       at least as strong as the Child SA being rekeyed. In practise this means the
       negotiated algorithms remain the same. But some deployments use stronger
       settings for the IKE SA compared to its Child SAs, which means technically
       the initial Child SA uses a stronger KE method than for rekeys. The CHILD_PFS_INFO
       payload exposes such settings to the peers during the Initial Exchanges, and peers
       can at that time accept or reject the child proposal. Once the Initial Child SA
       containing CHILD_PFS_INFO is accepted, rekey proposals are guaranteed to be acceptable
       to both parties. For example, an IKE SA could be using KE method 15 (3072-bit MODP)
       and specify in the CHILD_PFS_INFO that it accepts KE method 14 (2048-bit MODP) for
       this Child SA rekey.</t>

      <t>
      Deployments with a large number of Child SAs often use no PFS for their Child SAs. It
      is computationally much cheaper to establish the large number of Child SAs and then
      immediately rekey the IKE SA. This method can also be used if the peer's Child SA KE
      methods are unacceptable. If both peers accept the KE method of 0 (NONE), it can decide
      to rekey the Child SA without PFS and immediately rekey the IKE SA using its accepted KE
      method.
      </t>
    </section>

    <section title="Security Considerations" anchor="sec_consider">
      <t>
       This document introduces no new security considerations, as it only causes an
       increased awareness of peer capabilities with respect to KE methods.
      </t>
    </section>
    <section title="Implementation Status" anchor="impl_status">
      <t>
      [Note to RFC Editor: Please remove this section and the reference to
      <xref target="RFC6982"/> before publication.]
     </t>
      <t>
      This section records the status of known implementations of the
      protocol defined by this specification at the time of posting of
      this Internet-Draft, and is based on a proposal described in
      <xref target="RFC7942"/>. The description of implementations in this
      section is intended to assist the IETF in its decision processes
      in progressing drafts to RFCs. Please note that the listing of
      any individual implementation here does not imply endorsement
      by the IETF. Furthermore, no effort has been spent to verify the
      information presented here that was supplied by IETF contributors.
      This is not intended as, and must not be construed to be, a catalog
      of available implementations or their features. Readers are advised
      to note that other implementations may exist.
     </t>
      <t>
      According to <xref target="RFC7942"/>, "this will allow reviewers
      and working groups to assign due consideration to documents that
      have the benefit of running code, which may serve as evidence of
      valuable experimentation and feedback that have made the implemented
      protocols more mature.  It is up to the individual working groups
      to use this information as they see fit".
     </t>
      <t>
      Authors are requested to add a note to the RFC Editor at the
      top of this section, advising the Editor to remove the entire
      section before publication, as well as the reference to <xref target="RFC7942"/>.
     </t>
      <section anchor="section.impl-status.libreswan" title="Libreswan">
        <t>
          <list style="hanging">
            <t hangText="Organization: ">The Libreswan Project</t>
            <t hangText="Name: ">https://libreswan.org/</t>
            <t hangText="Description: ">
           An initial IKE implementation using the Private Use value 40961 for the Notify payload</t>
            <t hangText="Level of maturity: ">Beta</t>
            <t hangText="Coverage: ">Implements the draft's example reasons</t>
            <t hangText="Licensing: ">GPLv2</t>
            <t hangText="Implementation experience: ">TBD</t>
            <t hangText="Contact: ">Libreswan Development: swan-dev@libreswan.org</t>
          </list>
        </t>
      </section>
     </section>
    <section anchor="IANA" title="IANA Considerations">
      <t>
        This document defines one new IKEv2 Notify Message Type payload for the IANA "IKEv2 Notify Message Types - Status Types" registry.
        </t>
      <figure align="center" anchor="iana_requests_i">
        <artwork align="left"><![CDATA[
      Value   Notify Type Messages - Status Types    Reference
      -----   ------------------------------    ---------------
      [TBD1]   CHILD_PFS_INFO                    [this document]
            ]]></artwork>
      </figure>
    </section>
  </middle>
  <back>
    <references title="Normative References">
     &RFC2119;
     &RFC7296;
     &RFC8174;
    </references>
    <references title="Informative References">
     &RFC6982;
     &RFC7942;
    </references>
  </back>
</rfc>
