This JEP defines a protocol for communicating information about the current physical location of a Jabber entity.
NOTICE: This JEP is currently within Last Call or under consideration by the Jabber Council for advancement to the next stage in the JSF standards process. For further details, visit <http://www.jabber.org/council/queue.php>.
Type: Standards Track
Last Updated: 2004-10-12
JIG: Standards JIG
Approving Body: Jabber Council
Dependencies: XMPP Core, JEP-0060
Superseded By: None
Short Name: physloc
This Jabber Enhancement Proposal is copyright 1999 - 2004 by the Jabber Software Foundation (JSF) and is in full conformance with the JSF's Intellectual Property Rights Policy <http://www.jabber.org/jsf/ipr-policy.php>. This material may be distributed only subject to the terms and conditions set forth in the Open Publication License, v1.0 or later (the latest version is presently available at <http://www.opencontent.org/openpub/>).
The preferred venue for discussion of this document is the Standards-JIG discussion list: <http://mail.jabber.org/mailman/listinfo/standards-jig>.
The Extensible Messaging and Presence Protocol (XMPP) is defined in the XMPP Core and XMPP IM specifications contributed by the Jabber Software Foundation to the Internet Standards Process, which is managed by the Internet Engineering Task Force in accordance with RFC 2026. Any protocols defined in this JEP have been developed outside the Internet Standards Process and are to be understood as extensions to XMPP rather than as an evolution, development, or modification of XMPP itself.
The keywords "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 RFC 2119.
This JEP defines an extension mechanism for capturing "extended presence" information about a user's current physical location. The information structures defined herein are intended to provide a format for describing a location or address that may change fairly frequently (e.g., one's location on a campus or in a large building) in situations where the user or application does not possess, or does not wish to communicate, detailed latitude/longitude data of the type defined in User Geolocation .
Information about the user's location is provided by the user and propagated on the network by the user's client. The information is structured by means of an <physloc/> element that is qualified by the 'http://jabber.org/protocol/physloc' namespace. The location information itself is provided as the XML character data of the following children of the <physloc/> element:
|<country/>||The nation where the user is located||USA|
|<region/>||An administrative region of the nation, such as a state or province||New York|
|<locality/>||A locality within the administrative region, such as a town or city||New York City|
|<area/>||A named area such as a campus or neighborhood||Central Park|
|<street/>||A thoroughfare within the locality, or a crossing of two thoroughfares||34th and Broadway|
|<building/>||A specific building on a street or in an area||The Empire State Building|
|<floor/>||A particular floor in a building||102|
|<room/>||A particular room in a building||Observatory|
|<postalcode/>||A code used for postal delivery||10027|
|<text/>||A catch-all element that captures any other information about the user's location||Northwest corner of the lobby|
The <physloc/> information SHOULD be communicated by means of Publish-Subscribe . Because physical location information is not pure presence information and can change independently of the user's availability, it SHOULD NOT be provided as an extension to <presence/>.
<iq type='set' firstname.lastname@example.org/laptop' to='pubsub.jabber.org' id='publish1'> <pubsub xmlns='http://jabber.org/protocol/pubsub'> <publish node='generic/stpeter-loc'> <item id='current'> <physloc xmlns='http://jabber.org/protocol/physloc' xml:lang='en'> <country>Austria</country> <locality>Vienna</locality> <building>Vienna International Centre</building> <text>At IETF 57</text> </physloc> </item> </publish> </pubsub> </iq>
The location information is then delivered to all subscribers:
<message from='pubsub.jabber.org' email@example.com/silver'> <event xmlns='http://jabber.org/protocol/pubsub#event'> <items node='generic/stpeter-physloc'> <item id='current'> <physloc xmlns='http://jabber.org/protocol/physloc' xml:lang='en'> <country>Austria</country> <locality>Vienna</locality> <building>Vienna International Centre</building> <text>At IETF 57</text> </physloc> </item> </items> </event> </message> . . .
As mentioned in JEP-0060, the stanza containing the event notification or payload MAY also include 'replyto' data (as specified by the Extended Stanza Addressing  protocol) to provide an explicit association between the published data and the user:
<message from='pubsub.jabber.org' firstname.lastname@example.org/silver'> <event xmlns='http://jabber.org/protocol/pubsub#event'> <items node='generic/stpeter-physloc'> <item id='current'> <physloc xmlns='http://jabber.org/protocol/physloc' xml:lang='en'> <country>Austria</country> <locality>Vienna</locality> <building>Vienna International Centre</building> <text>At IETF 57</text> </physloc> </item> </items> </event> <addresses xmlns='http://jabber.org/protocol/address'> <address type='replyto' email@example.com'/> </addresses> </message>
There are many XML data formats for physical location or address information. It is beyond the scope of this JEP to provide a mapping from the extension defined herein to every such format. However, it would be valuable to provide a mapping from the Jabber/XMPP format to the formats used in other presence or extended presence protocols. The two main protocols of interest are:
The Wireless Village (now "IMPS") specifications for mobile instant messaging; these specifications define a presence attribute for address information as encapsulated in the IMPS "Address" element .
The SIP-based SIMPLE specifications; the IETF's GEOPRIV Working Group has defined an extension to the IETF's Presence Information Data Format (PIDF)  for location information, as specified in A Presence-based GEOPRIV Location Object Format  (also known as "PIDF-LO").
The following table also maps the format defined herein to the vCard XML format specified in vcard-temp .
|Jabber/XMPP||Wireless Village / IMPS||SIMPLE (PIDF-LO)||vCard XML|
|<region/>||--||<A1/> and/or <A2/>||<REGION/>|
|<area/>||<NamedArea/>||<A4/> and/or <A5/>||--|
|<street/>||<Street/> ||<A6/> ||<STREET/>|
Because the character data contained in most <physloc/> child elements is intended to be readable by humans, the <physloc/> element SHOULD possess an 'xml:lang' attribute specifying the natural language of such character data.
It is imperative to control access to location information, at least by default. Imagine that a stalker got unauthorized access to this information, with enough accuracy and timeliness to be able to find the target person. This scenario could lead to loss of life, so please take access control checks seriously. A user SHOULD take care in approving subscribers and in characterizing his or her current physical location.
This JEP requires no interaction with the Internet Assigned Numbers Authority (IANA) .
Upon advancement of this proposal to a status of Draft, the Jabber Registrar  shall add the 'http://jabber.org/protocol/physloc' namespace to its registry of protocol namespaces.
<?xml version='1.0' encoding='UTF-8'?> <xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' targetNamespace='http://jabber.org/protocol/physloc' xmlns='http://jabber.org/protocol/physloc' elementFormDefault='qualified'> <xs:element name='physloc'> <xs:complexType> <xs:sequence minOccurs='0'> <xs:element name='country' minOccurs='0' type='xs:string'/> <xs:element name='region' minOccurs='0' type='xs:string'/> <xs:element name='locality' minOccurs='0' type='xs:string'/> <xs:element name='area' minOccurs='0' type='xs:string'/> <xs:element name='street' minOccurs='0' type='xs:string'/> <xs:element name='building' minOccurs='0' type='xs:string'/> <xs:element name='floor' minOccurs='0' type='xs:string'/> <xs:element name='room' minOccurs='0' type='xs:string'/> <xs:element name='text' minOccurs='0' type='xs:string'/> <xs:element name='url' minOccurs='0' type='xs:string'/> </xs:sequence> </xs:complexType> </xs:element> </xs:schema>
1. JEP-0080: User Geolocation <http://www.jabber.org/jeps/jep-0080.html>.
2. JEP-0060: Publish-Subscribe <http://www.jabber.org/jeps/jep-0060.html>.
3. JEP-0033: Extended Stanza Addressing <http://www.jabber.org/jeps/jep-0033.html>.
4. The Wireless Village Initiative: Presence Attributes v1.1 (WV-029); for further information, visit <http://www.openmobilealliance.org/tech/affiliates/wv/wvindex.html>.
5. RFC 3863: Presence Information Data Format (PIDF) <http://www.ietf.org/rfc/rfc3863.txt>.
6. A Presence-based GEOPRIV Location Object Format <http://www.ietf.org/internet-drafts/draft-ietf-geopriv-pidf-lo-03.txt>.
7. JEP-0054: vcard-temp <http://www.jabber.org/jeps/jep-0054.html>.
8. As noted in JEP-0054, the XML vCard format defined in draft-dawson-vcard-xml-dtd-01 specified a <COUNTRY/> element rather than a <CTRY/> element; refer to JEP-0054 for details.
9. The IMPS specification also enables one to define an intersection (e.g., "Broadway and 34th Street") as the combination of a <Crossing1/> element (e.g., "Broadway") and a <Crossing2/> element (e.g., "34th Street"). To map from IMPS to Jabber, an application SHOULD map such a combination to one Jabber/XMPP <street/> element.
10. The PIDF-LO format provides information elements for much more granular control over a traditional street address; in PIDF-LO the <A6/> element is the street name only, and further information is provided in distinct elements for a leading street direction (e.g., "N"), trailing street suffix (e.g., "SW"), street suffix (e.g., "Avenue"), house number (e.g., "909"), and house number suffix (e.g., "1/2"). To map from PIDF-LO to Jabber, an application SHOULD construct the complete street address from the PIDF-LO elements (<A6/>, <PRD/>, <POD/>, <STS/>, <HNO/>, and <HNS/>) and map the result to one Jabber/XMPP <street/> element.
11. This element provides accuracy in meters. The geolocation protocol defined in JEP-0080 specifies such an element for Jabber/XMPP, which SHOULD be used when mapping from IMPS to Jabber.
12. This element provides a name for the location, e.g., a certain store in a building. This SHOULD be mapped to the Jabber/XMPP <text/> element.
13. The Internet Assigned Numbers Authority (IANA) is the central coordinator for the assignment of unique parameter values for Internet protocols, such as port numbers and URI schemes. For further information, see <http://www.iana.org/>.
14. The Jabber Registrar maintains a list of reserved Jabber protocol namespaces as well as registries of parameters used in the context of protocols approved by the Jabber Software Foundation. For further information, see <http://www.jabber.org/registrar/>.