<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE rfc [
<!ENTITY RFC2119 SYSTEM "https://bib.ietf.org/public/rfc/bibxml/reference.RFC.2119.xml">
<!ENTITY RFC8174 SYSTEM "https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8174.xml">
<!ENTITY RFC9083 SYSTEM "https://bib.ietf.org/public/rfc/bibxml/reference.RFC.9083.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 xmlns:xi="http://www.w3.org/2001/XInclude" category="std" docName="draft-brown-rdap-ttl-extension-01" ipr="trust200902" submissionType="IETF" consensus="true">
  <front>
    <title abbrev="RDAP TTL Extension">RDAP Extension for DNS Time-To-Live (TTL Values)</title>
    <author initials="G." surname="Brown" fullname="Gavin Brown">
      <organization>ICANN</organization>
      <address>
        <postal>
          <street>12025 Waterfront Drive, Suite 300</street>
          <city>Los Angeles</city>
          <code>90094-2536</code>
          <country>US</country>
          <region>CA</region>
        </postal>
        <email>gavin.brown@icann.org</email>
      </address>
    </author>
    <date/>
    <area>Internet</area>
    <workgroup>Registration Extensions (REGEXT)</workgroup>
    <abstract>
      <t>
This document describes an extension to the Registration Data Access Protocol (<xref target="RFC9083"/>) which allows the Time-To-Live (TTL) values for relevant DNS record types to be included in RDAP responses.
</t>
    </abstract>
    <note title="About this draft" removeInRFC="true">
      <t>
The source for this draft, and an issue tracker, may can be found at <eref target="https://github.com/gbxyz/rdap-ttl-extension"/>.
</t>
    </note>
  </front>
  <middle>
    <section anchor="introduction">
      <name>Introduction</name>
      <t>
While <xref target="RFC9083"/> allows RDAP server operators to provide information about the content of the <tt>NS</tt>, <tt>DS</tt>, <tt>A</tt> and <tt>AAAA</tt> record(s) which are published in the DNS for a given registry object (domain or host object), it does not provide a mechanism to allow the Time-To-Live (TTL) values of those records to be included in responses.
</t>
      <t>
This document describes how TTL information can be included in domain and nameserver objects in RDAP responses.
</t>
      <t>
This document is complementary to the EPP TTL extension (<xref target="I-D.ietf-regext-epp-ttl"/>), but registry operators do not need to implement that extension in their EPP server in order to implement this RDAP extension.
</t>
    </section>
    <section>
      <name>Conventions used in this document</name>
      <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 anchor="rdap-response-specification">
      <name>RDAP Response Specification</name>
      <t>
Servers which support this extension <bcp14>MUST</bcp14> include a <tt>ttl</tt> property in any domain and nameserver objects included in RDAP responses.
</t>
      <t>
The <tt>ttl</tt> property is an array of objects.
These objects have the following properties:
</t>
      <ul>
        <li>A <tt>types</tt> property, which is an array of DNS record type mnemonics;</li>
        <li>A <tt>value</tt> property, which is an unsigned integer indicated the TTL value for those DNS record types;</li>
        <li>An <bcp14>OPTIONAL</bcp14> <tt>remarks</tt> property, which is an array of remarks (see <xref section="4.3" sectionFormat="of" target="RFC9083"/>); and</li>
        <li>An <bcp14>OPTIONAL</bcp14> <tt>events</tt> property, which is an array of events (see <xref section="4.5" sectionFormat="of" target="RFC9083"/>).</li>
      </ul>
      <t>DNS record type mnemonics <bcp14>MUST</bcp14> be in all capitals. Each DNS record type <bcp14>MUST</bcp14> only appear once in a response.</t>
      <t>TTL values MUST be unsigned integers in the range 0-2,147,483,647.</t>
      <t>
Example domain object:
</t>
      <sourcecode><![CDATA[{
  "objectClassName": "domain",
  "ldhName": "example.com",
  "ttl": [
    {
      "types": [
        "NS"
      ],
      "value": 3600,
      "remarks": [
        {
          "description": [
            "The .example registry does not permit NS record TTL ",
            "values to be changed."
          ]
        }
      ]
    },
    {
      "types": [
        "DS"
      ],
      "value": 300,
      "events": [
        {
          "eventAction": "last updated",
          "eventActor": "example-registry",
          "eventDate": "2024-01-08T13:52:18Z"
        }
      ],
      "remarks": [
        {
          "description": [
            "For more information about the .example registry policy "
            "relating to DS record TTL changes, see https://example.com"
          ],
          "links": [
            {
              "rel": "related",
              "title": ".Example Registry DNS TTL Policy",
              "value": "https://example.com",
              "href": "https://example.com"
            }
          ]
        }
      ]
    }
  ]
}
]]></sourcecode>
      <t>
Example nameserver object:
</t>
      <sourcecode><![CDATA[{
  "objectClassName": "nameserver",
  "ldhName": "ns1.example.com",
  "ttl": [
    {
      "types": [
        "A",
        "AAAA"
      ],
      "value": 86400,
      "remarks": [
        {
          "description": [
            "The .example registry does not permit TTL ",
            "values for nameservers to be changed."
          ]
        }
      ]
    }
  ]
}
]]></sourcecode>
      <section anchor="rdap-conformance">
        <name>RDAP Conformance</name>
        <t>
Servers returning responses containing TTL values <bcp14>MUST</bcp14> include the string "<tt>ttl</tt>" in the <tt>rdapConformance</tt> array.
</t>
      </section>
    </section>
    <section anchor="iana-considerations">
      <name>IANA Considerations</name>
      <t>
IANA is requested to register the following value in the RDAP Extensions Registry:
</t>
      <t>
        <strong>Extension identifier:</strong>
        <tt>ttl</tt>
      </t>
      <t><strong>Registry operator:</strong> Any
</t>
      <t><strong>Published specification:</strong> this document
</t>
      <t><strong>Contact:</strong> IETF &lt;<eref target="mailto:iesg@ietf.org">iesg@ietf.org</eref>&gt;
</t>
      <t><strong>Intended usage:</strong> this extension describes how DNS TTL values can be included in RDAP responses.
</t>
    </section>
    <section anchor="changes">
      <name>Change Log</name>
      <section>
        <name>Changes from 00 to 01</name>
        <ol>
          <li>Extension property name renamed to <tt>ttl</tt>.</li>
          <li>The extension data structure is now an array allowing common TTL values, remarks and events to be mapped to multiple DNS record types.</li>
          <li>The extension data structure may now include remarks and events.</li>
          <li>Added normative text regarding the value of DNS record mnemonics and TTL values.</li>
        </ol>
      </section>
    </section>
  </middle>
  <back>
    <references><name>Normative References</name>
    &RFC2119;
    &RFC8174;
    &RFC9083;
  </references>
    <references>
      <name>Informative References</name>
      <reference anchor="I-D.ietf-regext-epp-ttl" target="https://datatracker.ietf.org/api/v1/doc/document/draft-ietf-regext-epp-ttl/">
        <front>
          <title>Extensible Provisioning Protocol (EPP) mapping for DNS Time-To-Live (TTL) values</title>
          <author fullname="Gavin Brown"/>
          <date day="24" month="June" year="2024"/>
        </front>
        <seriesInfo name="Internet-Draft" value="draft-ietf-regext-epp-ttl-14"/>
      </reference>
    </references>
  </back>
</rfc>
