<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE rfc [
  <!ENTITY nbsp    "&#160;">
  <!ENTITY zwsp   "&#8203;">
  <!ENTITY nbhy   "&#8209;">
  <!ENTITY wj     "&#8288;">
]>

<rfc xmlns:xi="http://www.w3.org/2001/XInclude" submissionType="IETF" category="std" consensus="true" docName="draft-ietf-regext-rdap-reverse-search-25" number="9536" ipr="trust200902" tocInclude="true" tocDepth="4" sortRefs="true" symRefs="true" updates="" obsoletes="" xml:lang="en" version="3">

  <!-- xml2rfc v2v3 conversion 3.18.0 -->
  <front>
    <title abbrev="RDAP Reverse Search">Registration Data Access Protocol (RDAP) Reverse Search</title>
    <seriesInfo name="RFC" value="9536"/>
    <author fullname="Mario Loffredo" initials="M." surname="Loffredo">
      <organization>IIT-CNR/Registro.it</organization>
      <address>
        <postal>
          <street>Via Moruzzi,1</street>
          <city>Pisa</city>
          <country>Italy</country>
          <code>56124</code>
        </postal>
        <email>mario.loffredo@iit.cnr.it</email>
        <uri>http://www.iit.cnr.it</uri>
      </address>
    </author>
    <author fullname="Maurizio Martinelli" initials="M." surname="Martinelli">
      <organization>IIT-CNR/Registro.it</organization>
      <address>
        <postal>
          <street>Via Moruzzi,1</street>
          <city>Pisa</city>
          <country>Italy</country>
          <code>56124</code>
        </postal>
        <email>maurizio.martinelli@iit.cnr.it</email>
        <uri>http://www.iit.cnr.it</uri>
      </address>
    </author>
    <date year="2024" month="April"/>
    <area>art</area>
    <workgroup>regext</workgroup>
    <keyword>RDAP</keyword>
    <keyword>Reverse search</keyword>
    <abstract>
      <t>The Registration Data Access Protocol (RDAP) does not include query capabilities for finding the list of domains related to a set of entities matching a given search pattern.  Considering that an RDAP entity can be associated with any defined object class and other relationships between RDAP object classes exist, a reverse search can be applied to other use cases besides the classic domain-entity scenario.  This document describes an RDAP extension that allows servers to provide a reverse search feature based on the relationship defined in RDAP between an object class for search and any related object class.  The reverse search based on the domain-entity relationship is treated as a particular case.</t>
    </abstract>
  </front>
  <middle>
    <section anchor="introduction">
      <name>Introduction</name>
      <t>The protocol described in this specification aims to extend the RDAP query capabilities and response to enable reverse search based on the relationships defined in RDAP between an object class for search and a related object class.  The reverse search based on the domain-entity relationship is treated as a particular case of such a generic model.</t>
      <t>RDAP providers willing to implement this specification should carefully consider its implications on the efficiency (see <xref target="impl-considerations"/>), the security (see <xref target="security-considerations"/>), and the compliance with privacy regulations (see <xref target="privacy-considerations"/>) of their RDAP service.</t>
      <section anchor="background">
        <name>Background</name>
        <t>Reverse WHOIS is a service provided by many web applications that allows users to find domain names owned by an individual or a company starting from the owner's details, such as name and email.  Even if it has been considered useful for some legal purposes (e.g., uncovering trademark infringements and detecting cybercrimes), its availability as a standardized WHOIS <xref target="RFC3912"/> capability has been objected to for two main reasons, which now don't seem to conflict with an RDAP implementation.</t>
        <t>The first objection concerns the potential risks of privacy violation.  However, the domain name community is considering a new generation of Registration Directory Services <xref target="ICANN-RDS"/> <xref target="ICANN-RA"/> that provide access to sensitive data under some permissible purposes and in accordance with appropriate policies for requestor accreditation, authentication, and authorization.  RDAP's reliance on HTTP means that it can make use of common HTTP-based approaches to authentication and authorization, making it more useful than WHOIS in the context of such directory services.  Since RDAP consequently permits a reverse search implementation complying with privacy protection principles, this first objection is not well-founded.</t>
        <t>The second objection to the implementation of a reverse search capability has been connected with its impact on server processing.  However, the core RDAP specifications already define search queries, with similar processing requirements, so the basis of this objection is not clear.</t>
        <t>Reverse searches, such as finding the list of domain names associated with contacts or nameservers, may be useful to registrars as well.  Usually, registries adopt out-of-band solutions to provide results to registrars asking for reverse searches on their domains.  Possible reasons for such requests are:</t>
        <ul spacing="normal">
          <li>the loss of synchronization between the registrar database and the registry database and
          </li>
          <li>the need for such data to perform bulk Extensible Provisioning Protocol (EPP) <xref target="RFC5730"/> updates (e.g., changing the contacts of a set of domains, etc.).</li>
        </ul>
        <t>Currently, RDAP does not provide any means for a client to search for the collection of domains associated with an entity <xref target="RFC9082"/>.  A query (lookup or search) on domains can return the array of entities related to a domain with different roles (registrant, registrar, administrative, technical, reseller, etc.), but the reverse operation is not allowed.  Only reverse searches to find the collection of domains related to a nameserver (ldhName or ip) can be requested.  Since an entity can be in relationship with any RDAP object <xref target="RFC9083"/>, the availability of a reverse search as largely intended can be common to all the object classes allowed for search.
Through a further step of generalization, the meaning of reverse search
   in the RDAP context can be extended to include any query for retrieving
   all the objects that relates to another query matching a given
   search pattern.</t>
      </section>
      <section>
        <name>Conventions Used in This Document</name>
        <t>The key words "<bcp14>MUST</bcp14>", "<bcp14>MUST NOT</bcp14>", "<bcp14>REQUIRED</bcp14>", "<bcp14>SHALL</bcp14>", "<bcp14>SHALL NOT</bcp14>", "<bcp14>SHOULD</bcp14>", "<bcp14>SHOULD NOT</bcp14>", "<bcp14>RECOMMENDED</bcp14>", "<bcp14>NOT RECOMMENDED</bcp14>", "<bcp14>MAY</bcp14>", and "<bcp14>OPTIONAL</bcp14>" 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="reverse-search-path-segment-specification">
      <name>Reverse Search Path Segment Specification</name>
      <t>A generic reverse search path is described by the syntax:</t>
      <t>{searchable-resource-type}/reverse_search/{related-resource-type}?&lt;search-condition&gt;</t>
      <t>The path segments are defined as follows:</t>
      <dl newline="false" spacing="normal">
        <dt>"searchable-resource-type":</dt>
        <dd>It <bcp14>MUST</bcp14> be one of the resource types for search defined in <xref target="RFC9082" section="3.2" sectionFormat="of" /> (i.e., "domains", "nameservers", and "entities") or a resource type extension.
        </dd>
        <dt>"related-resource-type":</dt>
        <dd>It <bcp14>MUST</bcp14> be one of the resource types for lookup defined in <xref target="RFC9082" section="3.1" sectionFormat="of" /> (i.e., "domain", "nameserver", "entity", "ip", and "autnum") or a resource type extension.
        </dd>
        <dt>"search-condition":</dt>
        <dd>A sequence of "property=search pattern" predicates separated by the ampersand character ('&amp;', US-ASCII value 0x0026).</dd>
      </dl>
      <t>While related-resource-type is defined as having one of a number of different values, the only reverse searches defined in this document are for a related-resource-type of "entity".  Reverse searches for the other resource types specified in <xref target="RFC9082"/> and resource type extensions may be defined by future documents.</t>
    </section>
    <section anchor="reverse-search-definition">
      <name>Reverse Search Definition</name>
      <t>Based on the content of <xref target="reverse-search-path-segment-specification"/>, defining a reverse search means to define the triple &lt;searchable resource type, related resource type, property&gt; and the mapping with the corresponding RDAP object member.  The mapping is done through the use of a JSONPath expression <xref target="RFC9535"/>.  Reverse searches are registered in the "RDAP Reverse Search" registry (see <xref target="rdap-reverse-search-registry"/>), whereas reverse search mappings are registered in the "RDAP Reverse Search Mapping" registry (see <xref target="rdap-reverse-search-mapping-registry"/>).  The reason for having two registries is that it may be possible for a single type of reverse search to rely on different members, depending on the server's configuration (see <xref target="reverse-search-properties-mapping"/>).</t>

      <t>All of the reverse searches defined by this document (see <xref target="reverse-search-on-entities"/>) have property names that are the same as the name of the RDAP object member that is the subject of the search.  For example, the reverse search with the property name "fn" relies on the value of the "fn" member inside the jCard of an entity object.  However, it is not necessary that these two names be the same.  In particular, remapping of searches as part of the deprecation of an existing member (see <xref target="reverse-search-properties-mapping"/>) will typically lead to a member with a different name being used for the search.</t>
      <t>Servers <bcp14>MUST NOT</bcp14> provide or implement reverse searches or reverse search mappings that are not registered with IANA.</t>
    </section>
    <section anchor="reverse-search-properties-discovery">
      <name>Reverse Search Properties Discovery</name>
      <t>Servers complying with this specification <bcp14>MUST</bcp14> extend the help response <xref target="RFC9083"/> with the "reverse_search_properties" member that contains an array of objects with the following mandatory child members:</t>
      <dl newline="false" spacing="normal">
        <dt>"searchableResourceType":</dt>
        <dd>the searchable resource type of the reverse search query, as defined in <xref target="reverse-search-path-segment-specification"/></dd>
        <dt>"relatedResourceType":</dt>
        <dd>the related resource type of the reverse search query, as defined in <xref target="reverse-search-path-segment-specification"/></dd>
        <dt>"property":</dt>
        <dd>the reverse search property used in the predicate of the reverse search query, as defined in <xref target="reverse-search-path-segment-specification"/></dd>
      </dl>
      <t>An example of the help response including the "reverse_search_properties" member is shown in <xref target="reverse-search-properties-example"/></t>
    </section>
    <section anchor="reverse-search-properties-mapping">
      <name>Reverse Search Properties Mapping</name>
      <t>To permit clients to determine the member used by the server for a reverse search, servers <bcp14>MUST</bcp14> detail the mapping that is occurring by adding the "reverse_search_properties_mapping" member to the topmost object of a reverse search response.
This data structure is included in the search response, rather
than in the help response, because it may differ depending on the query that is sent to the server.</t>
      <t>Documents that deprecate or restructure RDAP responses such that a registered reverse search is no longer able to be used <bcp14>MUST</bcp14> either note that the relevant reverse search is no longer available (in the case of deprecation) or describe how to continue supporting the relevant search by adding another mapping for the reverse search property (in the case of restructuring).</t>
      <t>The "reverse_search_properties_mapping" member contains an array of objects with the following mandatory child members:</t>
      <dl newline="false" spacing="normal">
        <dt>"property":</dt>
        <dd>the reverse search property used in the predicate of the current query, as defined in <xref target="reverse-search-path-segment-specification"/></dd>
        <dt>"propertyPath":</dt>
        <dd>the JSONPath expression of the object member (or members) corresponding to the reverse search property</dd>
      </dl>
      <t>The searchable and the related resource types are derived from the query, so there is no need to include them in addition to the property in this member.</t>
      <t>This member <bcp14>MUST</bcp14> be included for all properties used in the search, regardless of whether that property has multiple registered mappings as at the time of the search, because new mappings may be registered at any time.</t>
      <t>When applied to an object, the JSONPath expression <bcp14>MUST</bcp14> produce a list of values, each of which is a JSON number or string.</t>
      <t>An example of a reverse search response including the "reverse_search_properties_mapping" member is shown in <xref target="reverse-search-properties-mapping-example"/>.</t>
    </section>
    <section anchor="reverse-search-response-specification">
      <name>Reverse Search Response Specification</name>
      <t>Reverse search responses use the formats defined in <xref target="RFC9083" section="8" sectionFormat="of" />, which correspond to the searchable resource types defined in <xref target="reverse-search-path-segment-specification"/>.</t>
    </section>
    <section anchor="reverse-search-query-processing">
      <name>Reverse Search Query Processing</name>
      <t>To process a reverse search, the server returns the objects from its data store that are of type searchable-resource-type and that match each of the predicates from the search conditions.  To determine whether an object matches a predicate, the server:</t>
      <ul spacing="normal">
        <li>applies the mapping it uses for the reverse search property to the object in order to generate a list of values, each of which <bcp14>MUST</bcp14> be a JSON number or string and</li>
        <li>checks whether the search pattern matches one or more of those values.</li>
      </ul>
      <t>A search pattern matches a value where it equals the string representation of the value or where it is a match for the value in accordance with the partial string matching behavior defined in <xref target="RFC9082" section="4.1" sectionFormat="of" />.</t>
      <t>Objects are only included in the search results if they satisfy all included predicates.  This includes predicates that are for the same property; in such a case, it is necessary for the related object to match against each of those predicates.</t>
      <t>Servers <bcp14>MUST</bcp14> return an HTTP 501 (Not Implemented) <xref target="RFC9110"/> response to inform clients of unsupported reverse searches.</t>
      <t>Based on their policy, servers <bcp14>MAY</bcp14> restrict how predicates are used to make a valid search condition by returning a 400 (Bad Request) response when a problematic request is received.</t>
      <t>A given reverse search or reverse search mapping <bcp14>MAY</bcp14> define additional or alternative search behavior past that set out in this section.</t>
    </section>
    <section anchor="reverse-search-on-entities">
      <name>Reverse Searches Based on Entity Details</name>
      <t>Since an entity can be associated with any other object class in RDAP, the most common kind of reverse search is one based on an entity's details.  Such reverse searches arise from the query model by setting the related resource type to "entity".</t>
      <t>By selecting a specific searchable resource type, the resulting reverse search aims at retrieving all the objects (e.g., all the domains) that are related to any entity object matching the search conditions.</t>
      <t>This section defines the reverse search properties servers <bcp14>SHOULD</bcp14> support for the domain, nameserver, entity-searchable resource types, and entity-related resource type:</t>
      <dl newline="false" spacing="compact">
        <dt>Reverse search property:</dt>
        <dd>role</dd>
        <dt>RDAP member path:</dt>
        <dd>$.entities[*].roles</dd>
        <dt>Reference:</dt>
        <dd><xref target="RFC9083" section="10.2.4" sectionFormat="of" /></dd>
      </dl>
      <dl newline="false" spacing="compact">
        <dt>Reverse search property:</dt>
        <dd>handle</dd>
        <dt>RDAP member path:</dt>
        <dd>$.entities[*].handle</dd>
        <dt>Reference:</dt>
        <dd><xref target="RFC9083" section="5.1" sectionFormat="of" /></dd>
      </dl>
      <dl newline="false" spacing="compact">
        <dt>Reverse search property:</dt>
        <dd>fn</dd>
        <dt>RDAP member path:</dt>
        <dd>$.entities[*].vcardArray[1][?(@[0]=='fn')][3]</dd>
        <dt>Reference:</dt>
        <dd><xref target="RFC6350" section="6.2.1" sectionFormat="of" /></dd>
      </dl>
      <dl newline="false" spacing="compact">
        <dt>Reverse search property:</dt>
        <dd>email</dd>
        <dt>RDAP member path:</dt>
        <dd>$.entities[*].vcardArray[1][?(@[0]=='email')][3]</dd>
        <dt>Reference:</dt>
        <dd><xref target="RFC6350" section="6.4.2" sectionFormat="of" /></dd>
      </dl>    
      <t>The presence of a predicate on the reverse search property "role" means that the RDAP response property "roles" <bcp14>MUST</bcp14> contain at least the specified role.</t>
      <t>The last two properties are related to jCard elements <xref target="RFC7095"/>, but the field references are to vCard <xref target="RFC6350"/>, since jCard is the JSON format for vCard.</t>
      <t>Examples of reverse search paths based on the domain-entity relationship are presented in <xref target="reverse-search-request"/>.</t>
      <figure anchor="reverse-search-request">
        <name>Examples of Reverse Search Queries</name>
        <artwork><![CDATA[
 /domains/reverse_search/entity?handle=CID-40*&role=technical

 /domains/reverse_search/entity?fn=Bobby*&role=registrant

 /domains/reverse_search/entity?handle=RegistrarX&role=registrar
        ]]></artwork>
      </figure>
      <t>An example of the help response including the supported reverse search properties is shown in <xref target="reverse-search-properties-example"/>.</t>
      <figure anchor="reverse-search-properties-example">
        <name>An Example of the Help Response including the "reverse_search_properties" Member</name>
<sourcecode type="json"><![CDATA[
   {
     "rdapConformance": [
       "rdap_level_0",
       "reverse_search"
     ],
     ...
     "reverse_search_properties": [
       {
         "searchableResourceType": "domains",
         "relatedResourceType": "entity",
         "property": "fn"
       },
       {
         "searchableResourceType": "domains",
         "relatedResourceType": "entity",
         "property": "handle"
       },
       {
         "searchableResourceType": "domains",
         "relatedResourceType": "entity",
         "property": "email"
       },
       {
         "searchableResourceType": "domains",
         "relatedResourceType": "entity",
         "property": "role"
       }
     ],
     ...
   }
   ]]></sourcecode>
      </figure>
      <t>An example of a response including the mapping that is occurring for the first reverse search in <xref target="reverse-search-request"/> is shown below.</t>
      <figure anchor="reverse-search-properties-mapping-example">
        <name>An Example of an RDAP Response including the "reverse_search_properties_mapping" Member</name>
<sourcecode type="json"><![CDATA[
   {
     "rdapConformance": [
       "rdap_level_0",
       "reverse_search"
     ],
     ...
     "reverse_search_properties_mapping": [
       {
         "property": "handle",
         "propertyPath": "$.entities[*].handle"
       },
       {
         "property": "role",
         "propertyPath": "$.entities[*].roles"
       }
     ],
     ...
   }
   ]]></sourcecode>
      </figure>
    </section>
    <section anchor="rdap-conformance">
      <name>RDAP Conformance</name>     
      <t>Servers complying with this specification <bcp14>MUST</bcp14> include the value "reverse_search" in the rdapConformance property of the help response <xref target="RFC9083"/> and any other response including the "reverse_search_properties_mapping" member.  The information needed to register this value in the "RDAP Extensions" registry is described in <xref target="rdap-extensions-registry"/>.</t>
    </section>
    <section anchor="impl-considerations">
      <name>Implementation Considerations</name>
      <t>To limit the impact of processing the search predicates, servers are <bcp14>RECOMMENDED</bcp14> to make use of techniques to speed up the data retrieval in their underlying data store, such as indexes or similar.  In addition, risks with respect to performance degradation or result set generation can be mitigated by adopting practices used for standard searches, e.g., restricting the search functionality, limiting the rate of search requests according to the user's authorization, truncating and paging the results <xref target="RFC8977"/>, and returning partial responses <xref target="RFC8982"/>.</t>
    </section>
    <section>
      <name>IANA Considerations</name>
      <section anchor="rdap-extensions-registry">
        <name>RDAP Extensions Registry</name>
        <t>IANA has registered the following value in the "RDAP Extensions" registry:</t>
        <dl spacing="normal">
          <dt>Extension Identifier:</dt> <dd>reverse_search</dd>
          <dt>Registry Operator:</dt> <dd>Any</dd>
          <dt>Specification:</dt> <dd>RFC 9536</dd>
          <dt>Contact:</dt> <dd>IETF &lt;iesg@ietf.org&gt;</dd>
          <dt>Intended Usage:</dt> <dd>This extension identifier is used for both URI path segments and response extensions related to the reverse search in RDAP.</dd>
        </dl>
      </section>
      <section anchor="rdap-reverse-search-registries">
        <name>RDAP Reverse Search Registries</name>
        <section anchor="rdap-reverse-search-registries-creation">
          <name>Creation of the RDAP Reverse Search Registries</name>
          <t>IANA has created the "RDAP Reverse Search" and "RDAP Reverse Search Mapping" registries within the "Registration Data Access Protocol (RDAP)" category in the protocol registries.
	  </t>
          <t>These registries follow the Specification Required registration policy, as defined in <xref target="RFC8126" section="4.6" sectionFormat="of" />.</t>
          <t>The designated expert should prevent collisions and confirm that suitable documentation, as described in <xref target="RFC8126" section="4.5" sectionFormat="of" />, is available to ensure interoperability.</t>
          <t>Creators of either new RDAP reverse searches or new mappings for registered reverse searches <bcp14>SHOULD NOT</bcp14> replicate functionality already available by way of other documents referenced in these registries.  Creators <bcp14>MAY</bcp14> register additional reverse search mappings for existing properties, but they <bcp14>SHOULD NOT</bcp14> map a registered reverse search property to a response field with a meaning other than that of the response fields referenced by the mappings already registered for that property.  In other words, all the mappings for a reverse search property <bcp14>MUST</bcp14> point to response fields with the same meaning.</t>
        </section>
        <section>
          <name>Submit Requests to IANA</name>
          <t>Registration requests can be sent to &lt;iana@iana.org&gt;.</t>
        </section>
        <section anchor="rdap-reverse-search-registry">
          <name>RDAP Reverse Search Registry</name>
          <section anchor="rdap-reverse-search-registry-template">
            <name>Template</name>
            <dl newline="false" spacing="normal">
              <dt>Property:</dt>
              <dd>The name of the reverse search property.</dd>
              <dt>Description:</dt>
              <dd>A brief human-readable text describing the reverse search property.</dd>	      
              <dt>Searchable Resource Type:</dt>
              <dd>The searchable resource type of the reverse search query (<xref target="reverse-search-path-segment-specification"/>) including the reverse search property.  Multiple reverse search properties differing only by this field can be grouped together by listing all the searchable resource types separated by comma (see <xref target="rdap-reverse-search-registry-initial-content"/>).</dd>
              <dt>Related Resource Type:</dt>
              <dd>The related resource type of the reverse search query (<xref target="reverse-search-path-segment-specification"/>) including the reverse search property.</dd>
              <dt>Registrant:</dt>
              <dd>The name of the person registering the reverse search property.</dd>
              <dt>Contact Information:</dt>
              <dd>An email address, postal address, or some other information to be used to contact the registrant.</dd>
              <dt>Reference:</dt>
              <dd>Document (e.g., the RFC number) and section reference where the reverse search property is specified.</dd>
            </dl>
            <t>The combination of Searchable Resource Type, Related Resource Type, and Property <bcp14>MUST</bcp14> be unique across the registry entries.</t>
          </section>

	  <section anchor="rdap-reverse-search-registry-initial-content">
            <name>Initial Content</name>
            <t>IANA has registered the following entries in the "RDAP Reverse Search" registry.  For all entries, the common values are shown in <xref target="table1"/>, whereas the specific values are shown in <xref target="table2"/>.</t>
            <table anchor="table1">
              <name>Common Values for All Entries in the RDAP Reverse Search Registry</name>
              <thead>
                <tr>
                  <th align="left">Registry Property</th>
                  <th align="left">Value</th>
                </tr>
              </thead>
              <tbody>
                <tr>
                  <td align="left">Searchable Resource Type</td>
                  <td align="left">domains, nameservers, entities</td>
                </tr>
                <tr>
                  <td align="left">Related Resource Type</td>
                  <td align="left">entity</td>
                </tr>
                <tr>
                  <td align="left">Registrant</td>
                  <td align="left">IETF</td>
                </tr>
                <tr>
                  <td align="left">Contact Information</td>
                  <td align="left">iesg@ietf.org</td>
                </tr>
                <tr>
                  <td align="left">Reference</td>
                  <td align="left">RFC 9536</td>
                </tr>
              </tbody>
            </table>
            <table anchor="table2">
              <name>Specific Values for Entries in the RDAP Reverse Search Registry</name>
              <thead>
                <tr>
                  <th align="left">Property</th>
                  <th align="left">Description</th>
                </tr>
              </thead>
              <tbody>
                <tr>
                  <td align="left">fn</td>
                  <td align="left">The server supports the domain/nameserver/entity search based on the full name (a.k.a. formatted name) of an associated entity</td>
                </tr>
                <tr>
                  <td align="left">handle</td>
                  <td align="left">The server supports the domain/nameserver/entity search based on the handle of an associated entity</td>
                </tr>
                <tr>
                  <td align="left">email</td>
                  <td align="left">The server supports the domain/nameserver/entity search based on the email address of an associated entity</td>
                </tr>
                <tr>
                  <td align="left">role</td>
                  <td align="left">The server supports the domain/nameserver/entity search based on the role of an associated entity</td>
                </tr>
              </tbody>
            </table>
          </section>
        </section>
        <section anchor="rdap-reverse-search-mapping-registry">
          <name>RDAP Reverse Search Mapping Registry</name>
          <section anchor="rdap-reverse-search-mapping-registry-template">
            <name>Template</name>
            <dl newline="false" spacing="normal">
              <dt>Property:</dt>
              <dd>The same as defined in the "RDAP Reverse Search" registry.</dd>
              <dt>Property Path:</dt>
              <dd>The JSONPath of the RDAP property this reverse search property maps to.</dd>	      
              <dt>Searchable Resource Type:</dt>
              <dd>The same as defined in the "RDAP Reverse Search" registry.</dd>
              <dt>Related Resource Type:</dt>
              <dd>The same as defined in the "RDAP Reverse Search" registry.</dd>
	                    <dt>Registrant:</dt>
              <dd>The name of the person registering this reverse search property mapping.</dd>
              <dt>Contact Information:</dt>
              <dd>The same as defined in the "RDAP Reverse Search" registry.</dd>
              <dt>Reference:</dt>
              <dd>Document (e.g., the RFC number) and section reference where this reverse search property mapping is specified.</dd>
            </dl>
            <t>The combination of Searchable Resource Type, Related Resource Type, Property, and Property Path <bcp14>MUST</bcp14> be unique across the registry entries.</t>
          </section>
          <section anchor="rdap-reverse-search-mapping-registry-initial-content">
            <name>Initial Content</name>
            <t>IANA has registered the following entries in the "RDAP Reverse Search Mapping" registry. For all entries, the common values are the same as defined in the "RDAP Reverse Search" registry (see <xref target="table1"/>), whereas the specific values are shown below (see <xref target="table3"/>).</t>
            <table anchor="table3">
              <name>Specific Values for Entries in the RDAP Reverse Search Mapping Registry</name>
              <thead>
                <tr>
                  <th align="left">Property</th>
                  <th align="left">Property Path</th>
                </tr>
              </thead>
              <tbody>
                <tr>
                  <td align="left">fn</td>
                  <td align="left">$.entities[*].vcardArray[1][?(@[0]=='fn')][3]</td>
                </tr>
                <tr>
                  <td align="left">handle</td>
                  <td align="left">$.entities[*].handle</td>
                </tr>
                <tr>
                  <td align="left">email</td>
                  <td align="left">$.entities[*].vcardArray[1][?(@[0]=='email')][3]</td>
                </tr>
                <tr>
                  <td align="left">role</td>
                  <td align="left">$.entities[*].roles</td>
                </tr>
              </tbody>
            </table>
          </section>
        </section>
      </section>
    </section>
    <section anchor="privacy-considerations">
      <name>Privacy Considerations</name>
      <t>The search functionality defined in this document may affect the privacy of entities in the registry (and elsewhere) in various ways; see <xref target="RFC6973"/> for a general treatment of privacy in protocol specifications.  Registry operators should be aware of the trade-offs that result from implementing this functionality.</t>
      <t>Many jurisdictions have laws or regulations that restrict the use of "personal data", per the definition in <xref target="RFC6973"/>.  Given that, registry operators should ascertain whether the regulatory environment in which they operate permits implementation of the functionality defined in this document.</t>
      <t>In those cases where this functionality makes use of sensitive information, the information <bcp14>MUST</bcp14> only be accessible to authorized users under a lawful basis.</t>
      <t>Since reverse search requests and responses could contain Personally Identifiable Information (PII), reverse search functionality <bcp14>MUST</bcp14> be available over HTTPS only.</t>
      <t>Providing reverse search in RDAP carries the following threats as described in <xref target="RFC6973"/>:</t>
      <ul spacing="normal">
        <li>Correlation</li>
        <li>Disclosure</li>
        <li>Misuse of data</li>
      </ul>
      <t>Therefore, RDAP providers need to mitigate the risk of those threats by implementing appropriate measures supported by security services (see <xref target="security-considerations"/>).</t>
    </section>
    <section anchor="security-considerations">
      <name>Security Considerations</name>
      <t>Security services that are required to provide controlled access to the operations specified in this document are described in <xref target="RFC7481"/>.  A non-exhaustive list of access control paradigms an RDAP provider can implement is presented in <xref target="access-control-paradigms"/>.</t>
      <t>As an additional measure to enforce security by preventing reverse searches to be accessed from unauthorized users, the RDAP providers may consider physically separating the reverse search endpoints from the other ones by configuring a proxy routing the reverse searches to a dedicated backend server and leveraging further security services offered by other protocol layers, such as digital certificates and IP allow-listing.</t>
      <t>Finally, the specification of the relationship within the reverse search path allows the RDAP servers to implement different authorization policies on a per-relationship basis.</t>
    </section>
  </middle>
  <back>
    <references>
      <name>References</name>
      <references>
        <name>Normative References</name>

        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.2119.xml"/>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.6350.xml"/>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.7095.xml"/>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.7481.xml"/>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8126.xml"/>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8174.xml"/>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.9082.xml"/>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.9083.xml"/>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.9110.xml"/>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.9535.xml"/>
	
      </references>
      <references>
        <name>Informative References</name>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.3912.xml"/>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.5730.xml"/>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.6973.xml"/>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8977.xml"/>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8982.xml"/>

        <reference anchor="ICANN-RA" target="https://www.icann.org/en/registry-agreements/base-agreement">
          <front>
            <title>Base Registry Agreement</title>
            <author>
              <organization>ICANN</organization>
            </author>
	    <date month="January" year="2024"/>
          </front>
        </reference>

        <reference anchor="ICANN-RDS" target="https://www.icann.org/en/system/files/files/final-report-06jun14-en.pdf">
          <front>
            <title>Final Report from the Expert Working Group on gTLD Directory Services: A Next-Generation Registration Directory Service (RDS)</title>
            <author>
              <organization>ICANN</organization>
            </author>
            <date year="2014" month="June"/>
          </front>
        </reference>

        <reference anchor="OIDCC" target="http://openid.net/specs/openid-connect-core-1_0.html">
          <front>
            <title>OpenID Connect Core 1.0 incorporating errata set 2</title>
            <author initials="N" surname="Sakimura">
            </author>
	    <author initials="J" surname="Bradley">
	    </author>
	    <author initials="M" surname="Jones">
	    </author>
	    <author initials="B" surname="de Medeiros">
	    </author>
	    <author initials="C" surname="Mortimore">
            </author>
            <date month="December" year="2023"/>
          </front>
        </reference>
      </references>
    </references>
    <section anchor="access-control-paradigms">
      <name>Paradigms to Enforce Access Control on Reverse Search in RDAP</name>
      <t>Access control can be implemented according to different paradigms introducing increasingly stringent rules.  The paradigms listed below leverage the capabilities that are either built in or provided as extensions by the OpenID Connect <xref target="OIDCC"/>:</t>
      <dl spacing="normal">
        <dt>Role-Based Access Control (RBAC):</dt> <dd>Access rights are granted depending on roles.  Generally, this is done by grouping users into fixed categories and assigning static grants to each category.  A more dynamic approach can be implemented by using the OpenID Connect "scope" claim.</dd>
        <dt>Purpose-Based Access Control (PBAC):</dt> <dd>Access rules are based on the notion of purpose, being the intended use of some data by a user.  It can be implemented by tagging a request with the usage purpose and making the RDAP server check the compliance between the given purpose and the control rules applied to the data to be returned.</dd>
        <dt>Attribute-Based Access Control (ABAC):</dt> <dd>Rules to manage access rights are evaluated and applied according to specific attributes describing the context within which data are requested.  It can be implemented within an out-of-band process by setting additional OpenID Connect claims that describe the request context and make the RDAP server check for compliance between the given context and the control rules that are applied to the data to be returned.</dd>
        <dt>Time-Based Access Control (TBAC):</dt> <dd>Data access is allowed for a limited time only.  It can be implemented by assigning users temporary credentials linked to access grants with limited scopes.</dd>
      </dl>
      <t>With regard to the privacy threats reported in <xref target="privacy-considerations"/>, correlation and disclosure can be mitigated by minimizing both the request features and the response data based on user roles (i.e., RBAC).  Misuse can be mitigated by checking for the purpose of the request (i.e., PBAC).  It can be accomplished according to the following approaches:</t>
      <dl spacing="normal">
        <dt>Full Trust:</dt> <dd>The registry trusts the fairness of an accredited user.  The requestor is always legitimized to submit their requests under a lawful basis. Additionally, they can be required to specify the purpose as either a claim of their account or a query parameter.  In the former case, the purpose is assumed to be the same for every request.  In the latter case, the purpose must be one of those associated to the user.</dd>
        <dt>Zero Trust:</dt> <dd>The registry requires documents that assess whether the requestor is legitimized to submit a given request.  It can be implemented by assigning the requestor a temporary OpenID account linked to the given request (i.e., TBAC) and describing the request through a set of claims (i.e., ABAC).  The association between the temporary account and the claims about the request is made by an out-of-band application.  In so doing, the RDAP server is able to check that the incoming request is consistent with the request claims linked to the temporary account.</dd>
      </dl>
      <t>The two approaches can be used together:</t>
      <ul spacing="normal">
        <li>The former is suitable for users carrying out a task in the public interest or exercising their official authority (e.g., an officer of a cybercrime agency).  Similarly, registrars can submit reverse searches on their domains and contacts based on their contractual relationship with the domain holders.  In this case, the query results can be restricted to those pertaining to a registrar by adding an implicit predicate to the search condition.
        </li>
        <li>The latter can be taken to allow domain name dispute resolution service providers to request information in defense of the legitimate interests of complainants.</li>
      </ul>
    </section>
    <section numbered="false">
      <name>Acknowledgements</name>
      <t>The authors would like to acknowledge the following individuals for their contributions to this document: <contact fullname="Francesco Donini"/>, <contact fullname="Scott Hollenbeck"/>, <contact fullname="Francisco Arias"/>, <contact fullname="Gustavo Lozano"/>, <contact fullname="Eduardo Alvarez"/>, <contact fullname="Ulrich Wisser"/>, <contact fullname="James Gould"/>, and <contact fullname="Pawel Kowalik"/>.</t>
      <t><contact fullname="Tom Harrison"/> and <contact fullname="Jasdip Singh"/> provided relevant feedback and constant support to the implementation of this proposal.  Their contributions have been greatly appreciated.</t>
    </section>
  </back>
</rfc>
