%ents; ]>
vCard4 Over XMPP This document specifies an XMPP extension for use of the vCard4 XML format in XMPP systems, with the intent of obsoleting the vcard-temp format. &LEGALNOTICE; 0292 Experimental Standards Track Standards Council XMPP Core draft-ietf-vcarddav-vcardrev draft-ietf-vcarddav-vcardxml XEP-0054 NOT_YET_ASSIGNED Samantha Mizzi samizzi@cisco.com samizzi@cisco.com &stpeter; 0.2 2011-04-07 psa

Updated to track base vCard4 specs; defined IQ transport, with pubsub for notifications; added examples for server vCards; specified mapping from vcard-temp.

0.1 2011-03-02 psa

Initial published version.

0.0.5 2011-02-28 psa

Corrected more errors in the examples.

0.0.4 2011-02-25 psa

Corrected some errors in the examples.

0.0.3 2011-02-12 psa

Third draft.

0.0.2 2011-01-31 srm

Second draft.

0.0.1 2010-11-30 srm

First draft.

Since 1999, the Jabber/XMPP community has used an interim, unofficial XML representation of vCard data for personal contacts, called &xep0054;. Recently, the IETF has upgraded vCard from vCard3 to &vcardrev;, and at the same time has defined &vcardxml; as an official XML format for vCard4. This document specifies an XMPP extension for use of the vCard4 XML format in XMPP systems, with the intent of obsoleting the vcard-temp format. Primarily this document defines the encapsulation method itself; secondarily it also defines transport methods and a mapping to the vcard-temp format for migration by clients and servers.

This specification was designed with the following requirements in mind.

  1. Reuse vCard4 as defined in draft-ietf-vcarddav-vcardrev.
  2. Reuse the vCard4 XML format as defined in draft-ietf-vcarddav-vcardxml.
  3. Ensure that clients and servers can easily migrate from vcard-temp to the new encapsulation format.
  4. Notify interested parties of changes to vCard data using standard XMPP extensions, specifically &xep0163;.
  5. Support vCards for non-human entities such as XMPP servers and &xep0045; rooms.
  6. Enable XMPP servers to store vCard4 XML data in LDAP directories if desired.

Because there is now an XML namespace for the official vCard format, we can simply re-use that namespace: "urn:ietf:params:xml:ns:vcard-4.0".

The vCard XML format defined at the IETF specifies that the root element is <vcards/>, where the only defined child element is <vcard/>. For use in XMPP, we specify that the root element shall be <vcard/>, not <vcards/>.

As in XEP-0054, the primary method for publishing and retrieving vCards is the XMPP &IQ; stanza.

An XMPP entity retrieves the vCard of another entity (or itself) by sending an IQ-get to the target entity containing a <vcard/> child element (note the lowercase "c"!) qualified by the 'urn:ietf:params:xml:ns:vcard-4.0' namespace.

]]>

If a vCard exists for the target entity, the responsible entity (e.g., the XMPP server that hosts the account for a bare JID) MUST return the data in an IQ-result:

Peter Saint-Andre Saint-Andre Peter stpeter https://stpeter.im/ 19660806 M 1 en work XMPP Standards Foundation <text>Executive Director</text> Patron Saint work Suite 600 1899 Wynkoop Street Denver CO 80202 USA home Denver CO 80210 USA work voice tel:+1-303-308-3282 home voice tel:+1-303-555-1212 stpeter@jabber.org xmpp:stpeter@jabber.org America/Denver ]]>

If no vCard exists, the server MUST return an IQ-result containing an empty <vcard/> element.

]]>

An XMPP entity publishes or updates its vCard by sending an IQ-set to itself, containing a <vcard/> child element qualified by the 'urn:ietf:params:xml:ns:vcard-4.0' namespace.

Peter Saint-Andre Saint-Andre Peter stpeter https://stpeter.im/ 19660806 M 1 en work XMPP Standards Foundation <text>Executive Director</text> Patron Saint work Suite 600 1899 Wynkoop Street Denver CO 80202 USA home Denver CO 80210 USA work voice tel:+1-303-308-3282 home voice tel:+1-303-555-1212 work stpeter@jabber.org work xmpp:stpeter@jabber.org work https://stpeter.im/index.php/contact/ America/Denver ]]>

If no error occurs, the responsible entity returns an IQ-result.

]]>

Note: An entity MAY have authorization to update the vCard of another entity (e.g., a server administrator might have authorization to modify the server's vCard).

&xep0060; provides a way to subscribe to events, and &xep0163; defines a pubsub profile for events associated with instant messaging (IM) accounts. If PEP is supported by an IM server, it can be used to automatically generate event notifications when a user's vCard is modified.

The canonical location for notifications regarding a user's vCard is a pubsub node whose name is "urn:xmpp:vcard4".

Let us imagine that Juliet wishes to receive the updates that Romeo publishes to his vCard. She has two options:

  1. Implicitly subscribe by advertising support for "urn:xmpp:vcard4+notify" in her &xep0115; data. Romeo's PEP service then automatically sends vCard updates to her when it receives presence from her, until and unless she sends presence of type unavailable or stops advertising an interest in vCard updates. This is in accordance with XEP-0060, section 6.1.
  2. Explicitly subscribe by sending a formal subscription request to the "urn:xmpp:vcard4" node at Romeo's JabberID. Romeo's PEP service may send her all vCard updates even if she is offline at the time (depending on service policies regarding presence integration).

Because Juliet has sent presence to Romeo including Entity Capabilities data that includes the "urn:xmpp:vcard4+notify" feature, Romeo's XMPP server will send a PEP notification to Juliet. The notification can include an XMPP message body for backwards-compatibility with XMPP clients that are not pubsub-capable (see Message Body). This is in accordance with XEP-0060, second 6.1.7.

]]>

Note: There is no payload, because this is a pure notification (the receiver needs to retrieve the vCard using an IQ-get as described earlier..

Traditionally, vCards have been used on the XMPP network for entities other than human users, e.g. by XMPP servers and chatrooms. When such automated entities use vCards, it is RECOMMENDED to specify a value of "thing" for the vCard4 KIND property &vcardthing;. An example follows.

jabber.org IM service http://www.jabber.org/ 1 en work xmpp@jabber.org work xmpp:stpeter@jabber.org work http://www.jabber.org/wp-content/themes/carrington-blog/images/logo.png work geo:42.25,-91.05 America/Chicago thing ]]>

The following sections mention non-obvious aspects of the migration from vcard-temp to vCard4. A future version of this specification might provide a more detailed mapping.

The vcard-temp specification defined a <JABBERID/> element:

stpeter@jabber.org ]]>

However, the JABBERID field was not part of the vCard3 schema. &rfc4770; defined an IMPP property for instant messaging and presence addresses, which was ported to vCard4. In the vCard4 XML format, the IMPP property for a JabberID would be as follows.

xmpp:stpeter@jabber.org ]]>

The vcard-temp specification defined a <DESC/> element. This element too was not part of the vCard3 schema. There is no mapping of the vcard-temp <DESC/> element to vCard4.

The vCard information published to one's XMPP server is world-readable; therefore, users should exercise due caution when determining what information to include (e.g., street addresses, personal telephone numbers, or email addresses).

This document does not require interaction with &IANA;.

The following open issues are yet to be addressed:

  1. The mapping from XEP-0054 to vCard4 is not yet specified.
  2. It would be helpful to provide an XSLT for automated translation of vcard-temp to vCard4.

Thanks to Joe Hildebrand, Waqas Hussain, and Matt Miller for their feedback.