<?xml version="1.0" encoding="us-ascii"?>
<!DOCTYPE rfc SYSTEM "rfc2629.dtd"
[

<!ENTITY RFC2119 SYSTEM "http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.2119.xml">
<!ENTITY RFC3688 SYSTEM "http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.3688.xml">
<!ENTITY RFC5731 SYSTEM "http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.5731.xml">
<!ENTITY RFC7451 SYSTEM "http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.7451.xml">
<!ENTITY RFC8590 SYSTEM "http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.8590.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 comments="yes" ?>
<?rfc inline="yes" ?>

<rfc category="exp" docName="draft-regext-brown-epp-ttl-01"
  ipr="trust200902" submissionType="independent">

  <front>
    <title abbrev="TTL Mapping for EPP">Extensible Provisioning
    Protocol (EPP) Mapping for DNS Time-To-Live (TTL) values</title>

    <author fullname="Gavin Brown" initials="G" surname="Brown">
      <organization>CentralNic Group plc</organization>
      <address>
        <postal>
        <street>44 Gutter Lane</street>
        <city>London</city>
        <code>EC2V 6BR</code>
        <country>GB</country>
        </postal>
        <phone>+44 20 33 88 0600</phone>
        <email>gavin.brown@centralnic.com</email>
        <uri>https://www.centralnic.com</uri>
      </address>
    </author>
    <date month="September" year="2022" day="14" />
    <area>Applications</area>
    <workgroup> Registration Protocols Extensions (regext) </workgroup>

    <abstract><t>This document describes an extension to the Extensible Provisioning Protcol (EPP) that allows EPP clients to manage the Time-To-Live (TTL) value for domain name delegation records.</t></abstract>
  </front>

  <middle>
    <section title="Introduction">

<t>The principal output of any domain name provisioning system is a DNS zone file, which contains the delegation record(s) for names registered within the zone. These records include, at minimum, one or more <spanx style="verb">NS</spanx> records, but may also include <spanx style="verb">A</spanx> and/or <spanx style="verb">AAAA</spanx> glue records, and <spanx style="verb">DS</spanx> records.</t>

<t>Typically, the Time-To-Live (TTL) of these records is determined by the registry operator. However, in some circumstances it may be desirable to allow the sponsoring registrar of a domain name to change the TTL used for a particular domain: for example, to reduce the amount of time required to complete a change of DNS servers, or a DNSSEC key rollover.</t>

<t>This document describes an EPP extension to the domain name object mapping (described in <xref target="RFC5731"/>) which allows the sponsor of a domain name object to change the TTL associated with a given domain.</t>

      <section title="Conventions Used in This Document">
        <t>The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL
        NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and
        "OPTIONAL" in this document are to be interpreted as described
        in <xref target="RFC2119"/>.</t>

		<t>

   In examples, "C:" represents lines sent by a protocol client and "S:"
   represents lines returned by a protocol server.  Indentation and
   white space in examples are provided only to illustrate element
   relationships and are not REQUIRED features of this protocol.  A
   protocol client that is authorized to manage an existing object is
   described as a "sponsoring" client throughout this document.</t>

   <t>
   XML is case sensitive.  Unless stated otherwise, XML specifications
   and examples provided in this document MUST be interpreted in the
   character case presented in order to develop a conforming
   implementation.</t>
      </section>

    </section>

  <section title="Extension Elements">
    <t>This specification defines a single new element, <spanx style="verb">&lt;ttl:secs&gt;</spanx>, which contains a 32-bit unsigned integer indicating the TTL which will be applied to the delegation records for the associated domain name.</t>
	<t>Example:</t>
	<figure><artwork>&lt;ttl xmlns="urn:ietf:params:xml:ns:ttl-1.0"&gt;3600&lt;/ttl&gt;</artwork></figure>
  </section>

  <section title="EPP Command Mapping">
    <section title="EPP Query Commands">
      <section title="EPP &lt;info&gt; Command">

          <t>This extension defines additional elements EPP <spanx style="verb">&lt;info&gt;</spanx> responses.</t>

          <t>The <spanx style="verb">&lt;info&gt;</spanx> response MAY contain an <spanx style="verb">&lt;extension&gt;</spanx>; element which MAY
          contain a <spanx style="verb">&lt;ttl:infData&gt;</spanx> element. This element contains a single <spanx style="verb">&lt;ttl:secs&gt;</spanx> element.</t>

        <t>Example <spanx style="verb">&lt;info&gt;</spanx> response:</t><figure><artwork>
S: &lt;?xml version="1.0" encoding="utf-8" standalone="no"?&gt;
S: &lt;epp xmlns="urn:ietf:params:xml:ns:epp-1.0"&gt;
S:   &lt;response&gt;
S:     &lt;result code="1000"&gt;
S:       &lt;msg&gt;Command completed successfully&lt;/msg&gt;
S:     &lt;/result&gt;
S:     &lt;resData&gt;
S:       &lt;domain:infData
S:         xmlns:domain="urn:ietf:params:xml:ns:domain-1.0"&gt;
S:         &lt;domain:name&gt;example.com&lt;/domain:name&gt;
S:         &lt;domain:roid&gt;EXAMPLE1-REP&lt;/domain:roid&gt;
S:         &lt;domain:status s="ok" /&gt;
S:         &lt;domain:registrant&gt;jd1234&lt;/domain:registrant&gt;
S:         &lt;domain:contact type="admin"&gt;sh8013&lt;/domain:contact&gt;
S:         &lt;domain:contact type="tech"&gt;sh8013&lt;/domain:contact&gt;
S:         &lt;domain:ns&gt;
S:           &lt;domain:hostObj&gt;ns1.example.com&lt;/domain:hostObj&gt;
S:           &lt;domain:hostObj&gt;ns1.example.net&lt;/domain:hostObj&gt;
S:         &lt;/domain:ns&gt;
S:         &lt;domain:clID&gt;ClientX&lt;/domain:clID&gt;
S:         &lt;domain:crID&gt;ClientY&lt;/domain:crID&gt;
S:         &lt;domain:crDate&gt;1999-04-03T22:00:00.0Z&lt;/domain:crDate&gt;
S:         &lt;domain:upID&gt;ClientX&lt;/domain:upID&gt;
S:         &lt;domain:upDate&gt;1999-12-03T09:00:00.0Z&lt;/domain:upDate&gt;
S:         &lt;domain:exDate&gt;2005-04-03T22:00:00.0Z&lt;/domain:exDate&gt;
S:         &lt;domain:trDate&gt;2000-04-08T09:00:00.0Z&lt;/domain:trDate&gt;
S:         &lt;domain:authInfo&gt;
S:           &lt;domain:pw&gt;2fooBAR&lt;/domain:pw&gt;
S:         &lt;/domain:authInfo&gt;
S:       &lt;/domain:infData&gt;
S:     &lt;/resData&gt;
S:     &lt;extension&gt;
S:       &lt;ttl:infData
S:         xmlns:ttl="urn:ietf:params:xml:ns:ttl-1.0"&gt;
S:         &lt;ttl:secs&gt;3600&lt;/ttl:secs&gt;
S:       &lt;/ttl:infData&gt;
S:     &lt;/extension&gt;
S:     &lt;trID&gt;
S:       &lt;clTRID&gt;ABC-12345&lt;/clTRID&gt;
S:       &lt;svTRID&gt;54322-XYZ&lt;/svTRID&gt;
S:     &lt;/trID&gt;
S:   &lt;/response&gt;
S: &lt;/epp&gt;
</artwork></figure>

      </section>
    </section>
    <section title="EPP Transform Commands">
      <section title="EPP &lt;create&gt; Command">
          <t>This extension defines additional elements EPP <spanx style="verb">&lt;create&gt;</spanx> commands.</t>

          <t>The <spanx style="verb">&lt;create&gt;</spanx> command MAY contain an <spanx style="verb">&lt;extension&gt;</spanx> element which MAY
          contain a <spanx style="verb">&lt;ttl:create&gt;</spanx> element. This element contains a single <spanx style="verb">&lt;ttl:secs&gt;</spanx> element.</t>

	  	<t>Example <spanx style="verb">&lt;create&gt;</spanx> command:</t>

	  	<figure><artwork>C: &lt;?xml version="1.0" encoding="UTF-8" standalone="no"?&gt;
C: &lt;epp xmlns="urn:ietf:params:xml:ns:epp-1.0"&gt;
C:   &lt;command&gt;
C:     &lt;create&gt;
C:       &lt;domain:create
C:        xmlns:domain="urn:ietf:params:xml:ns:domain-1.0"&gt;
C:         &lt;domain:name&gt;example.com&lt;/domain:name&gt;
C:         &lt;domain:period unit="y"&gt;2&lt;/domain:period&gt;
C:         &lt;domain:ns&gt;
C:           &lt;domain:hostObj&gt;ns1.example.net&lt;/domain:hostObj&gt;
C:           &lt;domain:hostObj&gt;ns2.example.net&lt;/domain:hostObj&gt;
C:         &lt;/domain:ns&gt;
C:         &lt;domain:registrant&gt;jd1234&lt;/domain:registrant&gt;
C:         &lt;domain:contact type="admin"&gt;sh8013&lt;/domain:contact&gt;
C:         &lt;domain:contact type="tech"&gt;sh8013&lt;/domain:contact&gt;
C:         &lt;domain:authInfo&gt;
C:           &lt;domain:pw&gt;2fooBAR&lt;/domain:pw&gt;
C:         &lt;/domain:authInfo&gt;
C:       &lt;/domain:create&gt;
C:     &lt;/create&gt;
C:     &lt;extension&gt;
C:       &lt;ttl:create
C:         xmlns:ttl="urn:ietf:params:xml:ns:ttl-1.0"&gt;
C:         &lt;ttl:secs&gt;3600&lt;/ttl:secs&gt;
C:       &lt;/ttl:create&gt;
C:     &lt;/extension&gt;
C:     &lt;clTRID&gt;ABC-12345&lt;/clTRID&gt;
C:   &lt;/command&gt;
C: &lt;/epp&gt;</artwork></figure>

      </section>
      <section title="EPP &lt;update&gt; Command">
          <t>This extension defines additional elements EPP <spanx style="verb">&lt;update&gt;</spanx> commands.</t>

          <t>The <spanx style="verb">&lt;update&gt;</spanx> command MAY contain an <spanx style="verb">&lt;extension&gt;</spanx> element which MAY
          contain a <spanx style="verb">&lt;ttl:update&gt;</spanx> element. This element contains a single <spanx style="verb">&lt;ttl:secs&gt;</spanx> element.</t>

  	  	<t>Example <spanx style="verb">&lt;update&gt;</spanx> command:</t>
  	  	<figure><artwork>
C:&lt;?xml version="1.0" encoding="UTF-8" standalone="no"?&gt;
C:&lt;epp xmlns="urn:ietf:params:xml:ns:epp-1.0"
C:     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"&gt;
C:  &lt;command&gt;
C:    &lt;update&gt;
C:      &lt;domain:update
C:       xmlns:domain="urn:ietf:params:xml:ns:domain-1.0"&gt;
C:        &lt;domain:name&gt;example.com&lt;/domain:name&gt;
C:      &lt;/domain:update&gt;
C:    &lt;/update&gt;
C:    &lt;extension&gt;
C:       &lt;ttl:update&gt;
C:         xmlns:ttl="urn:ietf:params:xml:ns:ttl-1.0"&gt;
C:         &lt;ttl:secs&gt;3600&lt;/ttl:secs&gt;
C:       &lt;/ttl:update&gt;
C:     &lt;/extension&gt;
C:    &lt;clTRID&gt;ABC-12345&lt;/clTRID&gt;
C:  &lt;/command&gt;
C:&lt;/epp&gt;</artwork></figure>
      </section>
    </section>
  </section>

  <section title="Server Processing of TTL Values">
	  <t>EPP servers which implement this extension SHOULD use the values provided by EPP clients for the TTL values of <spanx style="verb">NS</spanx>, <spanx style="verb">A</spanx>, <spanx style="verb">AAAA</spanx> and <spanx style="verb">DS</spanx> records published in the DNS for the corresponding delegation.</t>
	  <t>If an EPP server receives a command containing a TTL that is outside the server's permitted range (see <xref target="operational-considerations" format="title" /> and <xref target="security-considerations" format="title" /> below), it MUST reject the command with a <spanx style="verb">2004</spanx> "Parameter value range error" response.</t>
  </section>

  <section title="Out-of-band changes to TTL values">
		<t>EPP server operators MAY, in order to address operational or security issues, make changes to domain TTL values out-of-band (that is, not in response to an <spanx style="verb">&lt;update&gt;</spanx> command received from the domain's sponsor).</t>
		<t>Additionally, server operators may implement an automatic reset of TTL values, so that they may be changed for a finite period before and after a planned change, and then revert to a standard value.</t>
		<t>In the event of changes to TTL values taking place out-of-band, EPP server operators SHOULD notify the sponsoring client by means of the EPP message queue and/or the EPP Change Poll Extension (<xref target="RFC8590"/>).</t>
  </section>

  <section anchor="operational-considerations" title="Operational Considerations">
	  <section title="Operational impact of TTL values">
		  <t>Domain registry operators must strike a balance between, on the one hand, the desire of registrants for changes to their domains to be visible in the DNS quickly, and the increased DNS query traffic that short TTLs can bring. Historically, registry operators specified a global TTL value that applies to all delegations within their zones, which has made it relatively easy to tune this value to an optimum value.</t>
		  <t>Domain registry operators SHOULD implement limits on the maximum and minimum TTL values (that are narrower than the values permitted in the Formal Specification, which were chosen to allow any TTL permitted in DNS records), to prevent scenarios where an excessively high or low TTL causes operational issues on either side of the zone cut.</t>
	  </section>

	  <section title="When the TTL should be changed">
		  <t>A common operational mistake is changing of DNS record TTLs during or after the planned change to the records themselves. This arises due to a misunderstanding about how TTLs work.</t>
		  <t>Client implementations of this specification SHOULD ensure that the user understands that changes to a TTL are only effective in shortening transition periods if implemented a period of time &mdash; at least equal to the current TTL &mdash; <em>before</em> the planned change.</t>
	  </section>
  </section>

  <section anchor="security-considerations" title="Security Considerations">
	  <t>Many malicious actors use a technique called "fast flux DNS" to rapidly change the DNS configuration for a zone in order to evade takedown and law enforcement activity.</t>
	  <t>Registry operators should take this into consideration when setting the lower limit on TTL values, since a short TTL on delegations has the potential to enhance the effectiveness of fast flux techniques on evasion.</t>
  </section>

  <section anchor="IANA" title="IANA Considerations">
		<section title="XML Namespace">
			<t>This document uses URNs to describe XML namespaces and XML schemas conforming to a registry mechanism described in <xref target="RFC3688"/>. The following URI assignment has been made by IANA:</t>

		   <t>Registration for the TTL namespace:</t>
			 <list>
		      <t>URI: <spanx style="verb">urn:ietf:params:xml:ns:ttl-1.0</spanx></t>

		      <t>Registrant Contact: See the author of this document</t>

		      <t>XML: None.  Namespace URIs do not represent an XML specification</t>
 			 </list>

		   <t>Registration for the TTL XML schema:</t>

			 <list>
		      <t>URI: <spanx style="verb">urn:ietf:params:xml:ns:ttl-1.0</spanx></t>

		      <t>Registrant Contact: See the author of this document</t>

		      <t>XML: See the "Formal Syntax" section of this document</t>
 			 </list>

		</section>
		<section title="EPP Extension Registry">
		   <t>The EPP extension described in this document has been registered by the IANA in the Extensions for the "Extensible Provisioning Protocol (EPP)" registry described in <xref target="RFC7451"/>. The details of the registration are as follows:</t>

			 <list>

		   <t>Name of Extension: Extensible Provisioning Protocol (EPP) Mapping for DNS Time-To-Live (TTL) values</t>

		   <t>Document Status: Experimental</t>

		   <t>Reference: URL of this document</t>

		   <t>Registrant Name and Email Address: See the author of this document</t>

		   <t>TLDs: Any</t>

		   <t>IPR Disclosure: None</t>

		   <t>Status: Active</t>

		   <t>Notes: None</t>
		 </list>
		 </section>
 		</section>

  <section title="Formal Specification">
<figure><artwork>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
&lt;schema xmlns:ttl="urn:ietf:params:xml:ns:ttl-1.0"&gt;
  &lt;annotation&gt;
    &lt;documentation&gt;
      Extensible Provisioning Protocol v1.0 domain name
      extension schema for Time-To-Live (TTL) modification
      in all DNS responses for a domain name including
      delegation (NS) records and any address (A) records.
    &lt;/documentation&gt;
  &lt;/annotation&gt;

  &lt;!-- Child elements found in EPP commands --&gt;
  &lt;element name="create" type="ttl:secs"/&gt;
  &lt;element name="update" type="ttl:secs"/&gt;

  &lt;!-- Child elements found in EPP responses --&gt;
  &lt;element name="infData" type="ttl:secs"/&gt;

  &lt;complexType name="secs"&gt;
    &lt;sequence&gt;
      &lt;element name="secs" type="ttl:nonNegativeInteger"/&gt;
    &lt;/sequence&gt;
  &lt;/complexType&gt;

  &lt;simpleType name="nonNegativeInteger"&gt;
    &lt;restriction base="nonNegativeInteger"&gt;
      &lt;minInclusive value="1"/&gt;
      &lt;maxInclusive value="4294967295"/&gt;
    &lt;/restriction&gt;
  &lt;/simpleType&gt;
&lt;/schema&gt;</artwork></figure>
  </section>

  </middle>

  <back>

    <references title="Normative References">
      &RFC2119;
			&RFC3688;
			&RFC5731;
			&RFC7451;			
      &RFC8590;
    </references>

    <!-- <references title="Informative References">
    </references> -->

  </back>
</rfc>
