geopriv
GEOPRIV                                                          R. Mahy
Internet-Draft                                               Plantronics
Intended status: Standards Track                           B. Rosen Rosen, Ed.
Expires: May 7, 2009 January 14, 2010                                        NeuStar
                                                        November 3, 2008
                                                           H. Tschofenig
                                                  Nokia Siemens Networks
                                                           July 13, 2009

 A Document Format for Filtering and Reporting Location Notications in
   the Presence Information Document Format Location Object (PIDF-LO)
                   draft-ietf-geopriv-loc-filters-03
                 draft-ietf-geopriv-loc-filters-04.txt

Status of this Memo

   By submitting this Internet-Draft, each author represents that any
   applicable patent or other IPR claims of which he or she

   This Internet-Draft is aware
   have been or will be disclosed, and any of which he or she becomes
   aware will be disclosed, submitted to IETF in accordance full conformance with Section 6 the
   provisions of BCP 78 and BCP 79.

   Internet-Drafts are working documents of the Internet Engineering
   Task Force (IETF), its areas, and its working groups.  Note that
   other groups may also distribute working documents as Internet-
   Drafts.

   Internet-Drafts are draft documents valid for a maximum of six months
   and may be updated, replaced, or obsoleted by other documents at any
   time.  It is inappropriate to use Internet-Drafts as reference
   material or to cite them other than as "work in progress."

   The list of current Internet-Drafts can be accessed at
   http://www.ietf.org/ietf/1id-abstracts.txt.

   The list of Internet-Draft Shadow Directories can be accessed at
   http://www.ietf.org/shadow.html.

   This Internet-Draft will expire on May 7, 2009. January 14, 2010.

Copyright Notice

   Copyright (c) 2009 IETF Trust and the persons identified as the
   document authors.  All rights reserved.

   This document is subject to BCP 78 and the IETF Trust's Legal
   Provisions Relating to IETF Documents in effect on the date of
   publication of this document (http://trustee.ietf.org/license-info).
   Please review these documents carefully, as they describe your rights
   and restrictions with respect to this document.

Abstract

   This document describes filters which that limit asynchronous location
   notifications to compelling events. events, designed as an extension to RFC
   4661 "An XML-Based Format for Event Notification Filtering".  The
   resulting location information is conveyed in existing location
   formats wrapped in
   GEOPRIV privacy extensions to the Presence Information Document Format (PIDF-LO)
   (PIDF-LO).

Table of Contents

   1.  Conventions  Terminology  . . . . . . . . . . . . . . . . . . . . . . . . .  3
   2.  Overview  Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . .  3  4
   3.  Definition of Location  Filter Format Definitions . . . . . . . . . . . . .  3 . . . . . . . . .  5
     3.1.  Horizontal and Vertical Movement . . . . . . . . . . . . .  4  5
     3.2.  Changes in value Speed . . . . . . . . . . . . . . . . . . . . .  5
     3.3.  Containment Within a Region  . . . .  Changes in Value . . . . . . . . . . .  6
     3.4.  Rate Control . . . . . . . . . .  6
     3.4.  Enter or Exit a Region . . . . . . . . . . . . .  9
     3.5.  XML Schema for filter format . . . . .  7
   4.  Rate Control . . . . . . . . . .  9
   4.  Containment schema . . . . . . . . . . . . . . .  9
   5.  XML Schema . . . . . . . 12
   5.  Security Considerations . . . . . . . . . . . . . . . . . . . 15 10
   6.  IANA  Security Considerations  . . . . . . . . . . . . . . . . . . . 11
   7.  IANA Considerations  . . 16
     6.1.  MIME Registration for
           application/location-delta-filter+xml  . . . . . . . . . . 16
     6.2.  URN Sub-Namespace Registration for
           urn:ietf:params:xml:ns:location-filter . . . . . . . . . . 16
     6.3.  Schema Registration For location-filter 12
     7.1.  Content-type registration for
           'application/location-delta-filter+xml'  . . . . . . . . . 17
     6.4. 12
     7.2.  URN Sub-Namespace Registration for
           urn:ietf:params:xml:ns:pidf:geopriv10:containment
           urn:ietf:params:xml:ns:location-filter . . . . 17
     6.5. . . . . . . 13
     7.3.  Schema Registration For containment  . . location-filter  . . . . . . . . . 18
   7. 14
   8.  Acknowledgments  . . . . . . . . . . . . . . . . . . . . . . . 18
   8. 15
   9.  References . . . . . . . . . . . . . . . . . . . . . . . . . . 18
     8.1. 16
     9.1.  Normative References . . . . . . . . . . . . . . . . . . . 18
     8.2. 16
     9.2.  Informational References . . . . . . . . . . . . . . . . . 19 17
   Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . . 19
   Intellectual Property and Copyright Statements . . . . . . . . . . 21 18

1.  Conventions  Terminology

   The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
   "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
   document are to be interpreted as described in RFC-2119 RFC 2119 [RFC2119].

2.  Overview  Introduction

   Conveying static location in PIDF-LO [RFC4119] bodies is
   straightforward.  However the difficult part about asynchronous described in
   [I-D.ietf-sip-location-conveyance].  Asynchronous notification of
   location information is that unfortunately more complex since many forms
   of location are measured as a continuous gradient.  Unlike
   notifications using
   discreet discret quantities, it is difficult to know when
   a change in location is large enough to warrant a notification.  Moreover,
   different applications require a wide variety of location
   resolutions.  Any optimization made for one application would
   ultimately result in wasteful polling or a sluggish user interface
   for other applications.  The
   mechanism described here in this document defines filters in XML [W3C.REC-xml]
   documents as an extension
   to RFC 4661 [RFC4661], which limit limits location notification to events which
   that are of relevance to the subscriber.  These filters persist until
   they are changed with a replacement filter.

   In addition to the relevant filters, this document also defines a new
   XML schema [W3C.REC-xmlschema-1] which can be included in PIDF-LO
   documents to indicate that the resource is inside or outside of a
   container region.

3.  Definition of Location Filter Format

   The granularity frequency of notifications necessary for various geographic
   location applications varies dramatically.  The subscriber should be
   able to get asynchronous notifications with appropriate granularity frequency and accuracy,
   granularity, without having to poll or flood the network with issue a large number of notifications which
   that are not important to the application.
   Notifications should only happen when the notification would be
   considered an Interesting Event to the subscriber.  This section of this
   document defines an XML filter format extension to [RFC4661]'s TriggerType element to
   describe interesting conditions or events.  The terminal elements in
   this format are
   defined in terms of existing utilizing Geographic Markup Language (GML) [GML] data
   types or and civic address elements.

   This document also defines a MIME type for this location filter
   format: application/location-delta-filter+xml.
   format, namely 'application/location-delta-filter+xml'.

   This document defines the following as an initial list of Interesting
   Events: events that
   could be interesting to a subscriber:

   1.  the resource Target moves more than a specific specified distance horizontally or
       vertically since the last notification

   2.  the resource Target exceeds a specific specified speed

   3.  the resource Target enters or exits one or more GML objects (for example,
       a set of 2-dimensional or 3-dimensional regions) included or
       referenced in the filter.

   4.  one or more of the values of the specified address labels has
       changed for the resource location of the Target (for example, the A1 value of
       the
       civilAddress <A1> civic address element has changed from California 'California' to Nevada)
   5.  a mininum
       'Nevada')

3.  Filter Definitions

3.1.  Horizontal and maximum rate of reports regardless Vertical Movement

   Changes in the position of movement
   This specification makes use the Target require extensions to the
   functionality of XML namespaces [W3C.REC-xml-names]
   for identifying location filter documents RFC 4661 and document fragments.
   The namespace URI for elements defined by this specification is a URN
   [RFC2141], using the namespace identifier 'ietf' defined by [RFC2648]
   and extended by [RFC3688].  This URN is:

   urn:ietf:params:xml:ns:location-filter simplying assumption.  The filter format starts with former
   aspect refers to the need to enhance the capability to extract a top-level
   value from inside an XML element called
   "<location-filter>", element, in our example from the <pos>
   element, which contains one or more filter events.  The
   semantics of multiple elements inside a location-filter generally is
   a logical OR.  In other words, if any of describes the individual filter events
   occurs, user's location.  Regarding the event satisfies latter
   aspect we assume that the location-filter user's location information of any shape
   and triggers a
   notification.  However the "maxRate" parameter uncertainty is converted into a logical AND, and
   will limit events that otherwise would have been reported.

3.1.  Horizontal and Vertical Movement

   The movedHoriz and movedVert filter events each indicate a minimum
   horizontal motion or vertical distance (respectively) that point before the
   resource must have moved from comparison
   regarding the movement with the previously notified location takes
   place.

   The example shown in Figure 1 references the latitude value (using
   the "gml:pos[1]" notation) and the 'by' attribute of the resource when <changed>
   element indicates the
   last desired change that triggers a notification was sent in order to trigger this event.  The
   distance is measured absolutely from
   be sent.

   <?xml version="1.0" encoding="UTF-8"?>
   <filter-set xmlns="urn:ietf:params:xml:ns:simple-filter">
       <ns-bindings>
           <ns-binding prefix="pidf"
                 urn="urn:ietf:params:xml:ns:pidf"/>
           <ns-binding prefix="gp"
                 urn="urn:ietf:params:xml:ns:pidf:geopriv10"/>
           <ns-binding prefix="dyn"
                 urn="http://www.opengis.net/gml"/>
       </ns-bindings>
       <filter id="123" uri="sip:presentity@example.com">
           <trigger>
               <changed by="100">
                   /pidf:presence/pidf:device/gp:geopriv/
                    gp:location-info/gml:Point/gml:pos[1]
               </changed>
           </trigger>
       </filter>
   </filter-set>

                     Figure 1: Movement Filter Example

3.2.  Changes in Speed

   Speed changes can be filtered with the point help of last notification
   rather than RFC 4661 and the
   functionality provided in terms of cumulative motion (For example, someone
   pacing inside a room will not trigger an event if [I-D.singh-geopriv-pidf-lo-dynamic], which
   extends the trigger
   threshold is slightly larger than the room.)  Each of these events
   can only appear once in a location-filter.  These events have PIDF-LO with support for spatial orientation, speed,
   heading, and acceleration.

   Figure 2 shows an
   attribute "uom" (for "units of measure"), which indicates the units
   of the element.  The default unit example for these events is meters.

   Similarly, the speedExceeds filter event indicates a minimum
   horizontal speed of the resource before the speedExceeds event is
   triggered.  This element can appear only once in a location-filter,
   and has a "uom" attribute which defaults to meters per second if not
   present.

      This filter measures the horizontal component of speed in any
      direction.  It does not measure velocity.  Note also trigger that there is
      no corresponding event triggered fires when speed drops below a
      threshold.

   Below are some examples.  In the first example if the resource moves
   20m in the x,y direction or 3m in the z direction, send a
   notification:

   <location-filter>
     <movedHoriz uom="urn:ogc:def:uom:EPSG::9001">20</movedHoriz>
     <movedVert uom="urn:ogc:def:uom:EPSG::9001">3</movedVert>
   </location-filter>

   If speed of
   the resource exceeds 3 Target changes by 20 meters per second (10.8 km/h), send a
   notification:

   <location-filter>
     <speedExceeds uom="#mps">3</speedExceeds>
   </location-filter>

3.2. second.

   <?xml version="1.0" encoding="UTF-8"?>
   <filter-set xmlns="urn:ietf:params:xml:ns:simple-filter">
       <ns-bindings>
           <ns-binding prefix="pidf"
               urn="urn:ietf:params:xml:ns:pidf"/>
           <ns-binding prefix="gp"
               urn="urn:ietf:params:xml:ns:pidf:geopriv10"/>
           <ns-binding prefix="dyn"
               urn="urn:ietf:params:xml:schema:pidf:dynamic"/>
       </ns-bindings>
       <filter id="123" uri="sip:presentity@example.com">
           <trigger>
               <changed by="3">
                   /pidf:presence/pidf:tuple/pidf:status/
                    gp:geopriv/gp:location-info/dyn:Dynamic/dyn:speed
               </changed>
           </trigger>
       </filter>
   </filter-set>

                      Figure 2: Speed Change Example

3.3.  Changes in value

   The valueChanges filter event contains a string which is interpreted
   as an XPath [W3C.xpath] expression evaluated within the context of
   the location-info element of the PIDF-LO document which would Value

   Changes in values, for example related to civic location information,
   can be
   generated provided by the notification.  The XPath expression MUST evaluate to
   only base functionality offered with RFC 4661.
   Figure 3 shows an example where a single Xpath node.  If the value of any of the elements in the
   resulting node changes, then the filter event notification is triggered.  Note
   that the value of the resulting node changes if any of those nodes or
   subnodes transitions from having a value to having no value or vice
   versa.  A location-filter may contain multiple valueChanges filters.

   For example, given the following logical PIDF-LO document, If sent when the
   state (A1), county (A2), city (A3), civic
   address tokens A1, A2, A3, or postal code (PC) changes, send
   a notification:

   PIDF-LO Location Document: PC change.

   <?xml version="1.0" encoding="UTF-8"?>
       <presence xmlns="urn:ietf:params:xml:ns:pidf"
          xmlns:gp="urn:ietf:params:xml:ns:pidf:geopriv10"
          xmlns:cl="urn:ietf:params:xml:ns:pidf:geopriv10:civilLoc"
          entity="pres:geotarget@example.com">
        <tuple id="sg89ae">
         <status>
          <gp:geopriv>
            <gp:location-info>
              <cl:civilAddress>
                <cl:country>US</cl:country>
                <cl:A1>NY</cl:A1>
                <cl:A3>New York</cl:A3>
                <cl:RD>Broadway</cl:RD>
                <cl:HNO>123</cl:HNO>
                <cl:UNIT>Suite 75</cl:UNIT>
                <cl:PC>10027</cl:PC>
              </cl:civilAddress>
            </gp:location-info>
            <gp:usage-rules>
              <gp:retransmission-allowed>yes</gp:retransmission-allowed>
              <gp:retention-expiry>2003-06-23T04:57:29Z
              </gp:retention-expiry>
            </gp:usage-rules>
          </gp:geopriv>
         </status>
         <timestamp>2003-06-22T20:57:29Z</timestamp>
        </tuple>
       </presence>

   Filter Document:
     <location-filter
       xmlns="urn:ietf:params:xml:ns:location-filter"
       xmlns:cl="urn:ietf:params:xml:ns:pidf:geopriv10:civilLoc">
       <valueChanges>cl:civilAddress/cl:A1</valueChanges>
       <valueChanges>cl:civilAddress/cl:A2</valueChanges>
       <valueChanges>cl:civilAddress/cl:A3</valueChanges>
       <valueChanges>cl:civilAddress/cl:PC</valueChanges>
     </location-filter>

3.3.  Containment Within
   <filter-set xmlns="urn:ietf:params:xml:ns:simple-filter">
       <ns-bindings>
           <ns-binding prefix="pidf"
                 urn="urn:ietf:params:xml:ns:pidf"/>
           <ns-binding prefix="gp"
                 urn="urn:ietf:params:xml:ns:pidf:geopriv10"/>
           <ns-binding prefix="cl"
                 urn="urn:ietf:params:xml:ns:pidf:geopriv10:civilLoc"/>
       </ns-bindings>
       <filter id="123" uri="sip:presentity@example.com">
           <trigger>
               <changed>
                   /pidf:presence/pidf:tuple/pidf:status/gp:geopriv/
                    gp:location-info/cl:civilAddress/cl:A1
               </changed>
               <changed>
                   /pidf:presence/pidf:tuple/pidf:status/gp:geopriv/
                    gp:location-info/cl:civilAddress/cl:A2
               </changed>
               <changed>
                   /pidf:presence/pidf:tuple/pidf:status/gp:geopriv/
                    gp:location-info/cl:civilAddress/cl:A3
               </changed>
               <changed>
                   /pidf:presence/pidf:tuple/pidf:status/gp:geopriv/
                    gp:location-info/cl:civilAddress/cl:PC
               </changed>
           </trigger>
       </filter>
   </filter-set>

                      Figure 3: Speed Change Example

3.4.  Enter or Exit a Region

   The "enterOrExit" filter event <enterOrExit> condition is satisfied when the resource Target enters or
   exits a named 2-dimensional or 3-dimensional region described by
   one of the shapes a
   polygon (as defined in section 5 of
   [I-D.ietf-geopriv-pdif-lo-profile].  These regions can be defined
   using inline snippets Section 5.2.2 of GML, [RFC5491]), or externally referenced using a URI
   (Uniform Resource Identifier).
      These regions need a unique name or identifier so location with
      respect to these regions can be described later (for example circle (as
   defined in Section 5.2.3 of [RFC5491]).

   Figure 4 and Figure 5 shows filter examples whereby a
      notification).  These regions are currently notification is
   sent when the Target enters or exits an area described as GML
      Features so they can be named with by a GML Name.  Ideally each
      region could be described instead as circle
   and by a GML geometry with some
      associated name or identifier.

   Any 2-dimensional region MUST be defined using the EPSG 4326
   coordinate reference system.  Any 3-dimensional region MUST be
   defined using the EPSG 4979 coordinate reference system.  A location-
   filter can contain more than one enterOrExit filter event.

      Notifiers MAY support other more complex geometries or additional
      coordinate reference systems.  How the Subscriber negotiates
      support for more complex geometries or reference systems is out of
      the scope of this document.
      Likewise, this document does not describe how a subscriber
      discovers the existence of externally referenced features.  This
      topic is out of scope of this document.

   In most cases Subscribers that use location filters based on
   enterOrExit events are especially interested in the resource's
   relationship to those named features.  Consequently, the notifier
   MUST include either a "containment" element for each feature
   mentioned in the location-filter which has changed its containment
   properties with respect to the resource since the last notification.
   These elements are defined in Section 4.  The notifier MAY include
   any other form of location that is relevant.

   For example, if the resource enters or exits Building 10 (which is
   defined by specific 2-D or 3-D rectangular coordinates), send a
   notification:

   Version in 2-Dimensions:
   <location-filter>
     <enterOrExit>
       <my:Building>
         <gml:name>Building 10</gml:name>
         <gml:extentOf>
           <gml:Polygon
     srsName="urn:ogc:def:crs:EPSG::4326"
     xmlns:gml="http://www.opengis.net/gml">
             <gml:exterior>
               <gml:LinearRing>
                 <gml:posList
                      37.41188 -121.93243
                      37.41142 -121.93243
                      37.41142 -121.93132
                      37.41188 -121.93132
                      37.41188 -121.93243
                 </gml:posLis>
               </gml:LinearRing>
             </gml:exterior>
           </gml:Polygon>
         </gml:extentOf>
       </my:Building>
     </enterOrExit>
   </location-filter>

   Version in 3-Dimensions:
   <location-filter> 3d polygon.

   <?xml version="1.0" encoding="UTF-8"?>
   <filter-set
       xmlns="urn:ietf:params:xml:ns:simple-filter"
       xmlns:con="urn:ietf:params:xml:ns:pidf:geopriv10:containment"
       xmlns:gml="http://www.opengis.net/gml"
       xmlns:gs="http://www.opengis.net/pidflo/1.0">

       <filter id="123" uri="sip:presentity@example.com">
           <con:enterOrExit>
               <gs:Circle srsName="urn:ogc:def:crs:EPSG::4326">
                   <gml:pos>42.5463 -73.2512</gml:pos>
                   <gs:radius uom="urn:ogc:def:uom:EPSG::9001">
                       850.24
                   </gs:radius>
               </gs:Circle>
           </con:enterOrExit>
       </filter>
   </filter-set>

                Figure 4: <enterOrExit>
       <my:Building>
         <gml:name>Building 10</gml:name>
         <gs:Prism
     srsName="urn:ogc:def:crs:EPSG::4979"
     xmlns:gs="urn:ietf:params:xml:ns:pidf:geopriv10:geoShape" (2D) Filter Example

   <?xml version="1.0" encoding="UTF-8"?>
   <filter-set xmlns="urn:ietf:params:xml:ns:simple-filter"
       xmlns:con="urn:ietf:params:xml:ns:pidf:geopriv10:containment"
       xmlns:gml="http://www.opengis.net/gml">
           <gs:base>
             <gml:Polygon>

       <filter id="123" uri="sip:presentity@example.com">
           <con:enterOrExit>
               <gml:Polygon srsName="urn:ogc:def:crs:EPSG::4326">
                   <gml:exterior>
                       <gml:LinearRing>
                           <gml:posList>
                      37.41188 -121.93243 0
                      37.41142 -121.93242 0
                      37.41142 -121.93132 0
                      37.41188 -121.93132 0
                      37.41188 -121.93243 0
                           43.311 -73.422 43.111 -73.322
                           43.111 -73.222 43.311 -73.122
                           43.411 -73.222 43.411 -73.322
                           43.311 -73.422
                       </gml:posList>
                       </gml:LinearRing>
                   </gml:exterior>
               </gml:Polygon>
           </gs:base>
           <gs:height uom="urn:ogc:def:uom:EPSG::9001">
              24
           </gs:height>
         </gs:Prism>
       </my:Building>
     </enterOrExit>
   </location-filter>

   If the resource enters or exits either the parking garage or any of
   the conference rooms (both of which are externally defined), send a
   notification:

   <location-filter>
     <enterOrExit>
       <my:ParkingGarage
   xlink:href="http://server.example.com/loc-defs/bldg-mgr/parking"/>
     </enterOrExit>
           </con:enterOrExit>
       </filter>
   </filter-set>

                Figure 5: <enterOrExit>
       <my:ConferenceRooms
   xlink:href="http://server.example.com/loc-defs/userdef/confrooms"/>
     </enterOrExit>
   </location-filter>

3.4. (3D) Filter Example

4.  Rate Control

   Although not part of the loc-filter function, the

   The throttle mechanisms
   [I-D.niemi-sipping-event-throttle] [I-D.ietf-sipcore-event-rate-control] can be
   used to control the rate of notifications.  The "throttle", "force"
   and "average" settings can filter notications by time

3.5.  XML Schema for filter format

   The XML Schema for this format is defined below.

   <?xml version="1.0" encoding="UTF-8"?>
   <xs:schema
     targetNamespace="urn:ietf:params:xml:ns:location-filter"
     xmlns:xs="http://www.w3.org/2001/XMLSchema"
     xmlns:gml="http://www.opengis.net/gml">

     <xs:element name="location-filter">
       <xs:complexType>
         <xs:sequence>
           <xs:element name="movedHoriz" type="gml:MeasureType"
                          minOccurs="0" maxOccurs="1"/>
           <xs:element name="movedVert" type="gml:MeasureType"
                          minOccurs="0" maxOccurs="1"/>
           <xs:element name="speedExceeds" type="gml:MeasureType"
                          minOccurs="0" maxOccurs="1"/>

           <!-- this type needs to hold an XPath statement -->
           <xs:element name="valueChanges" type="xs:string"
                          minOccurs="0" maxOccurs="unbounded"/>

           <xs:element name="enterOrExit" type="gml:FeaturePropertyType"
                          minOccurs="0" maxOccurs="unbounded"/>
           <xs:element name="minRate" type="xs:rate-spec"
                          minOccurs="0" maxOccurs="1"/>
           <xs:element name="maxRate" type="xs:rate-spec"
                          minOccurs="0" maxOccurs="1"/>
           <xs:any namespace="##other" processContents="lax"
              minOccurs="0"  maxOccurs="unbounded"/>
         </xs:sequence>
       </xs:complexType>
     </xs:element>
     <xs:element name="rate-spec">
       <xs:complexType>
         <xs:sequence>
           <xs:attribute name="uom" use="required">
             <xs:simpleType>
               <xs:restriction base="xs:token">
                 <xs:enumeration value="seconds"></xs:enumeration>
                 <xs:enumeration value="minutes"></xs:enumeration>
                 <xs:enumeration value="hours"></xs:enumeration>
                 <xs:enumeration value="days"></xs:enumeration>
                 <xs:enumeration value="weeks"></xs:enumeration>
                 <xs:enumeration value="years"></xs:enumeration>
               </xs:restriction>
             </xs:simpleType>
           </xs:attribute>
         </xs:sequence>
       </xs:complexType>
     </xs:element>
   </xs:schema>

   <?xml version="1.0" encoding="UTF-8"?>
   <xs:schema
     targetNamespace="urn:ietf:params:xml:ns:location-filter"
     xmlns:xs="http://www.w3.org/2001/XMLSchema"
     xmlns:gml="http://www.opengis.net/gml">

     <xs:element name="location-filter">
       <xs:complexType>
         <xs:sequence>
           <xs:element name="movedHoriz" type="gml:MeasureType"
                          minOccurs="0" maxOccurs="1"/>
           <xs:element name="movedVert" type="gml:MeasureType"
                          minOccurs="0" maxOccurs="1"/>
           <xs:element name="speedExceeds" type="gml:MeasureType"
                          minOccurs="0" maxOccurs="1"/>

           <!-- this type needs to hold an XPath statement -->
           <xs:element name="valueChanges" type="xs:string"
                          minOccurs="0" maxOccurs="unbounded"/>

           <xs:element name="enterOrExit" type="gml:FeaturePropertyType"
                          minOccurs="0" maxOccurs="unbounded"/>
           <xs:element name="minRate" type="xs:rate-spec"
                          minOccurs="0" maxOccurs="1"/>
           <xs:element name="maxRate" type="xs:rate-spec"
                          minOccurs="0" maxOccurs="1"/>
           <xs:any namespace="##other" processContents="lax"
              minOccurs="0"  maxOccurs="unbounded"/>
         </xs:sequence>
       </xs:complexType>
     </xs:element>
     <xs:element name="rate-spec">
       <xs:complexType>
         <xs:sequence>
           <xs:attribute name="uom" use="required">
             <xs:simpleType>
               <xs:restriction base="xs:token">
                 <xs:enumeration value="seconds"></xs:enumeration>
                 <xs:enumeration value="minutes"></xs:enumeration>
                 <xs:enumeration value="hours"></xs:enumeration>
                 <xs:enumeration value="days"></xs:enumeration>
                 <xs:enumeration value="weeks"></xs:enumeration>
                 <xs:enumeration value="years"></xs:enumeration>
               </xs:restriction>
             </xs:simpleType>
           </xs:attribute>
         </xs:sequence>
       </xs:complexType>
     </xs:element>
   </xs:schema>

   <?xml version="1.0" encoding="UTF-8"?>
   <xs:schema
     targetNamespace="urn:ietf:params:xml:ns:location-filter"
     xmlns:xs="http://www.w3.org/2001/XMLSchema"
     xmlns:gml="http://www.opengis.net/gml">

     <xs:element name="location-filter">
       <xs:complexType>
         <xs:sequence>
           <xs:element name="movedHoriz" type="gml:MeasureType"
                          minOccurs="0" maxOccurs="1"/>
           <xs:element name="movedVert" type="gml:MeasureType"
                          minOccurs="0" maxOccurs="1"/>
           <xs:element name="speedExceeds" type="gml:MeasureType"
                          minOccurs="0" maxOccurs="1"/>
           <!-- this type needs to hold an XPath statement -->
           <xs:element name="valueChanges" type="xs:string"
                          minOccurs="0" maxOccurs="unbounded"/>

           <xs:element name="enterOrExit" type="gml:FeaturePropertyType"
                          minOccurs="0" maxOccurs="unbounded"/>
           <xs:element name="minRate" type="xs:rate-spec"
                          minOccurs="0" maxOccurs="1"/>
           <xs:element name="maxRate" type="xs:rate-spec"
                          minOccurs="0" maxOccurs="1"/>
           <xs:any namespace="##other" processContents="lax"
              minOccurs="0"  maxOccurs="unbounded"/>
         </xs:sequence>
       </xs:complexType>
     </xs:element>
     <xs:element name="rate-spec">
       <xs:complexType>
         <xs:sequence>
           <xs:attribute name="uom" use="required">
             <xs:simpleType>
               <xs:restriction base="xs:token">
                 <xs:enumeration value="seconds"></xs:enumeration>
                 <xs:enumeration value="minutes"></xs:enumeration>
                 <xs:enumeration value="hours"></xs:enumeration>
                 <xs:enumeration value="days"></xs:enumeration>
                 <xs:enumeration value="weeks"></xs:enumeration>
                 <xs:enumeration value="years"></xs:enumeration>
               </xs:restriction>
             </xs:simpleType>
           </xs:attribute>
         </xs:sequence>
       </xs:complexType>
     </xs:element>
   </xs:schema>

4.  Containment schema

   This section describes a schema for describing the resource's
   location relative to a region or list of regions which might contain
   the resource.  (These regions can be defined dynamically in an
   "enterOrExit" element in a subscription filter, or defined on the
   notifier using some out-of-band mechanism.)  The "pidfResource"
   element is placed inside the location-info element in a PIDF-LO
   document.  The pidfResource element can contain zero or more
   "containment" elements.  Each containment element has a GML Feature
   sub-element (of type "FeaturePropertyType") and a mandatory attribute
   which specifies if the PIDF resource is inside or outside of the
   feature, or if the position of the resource with respect to the
   region or region list is undefined.
      In a future version of this specification, the GML Feature can
      become a reference to a more preferable name or identifier type.
      The GML Feature type is only used because it includes a name to
      reference it.

   If the subscriber is not authorized to know the relative position,
   the notifier MUST NOT reveal this private information.  The
   RECOMMENDED way to prevent the subscriber from seeing private
   location data of this type is to return a containment element whose
   position attribute is "undefined".  Note that in some cases, the
   containment information may be more interesting than the actual raw
   location.  It is not necessary to convey a concrete civic or geo
   location in a PIDF-LO if the subscriber is only interested in or
   authorized to see the containment status.

   <?xml version="1.0" encoding="UTF-8"?>
   <xs:schema
   targetNamespace="urn:ietf:params:xml:ns:pidf:geopriv10:containment"
       xmlns:xs="http://www.w3.org/2001/XMLSchema"
       xmlns:gml="http://www.opengis.net/gml"
   xmlns:pr="urn:ietf:params:xml:ns:pidf:geopriv10:containment" >
     <xs:element name="pidfResource">
       <xs:complexType>
           <xs:sequence>
               <xs:element ref="pr:containment"
                minOccurs="0" maxOccurs="unbounded"/>
           </xs:sequence>
       </xs:complexType>
     </xs:element>
     <xs:element name="containment">
       <xs:complexType>
           <xs:sequence>
             <xs:any namespace="http://www.opengis.net/gml"
                   minOccurs="1" maxOccurs="1"/>
           </xs:sequence>
         <xs:attribute name="position" use="required">
            <xs:simpleType>
           <xs:restriction base="xs:string">
               <xs:enumeration value="inside"></xs:enumeration>
               <xs:enumeration value="outside"></xs:enumeration>
               <xs:enumeration value="undefined"></xs:enumeration>
             </xs:restriction>
           </xs:simpleType>
         </xs:attribute>
       </xs:complexType>
     </xs:element>
   </xs:schema>

   Below is an example PIDF-LO document which indicates that the
   resource is inside building 10, not outside the parking garage, and
   not permitted to know if the resource is in a conference room.  Note
   that in GML, these features could be referenced by their unique
   identifiers instead. time.

5.  XML Schema

   <?xml version="1.0" encoding="UTF-8"?>
     <presence xmlns="urn:ietf:params:xml:ns:pidf"
        xmlns:gp="urn:ietf:params:xml:ns:pidf:geopriv10"
        xmlns:pr="urn:ietf:params:xml:ns:pidf:geopriv10:containment"
        entity="pres:geotarget@example.com">
      <tuple id="sg89ae">
       <status>
        <gp:geopriv>
          <gp:location-info>
            <pr:pidfResource>
              <pr:containment position="inside">
               <my:Building>
                  <gml:name>Building 10</gml:name>
                </my:Building>
              </pr:containment>
              <pr:containment position="outside">
                <my:ParkingGarage
   xlink:href="http://server.example.com/loc-defs/bldg-mgr/parking"/>
              </pr:containment>
              <pr:containment position="undefined">
                <my:ConferenceRooms
   xlink:href="http://server.example.com/loc-defs/userdef/confrooms"/>
              </pr:containment>
            </pr:pidfResource>
          </gp:location-info>
          <gp:usage-rules>
            <gp:retransmission-allowed>yes</gp:retransmission-allowed>
            <gp:retention-expiry>2003-06-23T04:57:29Z
            </gp:retention-expiry>
           </gp:usage-rules>
        </gp:geopriv>
       </status>
       <timestamp>2003-06-22T20:57:29Z</timestamp>
      </tuple>
     </presence>

5.
   <xs:schema
       targetNamespace="urn:ietf:params:xml:ns:location-filter"
       xmlns:xs="http://www.w3.org/2001/XMLSchema"
       xmlns:gml="http://www.opengis.net/gml">

       <!-- This element is an child element of the RFC 4661
               <filter> element.
          -->
       <xs:element name="enterOrExit" type="gml:FeaturePropertyType"/>
   </xs:schema>

                           Figure 6: XML Schema

6.  Security Considerations

   Location information is typically very privacy sensitive.  As such,
   GEOPRIV requires that
   notifications MUST be encrypted and integrity protected.

   Additional privacy and security considerations are discussed in
   detail in [I-D.ietf-geopriv-pdif-lo-profile].

6. [RFC5491].

7.  IANA Considerations

6.1.  MIME Registration

7.1.  Content-type registration for application/location-delta-filter+xml 'application/
      location-delta-filter+xml'

   This specification requests the registration of a new MIME type
   according to the procedures of RFC 4288 [RFC4288] and guidelines in
   RFC 3023 [RFC3023].

   MIME media type name:  application

   MIME subtype name: application/location-delta-filter+xml

         Required  location-delta-filter+xml

   Mandatory parameters: none.  none

   Optional parameters: none.  charset; Indicates the character encoding of
      enclosed XML.

   Encoding considerations:   Same as for XML.  Uses XML, which can employ 8-bit
      characters, depending on the character encoding used.  See RFC
      3023 [RFC3023], Section 3.2.

   Security considerations:  See the "Security Considerations" section
      in this document.

   Interoperability considerations: none  None

   Published specification: This document.  RFCXXXX [NOTE TO IANA/RFC-EDITOR: Please
      replace XXXX with the RFC number of this specification.]

   Applications which use this media: The application/
   location-delta-filter+xml application subtype media type:  This content type supports
      the exchange of filters to throttle asynchronous notifications of
      location information.

   Additional information:

              1.

      Magic number(s): Number:  N/A

              2.

      File extension(s): Extension:  N/A

              3.

      Macintosh file type code:  N/A

6.2.  URN Sub-Namespace Registration

   Personal and email address for
      urn:ietf:params:xml:ns:location-filter further information:  Brian Rosen,
      br@brianrosen.net
   Intended usage:  LIMITED USE

   Author:

      This section registers specification is a new XML namespace, as per work item of the guidelines in
   [RFC3688].

   URI:  The URI for this namespace is
      urn:ietf:params:xml:ns:location-filter.
   Registrant Contact:  IETF, IETF GEOPRIV working
      group, <geopriv@ietf.org>,
      as delegated by the IESG <iesg@ietf.org>.

   XML:

   BEGIN
   <?xml version="1.0"?>
   <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML Basic 1.0//EN"
             "http://www.w3.org/TR/xhtml-basic/xhtml-basic10.dtd">
   <html xmlns="http://www.w3.org/1999/xhtml">
   <head>
     <meta http-equiv="content-type"
        content="text/html;charset=iso-8859-1"/>
     <title>Location Filter Namespace</title>
   </head>
   <body>
     <h1>Namespace for PIDF-LO Location Filters</h1>
     <h2>urn:ietf:params:xml:ns:location-filter</h2>
     <p>See <a href="[[[URL of published RFC]]]">RFCXXXX</a>.</p>
   </body>
   </html>
   END

6.3.  Schema Registration For location-filter

   This specification registers a schema, as per the guidelines in
   [RFC3688].

      URI: please assign.
      Registrant Contact: IETF, GEOPRIV Working Group
      (geopriv@ietf.org), as delegated by the IESG (iesg@ietf.org).
      XML: with mailing list address <geopriv@ietf.org>.

   Change controller:

      The XML can be found as the sole content of Section 3.5.

6.4. IESG <iesg@ietf.org>

7.2.  URN Sub-Namespace Registration for
      urn:ietf:params:xml:ns:pidf:geopriv10:containment
      urn:ietf:params:xml:ns:location-filter

   This section registers a new XML namespace, as per the guidelines in
   [RFC3688].

   URI:  The URI for this namespace is
      urn:ietf:params:xml:ns:pidf:geopriv10:containment.
      urn:ietf:params:xml:ns:location-filter.

   Registrant Contact:  IETF, GEOPRIV working group, <geopriv@ietf.org>,
      as delegated by the IESG <iesg@ietf.org>.

   XML:

   BEGIN
   <?xml version="1.0"?>
   <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML Basic 1.0//EN"
             "http://www.w3.org/TR/xhtml-basic/xhtml-basic10.dtd">
   <html xmlns="http://www.w3.org/1999/xhtml">
   <head>
     <meta http-equiv="content-type"
        content="text/html;charset=iso-8859-1"/>
     <title>PIDF-LO Location Containment
     <title>Location Filter Namespace</title>
   </head>
   <body>
     <h1>Namespace for PIDF-LO location containment elements</h1>
     <h2>urn:ietf:params:xml:ns:pidf:geopriv10:containment</h2> Location Filters</h1>
     <h2>urn:ietf:params:xml:ns:location-filter</h2>
     <p>See <a href="[[[URL of published RFC]]]">RFCXXXX</a>.</p>
   </body>
   </html>
   END

6.5.

7.3.  Schema Registration For containment location-filter

   This specification registers a schema, as per the guidelines in
   [RFC3688].

      URI: please assign.

      Registrant Contact: IETF, GEOPRIV Working Group
      (geopriv@ietf.org), as delegated by the IESG (iesg@ietf.org).

      XML: The XML can be found as the sole content of Section 4.

7. 5.

8.  Acknowledgments

   Thanks to Allan Thompson, James Winterbottom, and Martin Thomson for
   their comments.

8.

9.  References

8.1.

9.1.  Normative References

   [GML]      OpenGIS, "Open Geography Markup Language (GML)
              Implementation Specification", OpenGIS OGC 02-023r4,
              January 2003,
              <http://www.opengis.org/techno/implementation.htm>.

   [I-D.ietf-geopriv-pdif-lo-profile]
              Winterbottom, J., Thomson, M., and H. Tschofenig, "GEOPRIV
              PIDF-LO Usage Clarification, Considerations and
              Recommendations", draft-ietf-geopriv-pdif-lo-profile-13
              (work in progress), September 2008.

   [I-D.niemi-sipping-event-throttle]
              Implementation Specification", OpenGIS OGC 02-023r4,
              January 2003,
              <http://www.opengis.org/techno/implementation.htm>.

   [I-D.ietf-sipcore-event-rate-control]
              Niemi, A., Kiss, K., and S. Loreto, "Session Initiation
              Protocol (SIP) Event Notification Extension for
              Notification Throttling",
              draft-niemi-sipping-event-throttle-07 Rate Control",
              draft-ietf-sipcore-event-rate-control-00 (work in
              progress), May 2009.

   [I-D.singh-geopriv-pidf-lo-dynamic]
              Schulzrinne, H., Singh, V., Tschofenig, H., and M.
              Thomson, "Dynamic Extensions to the Presence Information
              Data Format Location Object  (PIDF-LO)",
              draft-singh-geopriv-pidf-lo-dynamic-06 (work in progress),
              October 2008.
              June 2009.

   [RFC2119]  Bradner, S., "Key words for use in RFCs to Indicate
              Requirement Levels", BCP 14, RFC 2119, March 1997.

   [RFC3023]  Murata, M., St. Laurent, S., and D. Kohn, "XML Media
              Types", RFC 3023, January 2001.

   [RFC4119]  Peterson, J., "A Presence-based GEOPRIV Location Object
              Format", RFC 4119, December 2005.

   [W3C.REC-xml]
              Bray, T., Paoli, J., Sperberg-McQueen, C.,

   [RFC4288]  Freed, N. and E. Maler,
              "Extensible Markup Language (XML) 1.0 (2nd ed)", W3C REC-
              xml, October 2000, <http://www.w3.org/TR/REC-xml>.

   [W3C.REC-xml-names]
              Bray, T., Hollander, D., and A. Layman, "Namespaces in
              XML", W3C REC-xml-names, January 1999,
              <http://www.w3.org/TR/REC-xml-names>.

   [W3C.REC-xmlschema-1]
              Thompson, J. Klensin, "Media Type Specifications and
              Registration Procedures", BCP 13, RFC 4288, December 2005.

   [RFC4661]  Khartabil, H., Beech, D., Maloney, Leppanen, E., Lonnfors, M., and N. Mendelsohn,
              "XML Schema Part 1: Structures", W3C REC-xmlschema-1,
              May 2001, <http://www.w3.org/TR/xmlschema-1/>.

   [W3C.xpath]
              Clark, J. and S. DeRose, "XML Path Costa-
              Requena, "An Extensible Markup Language (XPath)
              Version 1.0", W3C Recommendation xpath, November 1999,
              <http://www.w3.org/TR/xpath>.

8.2. (XML)-Based Format
              for Event Notification Filtering", RFC 4661,
              September 2006.

   [RFC5491]  Winterbottom, J., Thomson, M., and H. Tschofenig, "GEOPRIV
              Presence Information Data Format Location Object (PIDF-LO)
              Usage Clarification, Considerations, and Recommendations",
              RFC 5491, March 2009.

9.2.  Informational References

   [RFC2141]  Moats, R., "URN Syntax", RFC 2141, May 1997.

   [RFC2648]  Moats, R., "A URN Namespace

   [I-D.ietf-sip-location-conveyance]
              Polk, J. and B. Rosen, "Location Conveyance for IETF Documents", RFC 2648,
              August 1999. the
              Session Initiation Protocol",
              draft-ietf-sip-location-conveyance-13 (work in progress),
              March 2009.

   [RFC3688]  Mealling, M., "The IETF XML Registry", BCP 81, RFC 3688,
              January 2004.

Authors' Addresses

   Rohan Mahy
   Plantronics
   345 Encincal Street
   Santa Cruz, CA
   USA

   Email: rohan@ekabal.com

   Brian Rosen (editor)
   NeuStar
   470 Conrad Dr.
   Mars, PA  16046
   US

   Phone: +1 724 382 1051
   Email: br@brianrosen.net

Full Copyright Statement

   Copyright (C) The IETF Trust (2008).

   This document is subject to the rights, licenses and restrictions
   contained in BCP 78, and except as set forth therein, the authors
   retain all their rights.

   This document and the information contained herein are provided on an
   "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS
   OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY, THE IETF TRUST AND
   THE INTERNET ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS
   OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF
   THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
   WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.

Intellectual Property

   The IETF takes no position regarding the validity or scope of any
   Intellectual Property Rights or other rights that might be claimed to
   pertain to the implementation or use of the technology described in
   this document or the extent to which any license under such rights
   might or might not be available; nor does it represent that it has
   made any independent effort to identify any such rights.  Information
   on the procedures with respect to rights in RFC documents can be
   found in BCP 78 and BCP 79.

   Copies of IPR disclosures made to the IETF Secretariat and any
   assurances of licenses to be made available, or the result of an
   attempt made to obtain a general license or permission for the use of
   such proprietary rights by implementers or users of this
   specification can be obtained from the IETF on-line IPR repository at
   http://www.ietf.org/ipr.

   The IETF invites any interested party to bring to its attention any
   copyrights, patents or patent applications, or other proprietary
   rights that may cover technology that may be required to implement
   this standard.  Please address the information to the IETF at
   ietf-ipr@ietf.org.

   Hannes Tschofenig
   Nokia Siemens Networks
   Linnoitustie 6
   Espoo  02600
   Finland

   Phone: +358 (50) 4871445
   Email: Hannes.Tschofenig@gmx.net
   URI:   http://www.tschofenig.priv.at