<?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" ipr="trust200902" docName="draft-ietf-calext-jscontact-uid-03" submissionType="IETF" consensus="true" category="std" xml:lang="en" obsoletes="" updates="9553,9555" tocInclude="true" symRefs="true" sortRefs="true" version="3">
  <front>
    <title abbrev="JSContact: Optional UIDs">JSContact Version 2.0: Optional Unique Identifiers</title>
    <seriesInfo name="RFC" value="draft-ietf-calext-jscontact-uid-03"/>
    <author initials="R." surname="Stepanek" fullname="Robert Stepanek">
      <organization>Fastmail</organization>
      <address>
        <postal>
          <extaddr>PO Box 234</extaddr>
          <street>Collins St. West</street>
          <city>Melbourne</city>
          <region>VIC</region>
          <code>8007</code>
          <country>Australia</country>
          <region/>
        </postal>
        <email>rsto@fastmailteam.com</email>
      </address>
    </author>
    <date year="2025" month="July" day="23"/>
    <area>art</area>
    <workgroup>calext</workgroup>
    <keyword>JSContact</keyword>
    <abstract>
      <t>This document defines version "2.0" of JSContact. It redefines the previously mandatory "uid" property of a Card object to be optional, which requires the major version number of JSContact to change. Other than changing the "uid" property as outlined in this document, all other definitions of JSContact version "1.0" remain as defined in RFC 9553. In addition, this document redefines the conversion rule for the "uid" property and accordingly updates RFC 9555.</t>
    </abstract>
  </front>
  <middle>
    <section anchor="notational-conventions" numbered="true" toc="default">
      <name>Notational Conventions</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 14 <xref target="RFC2119" format="default" sectionFormat="of" derivedContent="RFC2119"/> <xref target="RFC8174" format="default" sectionFormat="of" derivedContent="RFC8174"/> when, and only when, they appear in all capitals, as shown here.</t>
      <t>The ABNF definitions in this document use the notations of <xref target="RFC5234"/>. ABNF rules not defined in this document are defined in either <xref target="RFC5234"/> (such as the ABNF for CRLF, WSP, DQUOTE, VCHAR, ALPHA, and DIGIT) or <xref target="RFC6350"/>.</t>
    </section>
    <section anchor="introduction" numbered="true" toc="default">
      <name>Introduction</name>
      <t><xref target="RFC9553"/> defines the "uid" property of a Card object, a mandatory property which contains an unique identifier for the entity represented by that contact card. This property being mandatory has shown to be applicable for some use cases, but has turned out to be an issue in other contexts.</t>
          <t>For example, the <xref target="RFC6352">CardDAV protocol</xref> requires the UID property of a <xref target="RFC6350">vCard object</xref> to be set. Accordingly, an internet server that implements both CardDAV and <xref target="RFC9610">JMAP for Contacts</xref> requires the "uid" property of a JSContact Card to be set. In contrast, protocols such as <xref target="RFC9083">RDAP</xref> have no use for the "uid" property, either because they use different identifiers, or they prefer to not include any unique identifier in the contact data at all. JSContact should not require them to generate unique identifiers that are irrelevant to their use case.</t>
          <t>Also, one of the stated goals of JSContact is to be compatible with the semantics of the vCard data format (<xref target="RFC9553" section="1"/>). But <xref target="RFC6350"/> defines the UID property of a vCard to be optional, and consequently the semantics of JSContact and vCard differ for such a crucial common element.</t>
        <t>In case of vCards without a <xref target="RFC6350" section="6.7.6" sectionFormat="parens">UID property</xref> being converted to JSContact, requiring unique identifiers is especially problematic: the Card "uid" property is mandatory and accordingly <xref target="RFC9555" section="2.1.1"/> requires implementations to generate some unique identifier for it during conversion, but it does not guarantee it to be the same across implementations or even one implementation converting the same Card multiple times. A recipient being unaware that the "uid" property value of such a Card object is ephemeral might refer to it in the "members" or "relatedTo" properties of another Card object, introducing invalid relations between contact cards.</t>
    </section>
    <section>
      <name>JSContact Version 2.0</name>
      <t>This document redefines the "uid" property of a Card object to become optional. Other than that, the property definition is left unchanged. This change requires the major version of JSContact to change, so this document defines the JSContact version to become "2.0".</t>
      <t>Implementations <bcp14>MUST</bcp14> create JSContact data according to version "2.0" and <bcp14>MUST</bcp14> set the "version" property of newly created Card objects to "2.0" (or higher). They <bcp14>MUST</bcp14> validate JSContact data according to version "2.0", that is, they <bcp14>MUST NOT</bcp14> reject a Card object without the "uid" property as invalid unless specified differently. As any version "1.0" JSContact Card also is valid according to version "2.0", there is no need to migrate existing JSContact data.</t>
      <t>If to set the "uid" property is use-case specific. If an implementation is able to consistently generate the exact same unique identifier for a JSContact Card representing the same entity and no protocol-specific concerns prevail, it is recommended to set the "uid" property.</t>
    </section>
    <section anchor="redefined-uid-property" numbered="true" toc="default">
      <name>Redefined "uid" Property</name>
      <t>This document redefines the type signature of the "uid" property, originally defined in <xref target="RFC9553" section="2.1.9"/>. The new type signature is:</t>
      <dl spacing="normal">
        <dt>
          <strong>uid: String (optional).</strong>
        </dt>
        <dd/>
      </dl>
      <t>The remaining property definition is left unchanged, with the following additional paragraph:</t>
      <t>A Card without a uid property can not be referred to as group member in the <xref target="RFC9553" section="2.1.6" sectionFormat="parens">"members" property</xref>, or put in relation to another Card object in the <xref target="RFC9553" section="2.1.8" sectionFormat="parens">"relatedTo" property</xref>.</t>
    </section>
    <section anchor="redefined-uid-property-conversion" numbered="true" toc="default">
      <name>Redefined Conversion Rule for the "uid" Property</name>
      <t>This document redefines how to convert the Card "uid" property from vCard, originally defined in <xref target="RFC9555" section="2.1.1"/>. The new conversion rule is:</t>
      <t>Implementations that convert a vCard without a <xref target="RFC6350" section="6.7.6" sectionFormat="parens">UID property</xref> to a Card of version "2.0" or higher <bcp14>MUST NOT</bcp14> generate a unique identifier as value for the <xref target="RFC9553" section="2.1.9" sectionFormat="parens">"uid" property</xref>.</t>
      <t>When converting a vCard without UID property to obsoleted JSContact version "1.0", implementations <bcp14>MUST</bcp14> generate a value for the "uid" property. Generating unique identifiers is implementation-specific. An implementation <bcp14>SHOULD</bcp14> generate the same value when generating the same Card multiple times, but <bcp14>MAY</bcp14> generate different values for each conversion. <xref target="introduction"/> describes why this is problematic. Consequently, implementations <bcp14>SHOULD NOT</bcp14> convert to version "1.0" Card objects.</t>
    </section>
    <section anchor="iana-considerations" numbered="true" toc="default">
      <name>IANA Considerations</name>
      <section>
        <name>Update to the JSContact Version Registry</name>
        <t>IANA will update the "JSContact Version" registry, originally created in <xref target="RFC9553" section="3.4"/>. It will add the following record:</t>
        <table anchor="tab-iana-version-registry" align="center">
          <name>JSContact Version Registry</name>
          <thead>
            <tr>
              <th align="left">Major Version</th>
              <th align="left">Highest Minor Version</th>
              <th align="left">Reference</th>
            </tr>
          </thead>
          <tbody>
            <tr>
              <td align="left">2</td>
              <td align="left">0</td>
              <td align="left">This document</td>
            </tr>
          </tbody>
        </table>
      </section>
      <section>
        <name>Update to the JSContact Properties Registry</name>
        <t>IANA will update the "JSContact Properties" registry, originally created in <xref target="RFC9553" section="3.5"/>: For the "Reference/Description" column of the "uid" property, it will replace the reference to <xref target="RFC9553"/> with a reference to <xref target="redefined-uid-property"/> of this document.</t>
      </section>
    </section>
    <section anchor="security-considerations" numbered="true" toc="default">
      <name>Security Considerations</name>
      <t>This document does not provide new security considerations. The security considerations of <xref target="RFC9553" section="4" sectionFormat="of"/> apply.</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.5234.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.6352.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.9083.xml"/>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.9553.xml"/>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.9555.xml"/>
        <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.9610.xml"/>
      </references>
    </references>
  </back>
</rfc>
