The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xml:lang="en" xmlns="http://www.w3.org/1999/xhtml" lang="en"><head>


    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <meta name="robots" content="index,follow">
    <meta name="creator" content="rfcmarkup version 1.83">
    <link rel="schema.DC" href="http://purl.org/dc/elements/1.1/">
<meta name="DC.Identifier" content="urn:ietf:rfc:5025">
<meta name="DC.Description.Abstract" content="Authorization is a key function in presence systems. Authorization policies, also known as authorization rules, specify what presence information can be given to which watchers, and when. This specification defines an Extensible Markup Language (XML) document format for expressing presence authorization rules. Such a document can be manipulated by clients using the XML Configuration Access Protocol (XCAP), although other techniques are permitted.">
<meta name="DC.Creator" content="Rosenberg, J.">
<meta name="DC.Creator" content="Rosenberg, J.">
<meta name="DC.Date.Issued" content="December, 2007">
<meta name="DC.Title" content="Presence Authorization Rules">

    <link rel="icon" href="http://tools.ietf.org/images/rfc.png" type="image/png">
    <link rel="shortcut icon" href="http://tools.ietf.org/images/rfc.png" type="image/png">
    <title>RFC 5025 - Presence Authorization Rules</title>
    
    <style type="text/css">
	body {
	    margin: 0px 8px;
            font-size: 1em;
	}
        h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6 {
	    font-weight: bold;
            line-height: 0pt;
            display: inline;
            white-space: pre;
            font-family: monospace;
            font-size: 1em;
	    font-weight: bold;
        }
        pre {
            font-size: 1em;
            margin-top: 0px;
            margin-bottom: 0px;
        }
	.pre {
	    white-space: pre;
	    font-family: monospace;
	}
	.header{
	    font-weight: bold;
	}
        .newpage {
            page-break-before: always;
        }
        .invisible {
            text-decoration: none;
            color: white;
        }
        @media print {
            body {
                font-size: 10.5pt;
            }
            h1, h2, h3, h4, h5, h6 {
                font-size: 10.5pt;
            }
        
            a:link, a:visited {
                color: inherit;
                text-decoration: none;
            }
            .noprint {
                display: none;
            }
        }
	@media screen {
	    .grey, .grey a:link, .grey a:visited {
		color: #777;
	    }
            .docinfo {
                background-color: #EEE;
            }
            .top {
                border-top: 7px solid #EEE;
            }
            .bgwhite  { background-color: white; }
            .bgred    { background-color: #F44; }
            .bggrey   { background-color: #666; }
            .bgbrown  { background-color: #840; }            
            .bgorange { background-color: #FA0; }
            .bgyellow { background-color: #EE0; }
            .bgmagenta{ background-color: #F4F; }
            .bgblue   { background-color: #66F; }
            .bgcyan   { background-color: #4DD; }
            .bggreen  { background-color: #4F4; }

            .legend   { font-size: 90%; }
            .cplate   { font-size: 70%; border: solid grey 1px; }
	}
    </style>
    <!--[if IE]>
    <style>
    body {
       font-size: 13px;
       margin: 10px 10px;
    }
    </style>
    <![endif]-->

    <script type="text/javascript"><!--
    function addHeaderTags() {
	var spans = document.getElementsByTagName("span");
	for (var i=0; i < spans.length; i++) {
	    var elem = spans[i];
	    if (elem) {
		var level = elem.getAttribute("class");
                if (level == "h1" || level == "h2" || level == "h3" || level == "h4" || level == "h5" || level == "h6") {
                    elem.innerHTML = "<"+level+">"+elem.innerHTML+"</"+level+">";		
                }
	    }
	}
    }
    var legend_html = "Colour legend:<br />      <table>         <tr><td>Unknown:</td>          <td><span class='cplate bgwhite'>&nbsp;&nbsp;&nbsp;&nbsp;</span></td></tr>         <tr><td>Draft:</td>            <td><span class='cplate bgred'>&nbsp;&nbsp;&nbsp;&nbsp;</span></td></tr>         <tr><td>Informational:</td>    <td><span class='cplate bgorange'>&nbsp;&nbsp;&nbsp;&nbsp;</span></td></tr>         <tr><td>Experimental:</td>     <td><span class='cplate bgyellow'>&nbsp;&nbsp;&nbsp;&nbsp;</span></td></tr>         <tr><td>Best Common Practice:</td><td><span class='cplate bgmagenta'>&nbsp;&nbsp;&nbsp;&nbsp;</span></td></tr>         <tr><td>Proposed Standard:</td><td><span class='cplate bgblue'>&nbsp;&nbsp;&nbsp;&nbsp;</span></td></tr>         <tr><td>Draft Standard:</td>   <td><span class='cplate bgcyan'>&nbsp;&nbsp;&nbsp;&nbsp;</span></td></tr>         <tr><td>Standard:</td>         <td><span class='cplate bggreen'>&nbsp;&nbsp;&nbsp;&nbsp;</span></td></tr>         <tr><td>Historic:</td>         <td><span class='cplate bggrey'>&nbsp;&nbsp;&nbsp;&nbsp;</span></td></tr>         <tr><td>Obsolete:</td>         <td><span class='cplate bgbrown'>&nbsp;&nbsp;&nbsp;&nbsp;</span></td></tr>     </table>";
    function showElem(id) {
        var elem = document.getElementById(id);
        elem.innerHTML = eval(id+"_html");
        elem.style.visibility='visible';
    }
    function hideElem(id) {
        var elem = document.getElementById(id);
        elem.style.visibility='hidden';        
        elem.innerHTML = "";
    }
    // -->
    </script>
</head><body onload="addHeaderTags()">
   <div style="height: 13px;">
      <div onmouseover="this.style.cursor='pointer';" onclick="showElem('legend');" onmouseout="hideElem('legend')" style="height: 6px; position: absolute; cursor: pointer;" class="pre noprint docinfo bgblue" title="Click for colour legend.">                                                                        </div>
      <div id="legend" class="docinfo noprint pre legend" style="border: 1px solid rgb(51, 68, 85); padding: 4px 9px 5px 7px; position: absolute; top: 4px; left: 4ex; visibility: hidden; background-color: white;" onmouseover="showElem('legend');" onmouseout="hideElem('legend');"></div>
   </div>
<span class="pre noprint docinfo top">[<a href="http://tools.ietf.org/html/" title="Document search and retrieval page">Docs</a>] [<a href="http://tools.ietf.org/rfc/rfc5025.txt" title="Plaintext version of this document">txt</a>] [<a href="http://tools.ietf.org/pdf/rfc5025" title="PDF version of this document">pdf</a>] [<a href="http://tools.ietf.org/html/draft-ietf-simple-presence-rules" title="draft-ietf-simple-presence-rules">draft-ietf-simple-presence...</a>] [<a href="http://tools.ietf.org/rfcdiff?difftype=--hwdiff&amp;url2=rfc5025" title="Inline diff (wdiff)">Diff1</a>] [<a href="http://tools.ietf.org/rfcdiff?url2=rfc5025" title="Side-by-side diff">Diff2</a>]      </span><br>
<span class="pre noprint docinfo">                                                                        </span><br>
<span class="pre noprint docinfo">                                                       PROPOSED STANDARD</span><br>
<span class="pre noprint docinfo">                                                                        </span><br>
<pre>Network Working Group                                       J. Rosenberg
Request for Comments: 5025                                         Cisco
Category: Standards Track                                  December 2007


                     <span class="h1"><h1>Presence Authorization Rules</h1></span>

Status of This Memo

   This document specifies an Internet standards track protocol for the
   Internet community, and requests discussion and suggestions for
   improvements.  Please refer to the current edition of the "Internet
   Official Protocol Standards" (STD 1) for the standardization state
   and status of this protocol.  Distribution of this memo is unlimited.

Abstract

   Authorization is a key function in presence systems.  Authorization
   policies, also known as authorization rules, specify what presence
   information can be given to which watchers, and when.  This
   specification defines an Extensible Markup Language (XML) document
   format for expressing presence authorization rules.  Such a document
   can be manipulated by clients using the XML Configuration Access
   Protocol (XCAP), although other techniques are permitted.

Table of Contents

   <a href="#section-1">1</a>. Introduction ....................................................<a href="#page-2">2</a>
   <a href="#section-2">2</a>. Terminology .....................................................<a href="#page-3">3</a>
   <a href="#section-3">3</a>. Structure of Presence Authorization Documents ...................<a href="#page-3">3</a>
      <a href="#section-3.1">3.1</a>. Conditions .................................................<a href="#page-4">4</a>
           <a href="#section-3.1.1">3.1.1</a>. Identity ............................................<a href="#page-4">4</a>
                  <a href="#section-3.1.1.1">3.1.1.1</a>. Acceptable Forms of Authentication .........<a href="#page-4">4</a>
                  <a href="#section-3.1.1.2">3.1.1.2</a>. Computing a URI for the Watcher ............<a href="#page-5">5</a>
           <a href="#section-3.1.2">3.1.2</a>. Sphere ..............................................<a href="#page-6">6</a>
      <a href="#section-3.2">3.2</a>. Actions ....................................................<a href="#page-7">7</a>
           <a href="#section-3.2.1">3.2.1</a>. Subscription Handling ...............................<a href="#page-7">7</a>
      <a href="#section-3.3">3.3</a>. Transformations ............................................<a href="#page-9">9</a>
           <a href="#section-3.3.1">3.3.1</a>. Providing Access to Data Component Elements .........<a href="#page-9">9</a>
                  <a href="#section-3.3.1.1">3.3.1.1</a>. Device Information .........................<a href="#page-9">9</a>
                  <a href="#section-3.3.1.2">3.3.1.2</a>. Person Information ........................<a href="#page-10">10</a>
                  <a href="#section-3.3.1.3">3.3.1.3</a>. Service Information .......................<a href="#page-11">11</a>
           <a href="#section-3.3.2">3.3.2</a>. Providing Access to Presence Attributes ............<a href="#page-12">12</a>
                  <a href="#section-3.3.2.1">3.3.2.1</a>. Provide Activities ........................<a href="#page-12">12</a>
                  <a href="#section-3.3.2.2">3.3.2.2</a>. Provide Class .............................<a href="#page-12">12</a>
                  <a href="#section-3.3.2.3">3.3.2.3</a>. Provide DeviceID ..........................<a href="#page-13">13</a>
                  <a href="#section-3.3.2.4">3.3.2.4</a>. Provide Mood ..............................<a href="#page-13">13</a>
                  <a href="#section-3.3.2.5">3.3.2.5</a>. Provide Place-is ..........................<a href="#page-13">13</a>



<span class="grey">Rosenberg                   Standards Track                     [Page 1]</span>
</pre><pre class="newpage"><a name="page-2" id="page-2" href="#page-2" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


                  <a href="#section-3.3.2.6">3.3.2.6</a>. Provide Place-type ........................<a href="#page-13">13</a>
                  <a href="#section-3.3.2.7">3.3.2.7</a>. Provide Privacy ...........................<a href="#page-13">13</a>
                  <a href="#section-3.3.2.8">3.3.2.8</a>. Provide Relationship ......................<a href="#page-14">14</a>
                  <a href="#section-3.3.2.9">3.3.2.9</a>. Provide Sphere ............................<a href="#page-14">14</a>
                  <a href="#section-3.3.2.10">3.3.2.10</a>. Provide Status-Icon ......................<a href="#page-14">14</a>
                  <a href="#section-3.3.2.11">3.3.2.11</a>. Provide Time-Offset ......................<a href="#page-14">14</a>
                  <a href="#section-3.3.2.12">3.3.2.12</a>. Provide User-Input .......................<a href="#page-14">14</a>
                  <a href="#section-3.3.2.13">3.3.2.13</a>. Provide Note .............................<a href="#page-15">15</a>
                  <a href="#section-3.3.2.14">3.3.2.14</a>. Provide Unknown Attribute ................<a href="#page-15">15</a>
                  <a href="#section-3.3.2.15">3.3.2.15</a>. Provide All Attributes ...................<a href="#page-16">16</a>
   <a href="#section-4">4</a>. When to Apply the Authorization Policies .......................<a href="#page-17">17</a>
   <a href="#section-5">5</a>. Implementation Requirements ....................................<a href="#page-17">17</a>
   <a href="#section-6">6</a>. Example Document ...............................................<a href="#page-18">18</a>
   <a href="#section-7">7</a>. XML Schema .....................................................<a href="#page-19">19</a>
   <a href="#section-8">8</a>. Schema Extensibility ...........................................<a href="#page-21">21</a>
   <a href="#section-9">9</a>. XCAP Usage .....................................................<a href="#page-22">22</a>
      <a href="#section-9.1">9.1</a>. Application Unique ID .....................................<a href="#page-22">22</a>
      <a href="#section-9.2">9.2</a>. XML Schema ................................................<a href="#page-22">22</a>
      <a href="#section-9.3">9.3</a>. Default Namespace .........................................<a href="#page-22">22</a>
      <a href="#section-9.4">9.4</a>. MIME Type .................................................<a href="#page-22">22</a>
      <a href="#section-9.5">9.5</a>. Validation Constraints ....................................<a href="#page-22">22</a>
      <a href="#section-9.6">9.6</a>. Data Semantics ............................................<a href="#page-22">22</a>
      <a href="#section-9.7">9.7</a>. Naming Conventions ........................................<a href="#page-23">23</a>
      <a href="#section-9.8">9.8</a>. Resource Interdependencies ................................<a href="#page-23">23</a>
      <a href="#section-9.9">9.9</a>. Authorization Policies ....................................<a href="#page-23">23</a>
   <a href="#section-10">10</a>. Security Considerations .......................................<a href="#page-23">23</a>
   <a href="#section-11">11</a>. IANA Considerations ...........................................<a href="#page-24">24</a>
      <a href="#section-11.1">11.1</a>. XCAP Application Usage ID ................................<a href="#page-24">24</a>
      <a href="#section-11.2">11.2</a>. URN Sub-Namespace Registration ...........................<a href="#page-25">25</a>
      <a href="#section-11.3">11.3</a>. XML Schema Registrations .................................<a href="#page-25">25</a>
   <a href="#section-12">12</a>. Acknowledgements ..............................................<a href="#page-26">26</a>
   <a href="#section-13">13</a>. References ....................................................<a href="#page-26">26</a>
      <a href="#section-13.1">13.1</a>. Normative References .....................................<a href="#page-26">26</a>
      <a href="#section-13.2">13.2</a>. Informative References ...................................<a href="#page-27">27</a>

<span class="h2"><h2><a name="section-1">1</a>.  Introduction</h2></span>

   The Session Initiation Protocol (SIP) for Instant Messaging and
   Presence (SIMPLE) specifications allow a user, called a watcher, to
   subscribe to another user, called a presentity [<a href="#ref-17" title="&quot;A Model for Presence and Instant Messaging&quot;">17</a>], in order to
   learn their presence information [<a href="#ref-18" title="&quot;A Presence Event Package for the Session Initiation Protocol (SIP)&quot;">18</a>].  This subscription is handled
   by a presence agent.  However, presence information is sensitive, and
   a presence agent needs authorization from the presentity prior to
   handing out presence information.  As such, a presence authorization
   document format is needed.  This specification defines a format for
   such a document, called a presence authorization document.





<span class="grey">Rosenberg                   Standards Track                     [Page 2]</span>
</pre><pre class="newpage"><a name="page-3" id="page-3" href="#page-3" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


   [<a name="ref-8" id="ref-8">8</a>] specifies a framework for representing authorization policies,
   and is applicable to systems such as geo-location and presence.  This
   framework is used as the basis for presence authorization documents.
   In the framework, an authorization policy is a set of rules.  Each
   rule contains conditions, actions, and transformations.  The
   conditions specify under what conditions the rule is to be applied to
   presence server processing.  The actions element tells the server
   what actions to take.  The transformations element indicates how the
   presence data is to be manipulated before being presented to that
   watcher, and as such, defines a privacy filtering operation. [<a href="#ref-8" title="&quot;Common Policy: A Document Format for Expressing Privacy Preferences&quot;">8</a>]
   identifies a small number of specific conditions common to presence
   and location services, and leaves it to other specifications, such as
   this one, to fill in usage specific details.

   A presence authorization document can be manipulated by clients using
   several means.  One such mechanism is the XML Configuration Access
   Protocol (XCAP) [<a href="#ref-2" title="&quot;The Extensible Markup Language (XML) Configuration Access Protocol (XCAP)&quot;">2</a>].  This specification defines the details
   necessary for using XCAP to manage presence authorization documents.

<span class="h2"><h2><a name="section-2">2</a>.  Terminology</h2></span>

   In this document, the key words "MUST", "MUST NOT", "REQUIRED",
   "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY",
   and "OPTIONAL" are to be interpreted as described in <a href="http://tools.ietf.org/html/rfc2119">RFC 2119</a> [<a href="#ref-1" title="&quot;Key words for use in RFCs to Indicate Requirement Levels&quot;">1</a>] and
   indicate requirement levels for compliant implementations.

<span class="h2"><h2><a name="section-3">3</a>.  Structure of Presence Authorization Documents</h2></span>

   A presence authorization document is an XML document, formatted
   according to the schema defined in [<a href="#ref-8" title="&quot;Common Policy: A Document Format for Expressing Privacy Preferences&quot;">8</a>].  Presence authorization
   documents inherit the MIME type of common policy documents,
   application/auth-policy+xml.  As described in [<a href="#ref-8" title="&quot;Common Policy: A Document Format for Expressing Privacy Preferences&quot;">8</a>], this document is
   composed of rules that contain three parts - conditions, actions, and
   transformations.  Each action or transformation, which is also called
   a permission, has the property of being a positive grant of
   information to the watcher.  As a result, there is a well-defined
   mechanism for combining actions and transformations obtained from
   several sources.  This mechanism is privacy safe, since the lack of
   any action or transformation can only result in less information
   being presented to a watcher.

   This section defines the new conditions, actions, and transformations
   defined by this specification.








<span class="grey">Rosenberg                   Standards Track                     [Page 3]</span>
</pre><pre class="newpage"><a name="page-4" id="page-4" href="#page-4" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


<span class="h3"><h3><a name="section-3.1">3.1</a>.  Conditions</h3></span>

<span class="h4"><h4><a name="section-3.1.1">3.1.1</a>.  Identity</h4></span>

   Although the &lt;identity&gt; element is defined in [<a href="#ref-8" title="&quot;Common Policy: A Document Format for Expressing Privacy Preferences&quot;">8</a>], that specification
   indicates that the specific usages of the framework document need to
   define details that are protocol and usage specific.  In particular,
   it is necessary for a usage of the common policy framework to:

   o  Define acceptable means of authentication.

   o  Define the procedure for representing the identity of the WR
      (Watcher/Requestor) as a URI or Internationalized Resource
      Identifier (IRI) [<a href="#ref-13" title="&quot;Internationalized Resource Identifiers (IRIs)&quot;">13</a>].

   This sub-section defines those details for systems based on [<a href="#ref-18" title="&quot;A Presence Event Package for the Session Initiation Protocol (SIP)&quot;">18</a>].  It
   does so in general terms, so that the recommendations defined here
   apply to existing and future authentication mechanisms in SIP.

<span class="h5"><h5><a name="section-3.1.1.1">3.1.1.1</a>.  Acceptable Forms of Authentication</h5></span>

   When used with SIP, a request is considered authenticated if one of
   the following is true:


   The watcher proves its identity to the server through a form of
   cryptographic authentication, including authentication based on a
   shared secret or a certificate, and that authentication yields an
   identity for the watcher.

   The request comes from a sender that is asserting the identity of the
   watcher, and:

   1.  the assertion includes a claim that the asserting party used a
      form of cryptographic authentication (as defined above) to
      determine the identity of the watcher, and

   2.  the server trusts that assertion, and

   3.  the assertion provides an identity in the form of a URI.

   Based on this definition, examples of valid authentication techniques
   include SIP [<a href="#ref-5" title="&quot;SIP: Session Initiation Protocol&quot;">5</a>], digest authentication [<a href="#ref-4" title="&quot;HTTP Authentication: Basic and Digest Access Authentication&quot;">4</a>], cryptographically
   verified identity assertions (<a href="http://tools.ietf.org/html/rfc4474">RFC 4474</a> [<a href="#ref-15" title="&quot;Enhancements for Authenticated Identity Management in the Session Initiation Protocol (SIP)&quot;">15</a>]), and identity assertions
   made in closed network environments (<a href="http://tools.ietf.org/html/rfc3325">RFC 3325</a> [<a href="#ref-16" title="&quot;Private Extensions to the Session Initiation Protocol (SIP) for Asserted Identity within Trusted Networks&quot;">16</a>]).

   However, the anonymous authentication described on page 194 of <a href="http://tools.ietf.org/html/rfc3261">RFC</a>
   <a href="http://tools.ietf.org/html/rfc3261">3261</a> [<a href="#ref-5" title="&quot;SIP: Session Initiation Protocol&quot;">5</a>] is not considered a valid mechanism for authentication



<span class="grey">Rosenberg                   Standards Track                     [Page 4]</span>
</pre><pre class="newpage"><a name="page-5" id="page-5" href="#page-5" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


   because it does not produce an identity for the watcher.  However, an
   anonymous From header field, when used in conjunction with <a href="http://tools.ietf.org/html/rfc4474">RFC 4474</a>
   [<a href="#ref-15" title="&quot;Enhancements for Authenticated Identity Management in the Session Initiation Protocol (SIP)&quot;">15</a>], is considered an acceptable mechanism for authentication, since
   it still implies that the asserting node performed authentication
   that produced the identity of the watcher.

<span class="h5"><h5><a name="section-3.1.1.2">3.1.1.2</a>.  Computing a URI for the Watcher</h5></span>

   Computing the URI for the watcher depends on whether the identity is
   being ascertained through authentication or through an asserted
   identity.

   If an identity assertion is being utilized, the asserted identity
   itself (which is in the form of a URI for acceptable forms of
   identity assertion) is utilized as the URI.  If the identity
   assertion mechanism asserts multiple URIs for the watcher, then each
   of them is used for the comparisons outlined in [<a href="#ref-8" title="&quot;Common Policy: A Document Format for Expressing Privacy Preferences&quot;">8</a>], and if any of
   them match a &lt;one&gt; or &lt;except&gt; element, the watcher is considered a
   match.

   If an identity is being determined directly by a cryptographic
   authentication, that authentication must produce a URI, or must
   produce some form of identifier that can be linked, through
   provisioning, to a URI that is bound to that identifier.

   For example, in the case of SIP Digest authentication, the
   authentication process produces a username scoped within a realm.
   That username and realm are bound to an Address of Record (AOR)
   through provisioning, and the resulting AOR is used as the watcher
   URI.  Consider the following "user record" in a database:

   SIP AOR: sip:alice@example.com
   digest username: ali
   digest password: f779ajvvh8a6s6
   digest realm: example.com

   If the presence server receives a SUBSCRIBE request, challenges it
   with the realm set to "example.com", and the subsequent SUBSCRIBE
   contains an Authorization header field with a username of "ali" and a
   digest response generated with the password "f779ajvvh8a6s6", the
   identity used in matching operations is "sip:alice@example.com".

   In SIP systems, it is possible for a user to have aliases - that is,
   there are multiple SIP AORs "assigned" to a single user.  In terms of
   this specification, there is no relationship between those aliases.
   Each would look like a different user.  This will be the consequence
   for systems where the watcher is in a different domain than the
   presentity.  However, even if the watcher and presentity are in the



<span class="grey">Rosenberg                   Standards Track                     [Page 5]</span>
</pre><pre class="newpage"><a name="page-6" id="page-6" href="#page-6" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


   same domain, and the presence server knows that there are aliases for
   the watcher, these aliases are not mapped to each other or used in
   any way.

   SIP also allows for anonymous requests.  If a request is anonymous
   because the watcher utilized an authentication mechanism that does
   not provide an identity to the presence server (such as the SIP
   digest "anonymous" username), the request is considered
   unauthenticated (as discussed above) and will match only an empty
   &lt;identity&gt; element.  If a request is anonymous because it contains a
   Privacy header field [<a href="#ref-14" title="&quot;A Privacy Mechanism for the Session Initiation Protocol (SIP)&quot;">14</a>], but still contains an asserted identity
   meeting the criteria defined above, that identity is utilized, and
   the fact that the request was anonymous has no impact on the identity
   processing.

   It is important to note that SIP frequently uses both SIP URI and tel
   URI [<a href="#ref-12" title="&quot;The tel URI for Telephone Numbers&quot;">12</a>] as identifiers, and to make matters more confusing, a SIP
   URI can contain a phone number in its user part, in the same format
   used in a tel URI.  A WR identity that is a SIP URI with a phone
   number will NOT match the &lt;one&gt; and &lt;except&gt; conditions whose 'id' is
   a tel URI with the same number.  The same is true in the reverse.  If
   the WR identity is a tel URI, this will not match a SIP URI in the
   &lt;one&gt; or &lt;except&gt; conditions whose user part is a phone number.  URIs
   of different schemes are never equivalent.

<span class="h4"><h4><a name="section-3.1.2">3.1.2</a>.  Sphere</h4></span>

   The &lt;sphere&gt; element is defined in [<a href="#ref-8" title="&quot;Common Policy: A Document Format for Expressing Privacy Preferences&quot;">8</a>].  However, each application
   making use of the common policy specification needs to determine how
   the presence server computes the value of the &lt;sphere&gt; to be used in
   the evaluation of the condition.

   To compute the value of &lt;sphere&gt;, the presence agent examines all
   published presence documents for the presentity.  If at least one of
   them includes the &lt;sphere&gt; element [<a href="#ref-9" title="&quot;RPID: Rich Presence Extensions to the Presence Information Data Format (PIDF)&quot;">9</a>] as part of the person data
   component [<a href="#ref-10" title="&quot;A Data Model for Presence&quot;">10</a>], and all of those containing the element have the same
   value for it, which is the value used for the &lt;sphere&gt; in presence
   policy processing.  If, however, the &lt;sphere&gt; element was not present
   in any of the published documents, or it was present but had
   inconsistent values, its value is considered undefined in terms of
   presence policy processing.

   Care must be taken in using &lt;sphere&gt; as a condition for determining
   the subscription handling.  Since the value of &lt;sphere&gt; changes
   dynamically, a state change can cause a subscription to be suddenly
   terminated.  The watcher has no way to know, aside from polling, when
   their subscription would be reinstated as the value of &lt;sphere&gt;




<span class="grey">Rosenberg                   Standards Track                     [Page 6]</span>
</pre><pre class="newpage"><a name="page-7" id="page-7" href="#page-7" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


   changes.  For this reason, &lt;sphere&gt; is primarily useful for matching
   on rules that define transformations.

<span class="h3"><h3><a name="section-3.2">3.2</a>.  Actions</h3></span>

<span class="h4"><h4><a name="section-3.2.1">3.2.1</a>.  Subscription Handling</h4></span>

   The &lt;sub-handling&gt; element specifies the subscription authorization
   decision that the server should make.  It also specifies whether or
   not the presence document for the watcher should be constructed using
   "polite blocking".  Usage of polite blocking and the subscription
   authorization decision are specified jointly since proper privacy
   handling requires a correlation between them.  As discussed in [<a href="#ref-8" title="&quot;Common Policy: A Document Format for Expressing Privacy Preferences&quot;">8</a>],
   since the combination algorithm runs independently for each
   permission, if correlations exist between permissions, they must be
   merged into a single variable.  That is what is done here.  The
   &lt;sub-handling&gt; element is an enumerated Integer type.  The defined
   values are:

   block:  This action tells the server to reject the subscription,
      placing it in the "terminated" state.  It has the value of zero,
      and it represents the default value.  No value of the &lt;sub-
      handling&gt; element can ever be lower than this.  Strictly speaking,
      it is not necessary for a rule to include an explicit block
      action, since the default in the absence of any action will be
      block.  However, it is included for completeness.

   confirm:  This action tells the server to place the subscription in
      the "pending" state, and await input from the presentity to
      determine how to proceed.  It has a value of ten.

   polite-block:  This action tells the server to place the subscription
      into the "active" state, and to produce a presence document that
      indicates that the presentity is unavailable.  A reasonable
      document would exclude device and person information elements, and
      include only a single service whose basic status is set to closed
      [<a href="#ref-3" title="&quot;Presence Information Data Format (PIDF)&quot;">3</a>].  This action has a value of twenty.

   allow:  This action tells the server to place the subscription into
      the "active" state.  This action has a value of thirty.

      NOTE WELL: Placing a value of block for this element does not
      guarantee that a subscription is denied!  If any matching rule has
      any other value for this element, the subscription will receive
      treatment based on the maximum of those other values.  This is
      based on the combining rules defined in [<a href="#ref-8" title="&quot;Common Policy: A Document Format for Expressing Privacy Preferences&quot;">8</a>].





<span class="grey">Rosenberg                   Standards Track                     [Page 7]</span>
</pre><pre class="newpage"><a name="page-8" id="page-8" href="#page-8" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


   Future specifications that wish to define new types of actions MUST
   define an entirely new action (separate from &lt;sub-handling&gt;), and
   define their own set of values for that action.  A document could
   contain both &lt;sub-handling&gt; and a subscription handling action
   defined by a future specification; in that case, since each action is
   always a positive grant of information, the resulting action is the
   least restrictive one across both elements.

   The exact behavior of a presence server upon a change in the sub-
   handling value can be described by utilizing the subscription
   processing state machine in Figure 1 of <a href="http://tools.ietf.org/html/rfc3857">RFC 3857</a> [<a href="#ref-6" title="&quot;A Watcher Information Event Template-Package for the Session Initiation Protocol (SIP)&quot;">6</a>].

   If the &lt;sub-handling&gt; permission changes value to "block", this
   causes a "rejected" event to be generated into the subscription state
   machine for all affected subscriptions.  This will cause the state
   machine to move into the "terminated" state, resulting in the
   transmission of a NOTIFY to the watcher with a Subscription-State
   header field with value "terminated" and a reason of "rejected" [<a href="#ref-7" title="&quot;Session Initiation Protocol (SIP)-Specific Event Notification&quot;">7</a>],
   which terminates their subscription.  If a new subscription arrives
   later on, and the value of &lt;sub-handling&gt; that applies to that
   subscription is "block", the subscription processing follows the
   "subscribe, policy=reject" branch from the "init" state, and a 403
   response to the SUBSCRIBE is generated.

   If the &lt;sub-handling&gt; permission changes value to "confirm", the
   processing depends on the states of the affected subscriptions.
   Unfortunately, the state machine in <a href="http://tools.ietf.org/html/rfc3857">RFC 3857</a> does not define an event
   corresponding to an authorization decision of "pending".  If the
   subscription is in the "active" state, it moves back into the
   "pending" state.  This causes a NOTIFY to be sent, updating the
   Subscription-State [<a href="#ref-7" title="&quot;Session Initiation Protocol (SIP)-Specific Event Notification&quot;">7</a>] to "pending".  No reason is included in the
   Subscription-State header field (none are defined to handle this
   case).  No further documents are sent to this watcher.  There is no
   change in state if the subscription is in the "pending", "waiting",
   or "terminated" states.  If a new subscription arrives later on, and
   the value of &lt;sub-handling&gt; that applies to that subscription is
   "confirm", the subscription processing follows the "subscribe, no
   policy" branch from the "init" state, and a 202 response to the
   SUBSCRIBE is generated, followed by a NOTIFY with Subscription-State
   of "pending".  No presence document is included in that NOTIFY.

   If the &lt;sub-handling&gt; permission changes value from "blocked" or
   "confirm" to "polite-block" or "allow", this causes an "approved"
   event to be generated into the state machine for all affected
   subscriptions.  If the subscription was in the "pending" state, the
   state machine will move to the "active" state, resulting in the
   transmission of a NOTIFY with a Subscription-State header field of
   "active", and the inclusion of a presence document in that NOTIFY.



<span class="grey">Rosenberg                   Standards Track                     [Page 8]</span>
</pre><pre class="newpage"><a name="page-9" id="page-9" href="#page-9" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


   If the subscription was in the "waiting" state, it will move into the
   "terminated" state.  If a new subscription arrives later on, and the
   value of &lt;sub-handling&gt; that applies to that subscription is
   "polite-block" or "allow", the subscription processing follows the
   "subscribe, policy=accept" branch from the "init" state, and a 200 OK
   response to the SUBSCRIBE is generated, followed by a NOTIFY with
   Subscription-State of "active" with a presence document in the body
   of the NOTIFY.

<span class="h3"><h3><a name="section-3.3">3.3</a>.  Transformations</h3></span>

   The transformations defined here are used to drive the behavior of
   the privacy filtering operation.  Each transformation defines the
   visibility a watcher is granted to a particular component of the
   presence document.  One group of transformations grants visibility to
   person, device, and service data elements based on identifying
   information for those elements.  Another group of transformations
   provides access to particular data elements in the presence document.

<span class="h4"><h4><a name="section-3.3.1">3.3.1</a>.  Providing Access to Data Component Elements</h4></span>

   The transformations in this section provide access to person, device,
   and service data component elements.  Once access has been granted to
   such an element, access to specific presence attributes for that
   element is controlled by the permissions defined in <a href="#section-3.3.2">Section 3.3.2</a>.

<span class="h5"><h5><a name="section-3.3.1.1">3.3.1.1</a>.  Device Information</h5></span>

   The &lt;provide-devices&gt; permission allows a watcher to see &lt;device&gt;
   information present in the presence document.  It is a set variable.
   Each member of the set provides a way to identify a device or group
   of devices.  This specification defines three types of elements in
   the set - &lt;class&gt;, which identifies a device occurrence by class;
   &lt;deviceID&gt;, which identifies a device occurrence by device ID; and
   &lt;occurrence-id&gt;, which identifies a device occurrence by occurrence
   ID.  The device ID and occurrence ID are defined in [<a href="#ref-10" title="&quot;A Data Model for Presence&quot;">10</a>].  Each
   member of the set is identified by its type (class, deviceID, or
   occurrence-id) and value (value of the class, value of the deviceID,
   or value of the occurrence-id).

   For example, consider the following &lt;provide-devices&gt; element:

   &lt;provide-devices&gt;
     &lt;deviceID&gt;urn:uuid:f81d4fae-7dec-11d0-a765-00a0c91e6bf6&lt;/deviceID&gt;
     &lt;class&gt;biz&lt;/class&gt;
   &lt;/provide-devices&gt;





<span class="grey">Rosenberg                   Standards Track                     [Page 9]</span>
</pre><pre class="newpage"><a name="page-10" id="page-10" href="#page-10" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


   This set has two members.  This is combined with a &lt;provide-devices&gt;
   element from a different rule:

   &lt;provide-devices&gt;
     &lt;class&gt;home&lt;/class&gt;
     &lt;class&gt;biz&lt;/class&gt;
   &lt;/provide-devices&gt;

   The result of the set combination (using the union operation) is a
   set with three elements:

   &lt;provide-devices&gt;
     &lt;class&gt;home&lt;/class&gt;
     &lt;class&gt;biz&lt;/class&gt;
     &lt;deviceID&gt;urn:uuid:f81d4fae-7dec-11d0-a765-00a0c91e6bf6&lt;/deviceID&gt;
   &lt;/provide-devices&gt;

   The &lt;provide-devices&gt; element can also take on the special value
   &lt;all-devices&gt;, which is a short-hand notation for all device
   occurrences present in the presence document.

   Permission is granted to see a particular device occurrence if one of
   the device identifiers in the set identifies that device occurrence.
   If a &lt;class&gt; permission is granted to the watcher, and the &lt;class&gt; of
   the device occurrence matches the value of the &lt;class&gt; permission
   based on case-sensitive equality, the device occurrence is included
   in the presence document.  If a &lt;deviceID&gt; permission is granted to
   the watcher, and the &lt;deviceID&gt; of the device occurrence matches the
   value of the &lt;deviceID&gt; permission based on URI equivalence, the
   device occurrence is included in the presence document.  If an
   &lt;occurrence-id&gt; permission is granted to the watcher, and the
   &lt;occurrence-id&gt;  of the device occurrence matches the value of the
   &lt;occurrence-id&gt; permission based on case-sensitive equality, the
   device occurrence is included in the presence document.  In addition,
   a device occurrence is included in the presence document if the
   &lt;all-devices&gt; permission was granted to the watcher.

<span class="h5"><h5><a name="section-3.3.1.2">3.3.1.2</a>.  Person Information</h5></span>

   The &lt;provide-persons&gt; permission allows a watcher to see the &lt;person&gt;
   information present in the presence document.  It is a set variable.
   Each member of the set provides a way to identify a person
   occurrence.  This specification defines two types of elements in the
   set - &lt;class&gt;, which identifies a person occurrence by class, and
   &lt;occurrence-id&gt;, which identifies an occurrence by its occurrence ID.
   Each member of the set is identified by its type (class or
   occurrence-id) and value (value of the class or value of the
   occurrence-id).  The &lt;provide-persons&gt; element can also take on the



<span class="grey">Rosenberg                   Standards Track                    [Page 10]</span>
</pre><pre class="newpage"><a name="page-11" id="page-11" href="#page-11" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


   special value &lt;all-persons&gt;, which is a short-hand notation for all
   person occurrences present in the presence document.  The set
   combination is done identically to the &lt;provide-devices&gt; element.

   Permission is granted to see a particular person occurrence if one of
   the person identifiers in the set identifies that person occurrence.
   If a &lt;class&gt; permission is granted to the watcher, and the &lt;class&gt; of
   the person occurrence matches the value of the &lt;class&gt; permission
   based on case-sensitive equality, the person occurrence is included
   in the presence document.  If an &lt;occurrence-id&gt; permission is
   granted to the watcher, and the &lt;occurrence-id&gt; of the person
   occurrence matches the value of the &lt;occurrence-id&gt; permission based
   on case-sensitive equality, the person occurrence is included in the
   presence document.  In addition, a person occurrence is included in
   the presence document if the &lt;all-persons&gt; permission was granted to
   the watcher.

<span class="h5"><h5><a name="section-3.3.1.3">3.3.1.3</a>.  Service Information</h5></span>

   The &lt;provide-services&gt; permission allows a watcher to see service
   information present in &lt;tuple&gt; elements in the presence document.
   Like &lt;provide-devices&gt;, it is a set variable.  Each member of the set
   provides a way to identify a service occurrence.  This specification
   defines four types of elements in the set - &lt;class&gt;, which identifies
   a service occurrence by class; &lt;occurrence-id&gt;, which identifies a
   service by its occurrence ID; &lt;service-uri&gt;, which identifies a
   service by its service URI; and &lt;service-uri-scheme&gt;, which
   identifies a service by its service URI scheme.  Each member of the
   set is identified by its type (class, occurrence-id, service-uri, or
   service-uri-scheme) and value (value of the class, value of the
   occurrence-id, value of the service-uri, or value of the service-
   uri-scheme).  The &lt;provide-services&gt; element can also take on the
   special value &lt;all-services&gt;, which is a short-hand notation for all
   service occurrences present in the presence document.  The set
   combination is done identically to the &lt;provide-persons&gt; element.

   Permission is granted to see a particular service occurrence if one
   of the service identifiers in the set identifies that service
   occurrence.  If a &lt;class&gt; permission is granted to the watcher, and
   the &lt;class&gt; of the service occurrence matches the value of the
   &lt;class&gt; permission based on case-sensitive equality, the service
   occurrence is included in the presence document.  If a &lt;service-uri&gt;
   permission is granted to the watcher, and the &lt;service-uri&gt; of the
   service occurrence matches the value of the &lt;service-uri&gt; permission
   based on URI equivalence, the service occurrence is included in the
   presence document.  If an &lt;occurrence-id&gt; permission is granted to
   the watcher, and the &lt;occurrence-id&gt; of the service occurrence
   matches the value of the &lt;occurrence-id&gt; permission based on case-



<span class="grey">Rosenberg                   Standards Track                    [Page 11]</span>
</pre><pre class="newpage"><a name="page-12" id="page-12" href="#page-12" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


   sensitive equality, the service occurrence is included in the
   presence document.  If a &lt;service-uri-scheme&gt; permission is granted
   to the watcher, and the scheme of the service URI for the service
   occurrence matches the value of &lt;service-uri-scheme&gt; based on case-
   sensitive equality, the service occurrence is included in the
   presence document.  In addition, a service occurrence is included in
   the presence document if the &lt;all-services&gt; permission was granted to
   the watcher.

<span class="h4"><h4><a name="section-3.3.2">3.3.2</a>.  Providing Access to Presence Attributes</h4></span>

   The permissions of <a href="#section-3.3.1">Section 3.3.1</a> provide coarse-grained access to
   presence data by allowing or blocking specific services or devices,
   and allowing or blocking person information.

   Once person, device, or service information is included in the
   document, the permissions in this section define which presence
   attributes are reported there.  Certain information is always
   reported.  In particular, the &lt;contact&gt;, &lt;service-class&gt; [<a href="#ref-9" title="&quot;RPID: Rich Presence Extensions to the Presence Information Data Format (PIDF)&quot;">9</a>], &lt;basic&gt;
   status, and &lt;timestamp&gt; elements in all &lt;tuple&gt; elements, if present,
   are provided to watchers.  The &lt;timestamp&gt; element in all &lt;person&gt;
   elements, if present, is provided to watchers.  The &lt;timestamp&gt; and
   &lt;deviceID&gt; elements in all &lt;device&gt; elements, if present, are
   provided to all watchers.

<span class="h5"><h5><a name="section-3.3.2.1">3.3.2.1</a>.  Provide Activities</h5></span>

   This permission controls access to the &lt;activities&gt; element defined
   in [<a href="#ref-9" title="&quot;RPID: Rich Presence Extensions to the Presence Information Data Format (PIDF)&quot;">9</a>].  The name of the element providing this permission is
   &lt;provide-activities&gt;, and it is a Boolean type.  If its value is
   TRUE, then the &lt;activities&gt; element in the person data element is
   reported to the watcher.  If FALSE, this presence attribute is
   removed if present.

<span class="h5"><h5><a name="section-3.3.2.2">3.3.2.2</a>.  Provide Class</h5></span>

   This permission controls access to the &lt;class&gt; element defined in
   [<a href="#ref-9" title="&quot;RPID: Rich Presence Extensions to the Presence Information Data Format (PIDF)&quot;">9</a>].  The name of the element providing this permission is &lt;provide-
   class&gt;, and it is a Boolean type.  If its value is TRUE, then any
   &lt;class&gt; element in a person, service, or device data element is
   reported to the watcher.  If FALSE, this presence attribute is
   removed if present.









<span class="grey">Rosenberg                   Standards Track                    [Page 12]</span>
</pre><pre class="newpage"><a name="page-13" id="page-13" href="#page-13" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


<span class="h5"><h5><a name="section-3.3.2.3">3.3.2.3</a>.  Provide DeviceID</h5></span>

   This permission controls access to the &lt;deviceID&gt; element in a
   &lt;tuple&gt; element, as defined in [<a href="#ref-9" title="&quot;RPID: Rich Presence Extensions to the Presence Information Data Format (PIDF)&quot;">9</a>].  The name of the element
   providing this permission is &lt;provide-deviceID&gt;, and it is a Boolean
   type.  If its value is TRUE, then the &lt;deviceID&gt; element in the
   service data element is reported to the watcher.  If FALSE, this
   presence attribute is removed if present.  Note that the &lt;deviceID&gt;
   in a device data element is always included, and not controlled by
   this permission.

<span class="h5"><h5><a name="section-3.3.2.4">3.3.2.4</a>.  Provide Mood</h5></span>

   This permission controls access to the &lt;mood&gt; element defined in [<a href="#ref-9" title="&quot;RPID: Rich Presence Extensions to the Presence Information Data Format (PIDF)&quot;">9</a>].
   The name of the element providing this permission is &lt;provide-mood&gt;,
   and it is a Boolean type.  If its value is TRUE, then the &lt;mood&gt;
   element in the person data element is reported to the watcher.  If
   FALSE, this presence attribute is removed if present.

<span class="h5"><h5><a name="section-3.3.2.5">3.3.2.5</a>.  Provide Place-is</h5></span>

   This permission controls access to the &lt;place-is&gt; element defined in
   [<a href="#ref-9" title="&quot;RPID: Rich Presence Extensions to the Presence Information Data Format (PIDF)&quot;">9</a>].  The name of the element providing this permission is &lt;provide-
   place-is&gt;, and it is a Boolean type.  If its value is TRUE, then the
   &lt;place-is&gt; element in the person data element is reported to the
   watcher.  If FALSE, this presence attribute is removed if present.

<span class="h5"><h5><a name="section-3.3.2.6">3.3.2.6</a>.  Provide Place-type</h5></span>

   This permission controls access to the &lt;place-type&gt; element defined
   in [<a href="#ref-9" title="&quot;RPID: Rich Presence Extensions to the Presence Information Data Format (PIDF)&quot;">9</a>].  The name of the element providing this permission is
   &lt;provide-place-type&gt;, and it is a Boolean type.  If its value is
   TRUE, then the &lt;place-type&gt; element in the person data element is
   reported to the watcher.  If FALSE, this presence attribute is
   removed if present.

<span class="h5"><h5><a name="section-3.3.2.7">3.3.2.7</a>.  Provide Privacy</h5></span>

   This permission controls access to the &lt;privacy&gt; element defined in
   [<a href="#ref-9" title="&quot;RPID: Rich Presence Extensions to the Presence Information Data Format (PIDF)&quot;">9</a>].  The name of the element providing this permission is &lt;provide-
   privacy&gt;, and it is a Boolean type.  If its value is TRUE, then the
   &lt;privacy&gt; element in the person or service data element is reported
   to the watcher.  If FALSE, this presence attribute is removed if
   present.







<span class="grey">Rosenberg                   Standards Track                    [Page 13]</span>
</pre><pre class="newpage"><a name="page-14" id="page-14" href="#page-14" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


<span class="h5"><h5><a name="section-3.3.2.8">3.3.2.8</a>.  Provide Relationship</h5></span>

   This permission controls access to the &lt;relationship&gt; element defined
   in [<a href="#ref-9" title="&quot;RPID: Rich Presence Extensions to the Presence Information Data Format (PIDF)&quot;">9</a>].  The name of the element providing this permission is
   &lt;provide-relationship&gt;, and it is a Boolean type.  If its value is
   TRUE, then the &lt;relationship&gt; element in the service data element is
   reported to the watcher.  If FALSE, this presence attribute is
   removed if present.

<span class="h5"><h5><a name="section-3.3.2.9">3.3.2.9</a>.  Provide Sphere</h5></span>

   This permission controls access to the &lt;sphere&gt; element defined in
   [<a href="#ref-9" title="&quot;RPID: Rich Presence Extensions to the Presence Information Data Format (PIDF)&quot;">9</a>].  The name of the element providing this permission is &lt;provide-
   sphere&gt;, and it is a Boolean type.  If its value is TRUE, then the
   &lt;sphere&gt; element in the person data element is reported to the
   watcher.  If FALSE, this presence attribute is removed if present.

<span class="h5"><h5><a name="section-3.3.2.10">3.3.2.10</a>.  Provide Status-Icon</h5></span>

   This permission controls access to the &lt;status-icon&gt; element defined
   in [<a href="#ref-9" title="&quot;RPID: Rich Presence Extensions to the Presence Information Data Format (PIDF)&quot;">9</a>].  The name of the element providing this permission is
   &lt;provide-status-icon&gt;, and it is a Boolean type.  If its value is
   TRUE, then any &lt;status-icon&gt; element in the person or service data
   element is reported to the watcher.  If FALSE, this presence
   attribute is removed if present.

<span class="h5"><h5><a name="section-3.3.2.11">3.3.2.11</a>.  Provide Time-Offset</h5></span>

   This permission controls access to the &lt;time-offset&gt; element defined
   in [<a href="#ref-9" title="&quot;RPID: Rich Presence Extensions to the Presence Information Data Format (PIDF)&quot;">9</a>].  The name of the element providing this permission is
   &lt;provide-time-offset&gt;, and it is a Boolean type.  If its value is
   TRUE, then the &lt;time-offset&gt; element in the person data element is
   reported to the watcher.  If FALSE, this presence attribute is
   removed if present.

<span class="h5"><h5><a name="section-3.3.2.12">3.3.2.12</a>.  Provide User-Input</h5></span>

   This permission controls access to the &lt;user-input&gt; element defined
   in [<a href="#ref-9" title="&quot;RPID: Rich Presence Extensions to the Presence Information Data Format (PIDF)&quot;">9</a>].  The name of the element providing this permission is
   &lt;provide-user-input&gt;, and it is an enumerated integer type.  Its
   value defines what information is provided to watchers in person,
   device, or service data elements:

   false:  This value indicates that the &lt;user-input&gt; element is removed
      from the document.  It is assigned the numeric value of 0.






<span class="grey">Rosenberg                   Standards Track                    [Page 14]</span>
</pre><pre class="newpage"><a name="page-15" id="page-15" href="#page-15" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


   bare:  This value indicates that the &lt;user-input&gt; element is to be
      retained.  However, any "idle-threshold" and "since" attributes
      are to be removed.  This value is assigned the numeric value of
      10.

   thresholds:  This value indicates that the &lt;user-input&gt; element is to
      be retained.  However, only the "idle-threshold" attribute is to
      be retained.  This value is assigned the numeric value of 20.

   full:  This value indicates that the &lt;user-input&gt; element is to be
      retained, including any attributes.  This value is assigned the
      numeric value of 30.

<span class="h5"><h5><a name="section-3.3.2.13">3.3.2.13</a>.  Provide Note</h5></span>

   This permission controls access to the &lt;note&gt; element defined in [<a href="#ref-3" title="&quot;Presence Information Data Format (PIDF)&quot;">3</a>]
   for &lt;tuple&gt; and [<a href="#ref-10" title="&quot;A Data Model for Presence&quot;">10</a>] for &lt;person&gt; and &lt;device&gt;.  The name of the
   element providing this permission is &lt;provide-note&gt;, and it is a
   Boolean type.  If its value is TRUE, then any &lt;note&gt; elements in the
   person, service, or device data elements are reported to the watcher.
   If FALSE, this presence attribute is removed if present.

   This permission has no bearing on any &lt;note&gt; values present within
   &lt;activities&gt;, &lt;mood&gt;, &lt;place-is&gt;, &lt;place-type&gt;, &lt;privacy&gt;,
   &lt;relationship&gt;, or &lt;service-class&gt; elements.  Notes within these
   elements are essentially values for their respective elements, and
   are present if the respective element is permitted in the presence
   document.  For example, if an &lt;activities&gt; element is present in a
   presence document, and there is a &lt;note&gt; value for it, that note is
   present in the document sent to the watcher if the &lt;provide-
   activities&gt; permission is given, regardless of whether the &lt;provide-
   note&gt; permission is given.

<span class="h5"><h5><a name="section-3.3.2.14">3.3.2.14</a>.  Provide Unknown Attribute</h5></span>

   It is important that systems be allowed to include proprietary or new
   presence information and that users be able to set permissions for
   that information, without requiring an upgrade of the presence server
   and authorization system.  For this reason, the &lt;provide-unknown-
   attribute&gt; permission is defined.  This permission indicates that the
   unknown presence attribute with the given name and namespace
   (supplied as mandatory attributes of the &lt;provide-unknown-attribute&gt;
   element) should be included in the document.  Its type is Boolean.

   The value of the name attribute MUST be an unqualified element name
   (meaning that a namespace prefix MUST NOT be included), and the value
   of the ns attribute MUST be a namespace URI.  The two are combined to
   form a qualified element name, which will be matched to all unknown



<span class="grey">Rosenberg                   Standards Track                    [Page 15]</span>
</pre><pre class="newpage"><a name="page-16" id="page-16" href="#page-16" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


   child elements of the Presence Information Data Format (PIDF)
   &lt;tuple&gt;, &lt;device&gt;, or &lt;person&gt; elements with the same qualified name.
   In this context, "unknown" means that the presence server is not
   aware of any schemas that define authorization policies for that
   element.  By definition, this will exclude the &lt;provide-unknown-
   attribute&gt; rule from being applied to any of the presence status
   extensions defined by RPID, since authorization policies for those
   are defined here.

   Another consequence of this definition is that the interpretation of
   the &lt;provide-unknown-attribute&gt; element can change should the
   presence server be upgraded.  For example, consider a server that,
   prior to the upgrade, had an authorization document that used
   &lt;provide-unknown-attribute&gt; with a value of TRUE for some attribute,
   say foo.  This attribute was from a namespace and schema unknown to
   the server, and so the attribute was provided to watchers.  However,
   after upgrade, the server is now aware of a new namespace and schema
   for a permission that grants access to the foo attribute.  Now, the
   &lt;provide-unknown-attribute&gt; permission for the foo attribute will be
   ignored, resulting in a removal of those elements from presence
   documents sent to watchers.  The system remains privacy safe, but
   behavior might not be as expected.  Developers of systems that allow
   clients to set policies are advised to check the capabilities of the
   server (using the mechanism described in <a href="#section-8">Section 8</a>) before uploading
   a new authorization document, to make sure that the behavior will be
   as expected.

<span class="h5"><h5><a name="section-3.3.2.15">3.3.2.15</a>.  Provide All Attributes</h5></span>

   This permission grants access to all presence attributes in all of
   the person, device, and tuple elements that are present in the
   document (the ones present in the document are determined by the
   &lt;provide-persons&gt;, &lt;provide-devices&gt;, and &lt;provide-services&gt;
   permissions).  It is effectively a macro that expands into a set of
   provide-activities, provide-class, provide-deviceID, provide-mood,
   provide-place-is, provide-place-type, provide-privacy, provide-
   relationship, provide-sphere, provide-status-icon, provide-time-
   offset, provide-user-input, provide-note, and provide-unknown-
   attribute permissions such that each presence attribute in the
   document has a permission for it.  This implies that, so long as an
   entire person, service, or device occurrence is provided, every
   single presence attribute, including ones not known to the server
   and/or defined in future presence document extensions, is granted to
   the watcher.







<span class="grey">Rosenberg                   Standards Track                    [Page 16]</span>
</pre><pre class="newpage"><a name="page-17" id="page-17" href="#page-17" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


<span class="h2"><h2><a name="section-4">4</a>.  When to Apply the Authorization Policies</h2></span>

   This specification does not mandate at what point in the processing
   of presence data the privacy filtering aspects of the authorization
   policy are applied.  However, they must be applied such that the
   final presence document sent to the watcher is compliant to the
   privacy policy described in the authorization documents that apply to
   the user (there can be more than one; the rules for combining them
   are described in [<a href="#ref-8" title="&quot;Common Policy: A Document Format for Expressing Privacy Preferences&quot;">8</a>]).  More concretely, if the presence document
   sent to a watcher is D, and the privacy filtering operation applied
   do a presence document x is F(x), then D MUST have the property that
   D = F(D).  In other words, further applications of the privacy
   filtering operation would not result in any further changes of the
   presence document, making further application of the filtering
   operation a no-op.  A corollary of this is that F(F(D)) = D for all
   D.

   The subscription processing aspects of the document get applied by
   the server when it decides to accept or reject the subscription.

<span class="h2"><h2><a name="section-5">5</a>.  Implementation Requirements</h2></span>

   The rules defined by the document in this specification form a
   "contract" of sorts between a client that creates this document and
   the server that executes the policies it contains.  Consequently,
   presence servers implementing this specification MUST support all of
   the conditions, actions, and transformations defined in this
   specification.  If servers were to implement a subset of these,
   clients would need a mechanism to discover which subset is supported.
   No such mechanism is defined.

   It is RECOMMENDED that clients support all of the actions,
   transformations, and conditions defined in this specification.  If a
   client supports a subset, it is possible that a user might manipulate
   their authorization rules from a different client, supporting a
   different subset, and store those results on the server.  When the
   user goes back to the first client and views their presence
   authorization rules there, the client may not be able to properly
   render or manipulate the document retrieved from the server, since it
   may contain conditions, actions, or transformations not supported by
   the client.  The only reason that this normative requirement is not a
   MUST is that there are valid conditions in which a user manipulates
   their presence authorization rules from a single client, in which
   case this problem does not occur.

   This specification makes no normative recommendations on the
   mechanism used to transport presence authorization documents from




<span class="grey">Rosenberg                   Standards Track                    [Page 17]</span>
</pre><pre class="newpage"><a name="page-18" id="page-18" href="#page-18" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


   clients to their servers.  Although <a href="#section-9">Section 9</a> defines how to utilize
   XCAP, XCAP is not normatively required by this specification.

<span class="h2"><h2><a name="section-6">6</a>.  Example Document</h2></span>

   The following presence authorization document specifies permissions
   for the user "user@example.com".  The watcher is allowed to access
   presence information (the 'allow' value for &lt;sub-handling&gt;).  They
   will be granted access to the presence data of all services whose
   contact URI schemes are sip and mailto.  Person information is also
   provided.  However, since there is no &lt;provide-devices&gt;, no device
   information will be given to the watcher.  Within the service and
   person information provided to the watcher, the &lt;activities&gt; element
   will be shown, as will the &lt;user-input&gt; element.  However, any
   "idle-threshold" and "since" attributes in the &lt;user-input&gt; element
   will be removed.  Finally, the presence attribute &lt;foo&gt; will be shown
   to the watcher.  Any other presence attributes will be removed.

   &lt;?xml version="1.0" encoding="UTF-8"?&gt;
   &lt;cr:ruleset xmlns="urn:ietf:params:xml:ns:pres-rules"
    xmlns:pr="urn:ietf:params:xml:ns:pres-rules"
    xmlns:cr="urn:ietf:params:xml:ns:common-policy"&gt;
    &lt;cr:rule id="a"&gt;
     &lt;cr:conditions&gt;
      &lt;cr:identity&gt;
       &lt;cr:one id="sip:user@example.com"/&gt;
      &lt;/cr:identity&gt;
     &lt;/cr:conditions&gt;
     &lt;cr:actions&gt;
      &lt;pr:sub-handling&gt;allow&lt;/pr:sub-handling&gt;
     &lt;/cr:actions&gt;
     &lt;cr:transformations&gt;
      &lt;pr:provide-services&gt;
        &lt;pr:service-uri-scheme&gt;sip&lt;/pr:service-uri-scheme&gt;
        &lt;pr:service-uri-scheme&gt;mailto&lt;/pr:service-uri-scheme&gt;
      &lt;/pr:provide-services&gt;
      &lt;pr:provide-persons&gt;
        &lt;pr:all-persons/&gt;
      &lt;/pr:provide-persons&gt;
      &lt;pr:provide-activities&gt;true&lt;/pr:provide-activities&gt;
      &lt;pr:provide-user-input&gt;bare&lt;/pr:provide-user-input&gt;
       &lt;pr:provide-unknown-attribute
        ns="urn:vendor-specific:foo-namespace"
        name="foo"&gt;true&lt;/pr:provide-unknown-attribute&gt;
     &lt;/cr:transformations&gt;
    &lt;/cr:rule&gt;
   &lt;/cr:ruleset&gt;




<span class="grey">Rosenberg                   Standards Track                    [Page 18]</span>
</pre><pre class="newpage"><a name="page-19" id="page-19" href="#page-19" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


<span class="h2"><h2><a name="section-7">7</a>.  XML Schema</h2></span>

   &lt;?xml version="1.0" encoding="UTF-8"?&gt;
   &lt;xs:schema targetNamespace="urn:ietf:params:xml:ns:pres-rules"
    xmlns:xs="http://www.w3.org/2001/XMLSchema"
    xmlns:cr="urn:ietf:params:xml:ns:common-policy"
    xmlns:pr="urn:ietf:params:xml:ns:pres-rules"
    elementFormDefault="qualified" attributeFormDefault="unqualified"&gt;
    &lt;xs:import namespace="urn:ietf:params:xml:ns:common-policy"/&gt;
    &lt;xs:simpleType name="booleanPermission"&gt;
     &lt;xs:restriction base="xs:boolean"/&gt;
    &lt;/xs:simpleType&gt;
    &lt;xs:element name="service-uri-scheme" type="xs:token"/&gt;
    &lt;xs:element name="class" type="xs:token"/&gt;
    &lt;xs:element name="occurrence-id" type="xs:token"/&gt;
    &lt;xs:element name="service-uri" type="xs:anyURI"/&gt;
    &lt;xs:complexType name="provideServicePermission"&gt;
     &lt;xs:choice&gt;
      &lt;xs:element name="all-services"&gt;
       &lt;xs:complexType/&gt;
      &lt;/xs:element&gt;
      &lt;xs:sequence minOccurs="0" maxOccurs="unbounded"&gt;
       &lt;xs:choice&gt;
        &lt;xs:element ref="pr:service-uri"/&gt;
        &lt;xs:element ref="pr:service-uri-scheme"/&gt;
        &lt;xs:element ref="pr:occurrence-id"/&gt;
        &lt;xs:element ref="pr:class"/&gt;
        &lt;xs:any namespace="##other" processContents="lax"/&gt;
       &lt;/xs:choice&gt;
      &lt;/xs:sequence&gt;
     &lt;/xs:choice&gt;
    &lt;/xs:complexType&gt;
    &lt;xs:element name="provide-services"
     type="pr:provideServicePermission"/&gt;
    &lt;xs:element name="deviceID" type="xs:anyURI"/&gt;
    &lt;xs:complexType name="provideDevicePermission"&gt;
     &lt;xs:choice&gt;
      &lt;xs:element name="all-devices"&gt;
       &lt;xs:complexType/&gt;
      &lt;/xs:element&gt;
      &lt;xs:sequence minOccurs="0" maxOccurs="unbounded"&gt;
       &lt;xs:choice&gt;
        &lt;xs:element ref="pr:deviceID"/&gt;
        &lt;xs:element ref="pr:occurrence-id"/&gt;
        &lt;xs:element ref="pr:class"/&gt;
        &lt;xs:any namespace="##other" processContents="lax"/&gt;
       &lt;/xs:choice&gt;
      &lt;/xs:sequence&gt;



<span class="grey">Rosenberg                   Standards Track                    [Page 19]</span>
</pre><pre class="newpage"><a name="page-20" id="page-20" href="#page-20" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


     &lt;/xs:choice&gt;
    &lt;/xs:complexType&gt;
    &lt;xs:element name="provide-devices"
     type="pr:provideDevicePermission"/&gt;
    &lt;xs:complexType name="providePersonPermission"&gt;
     &lt;xs:choice&gt;
      &lt;xs:element name="all-persons"&gt;
       &lt;xs:complexType/&gt;
      &lt;/xs:element&gt;
      &lt;xs:sequence minOccurs="0" maxOccurs="unbounded"&gt;
       &lt;xs:choice&gt;
        &lt;xs:element ref="pr:occurrence-id"/&gt;
        &lt;xs:element ref="pr:class"/&gt;
        &lt;xs:any namespace="##other" processContents="lax"/&gt;
       &lt;/xs:choice&gt;
      &lt;/xs:sequence&gt;
     &lt;/xs:choice&gt;
    &lt;/xs:complexType&gt;
    &lt;xs:element name="provide-persons"
     type="pr:providePersonPermission"/&gt;
    &lt;xs:element name="provide-activities"
     type="pr:booleanPermission"/&gt;
    &lt;xs:element name="provide-class"
     type="pr:booleanPermission"/&gt;
    &lt;xs:element name="provide-deviceID"
     type="pr:booleanPermission"/&gt;
    &lt;xs:element name="provide-mood"
     type="pr:booleanPermission"/&gt;
    &lt;xs:element name="provide-place-is"
     type="pr:booleanPermission"/&gt;
    &lt;xs:element name="provide-place-type"
     type="pr:booleanPermission"/&gt;
    &lt;xs:element name="provide-privacy"
     type="pr:booleanPermission"/&gt;
    &lt;xs:element name="provide-relationship"
     type="pr:booleanPermission"/&gt;
    &lt;xs:element name="provide-status-icon"
     type="pr:booleanPermission"/&gt;
    &lt;xs:element name="provide-sphere"
     type="pr:booleanPermission"/&gt;
    &lt;xs:element name="provide-time-offset"
     type="pr:booleanPermission"/&gt;
    &lt;xs:element name="provide-user-input"&gt;
     &lt;xs:simpleType&gt;
      &lt;xs:restriction base="xs:string"&gt;
       &lt;xs:enumeration value="false"/&gt;
       &lt;xs:enumeration value="bare"/&gt;
       &lt;xs:enumeration value="thresholds"/&gt;



<span class="grey">Rosenberg                   Standards Track                    [Page 20]</span>
</pre><pre class="newpage"><a name="page-21" id="page-21" href="#page-21" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


       &lt;xs:enumeration value="full"/&gt;
      &lt;/xs:restriction&gt;
     &lt;/xs:simpleType&gt;
    &lt;/xs:element&gt;
    &lt;xs:element name="provide-note" type="pr:booleanPermission"/&gt;
    &lt;xs:element name="sub-handling"&gt;
     &lt;xs:simpleType&gt;
      &lt;xs:restriction base="xs:token"&gt;
       &lt;xs:enumeration value="block"/&gt;
       &lt;xs:enumeration value="confirm"/&gt;
       &lt;xs:enumeration value="polite-block"/&gt;
       &lt;xs:enumeration value="allow"/&gt;
      &lt;/xs:restriction&gt;
     &lt;/xs:simpleType&gt;
    &lt;/xs:element&gt;
    &lt;xs:complexType name="unknownBooleanPermission"&gt;
     &lt;xs:simpleContent&gt;
      &lt;xs:extension base="pr:booleanPermission"&gt;
       &lt;xs:attribute name="name" type="xs:string" use="required"/&gt;
       &lt;xs:attribute name="ns" type="xs:string" use="required"/&gt;
      &lt;/xs:extension&gt;
     &lt;/xs:simpleContent&gt;
    &lt;/xs:complexType&gt;
    &lt;xs:element name="provide-unknown-attribute"
     type="pr:unknownBooleanPermission"/&gt;
    &lt;xs:element name="provide-all-attributes"&gt;
     &lt;xs:complexType/&gt;
    &lt;/xs:element&gt;
   &lt;/xs:schema&gt;

<span class="h2"><h2><a name="section-8">8</a>.  Schema Extensibility</h2></span>

   It is anticipated that future changes to this specification are
   accomplished through extensions that define new types of permissions.
   These extensions MUST exist within a different namespace.
   Furthermore, the schema defined above and the namespace for elements
   defined within it MUST NOT be altered by future specifications.
   Changes in the basic schema, or in the interpretation of elements
   within that schema, may result in violations of user privacy due to
   misinterpretation of documents.

   When extensions are made to the set of permissions, it becomes
   necessary for the agent constructing the permission document
   (typically a SIP user agent, though not necessarily) to know which
   permissions are supported by the server.  This allows the agent to
   know how to build a document that results in the desired behavior,
   since unknown permissions would be ignored by the server.  To handle
   this, when presence authorization documents are transported using



<span class="grey">Rosenberg                   Standards Track                    [Page 21]</span>
</pre><pre class="newpage"><a name="page-22" id="page-22" href="#page-22" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


   XCAP, the XCAP capabilities document stored at the server SHOULD
   contain the namespaces for the permissions supported by the presence
   server.  This way, an agent can query for this list prior to
   constructing a document.

<span class="h2"><h2><a name="section-9">9</a>.  XCAP Usage</h2></span>

   The following section defines the details necessary for clients to
   manipulate presence authorization documents from a server using XCAP.

<span class="h3"><h3><a name="section-9.1">9.1</a>.  Application Unique ID</h3></span>

   XCAP requires application usages to define a unique application usage
   ID (AUID) in either the IETF tree or a vendor tree.  This
   specification defines the "pres-rules" AUID within the IETF tree, via
   the IANA registration in <a href="#section-11">Section 11</a>.

<span class="h3"><h3><a name="section-9.2">9.2</a>.  XML Schema</h3></span>

   XCAP requires application usages to define a schema for their
   documents.  The schema for presence authorization documents is in
   <a href="#section-7">Section 7</a>.

<span class="h3"><h3><a name="section-9.3">9.3</a>.  Default Namespace</h3></span>

   XCAP requires application usages to define the default namespace for
   their URIs.  The default namespace is urn:ietf:params:xml:ns:pres-
   rules.

<span class="h3"><h3><a name="section-9.4">9.4</a>.  MIME Type</h3></span>

   XCAP requires application usages to define the MIME type for
   documents they carry.  Presence authorization documents inherit the
   MIME type of common policy documents, application/auth-policy+xml.

<span class="h3"><h3><a name="section-9.5">9.5</a>.  Validation Constraints</h3></span>

   There are no additional constraints defined by this specification.

<span class="h3"><h3><a name="section-9.6">9.6</a>.  Data Semantics</h3></span>

   Semantics of a presence authorization document are discussed in
   <a href="#section-3">Section 3</a>.








<span class="grey">Rosenberg                   Standards Track                    [Page 22]</span>
</pre><pre class="newpage"><a name="page-23" id="page-23" href="#page-23" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


<span class="h3"><h3><a name="section-9.7">9.7</a>.  Naming Conventions</h3></span>

   When a presence agent receives a subscription for some user foo
   within a domain, it will look for all documents within http://[xcap
   root]/pres-rules/users/foo, and use all documents found beneath that
   point to guide authorization policy.  If only a single document is
   used, it SHOULD be called "index".

<span class="h3"><h3><a name="section-9.8">9.8</a>.  Resource Interdependencies</h3></span>

   There are no additional resource interdependencies defined by this
   application usage.

<span class="h3"><h3><a name="section-9.9">9.9</a>.  Authorization Policies</h3></span>

   This application usage does not modify the default XCAP authorization
   policy, which is that only a user can read, write, or modify their
   own documents.  A server can allow privileged users to modify
   documents that they don't own, but the establishment and indication
   of such policies are outside the scope of this document.

<span class="h2"><h2><a name="section-10">10</a>.  Security Considerations</h2></span>

   Presence authorization policies contain very sensitive information.
   They indicate which other users are "liked" or "disliked" by a user.
   As such, when these documents are transported over a network, they
   SHOULD be encrypted.

   Modification of these documents by an attacker can disrupt the
   service seen by a user, often in subtle ways.  As a result, when
   these documents are transported, the transport SHOULD provide
   authenticity and message integrity.

   In the case where XCAP is used to transfer the document, both clients
   and servers MUST implement HTTP over Transport Layer Security (TLS)
   and HTTP Digest authentication.  Sites SHOULD authenticate clients
   using digest authentication over TLS, and sites SHOULD define the
   root services URI as an https URI.

   Authorization documents themselves exist for the purposes of
   providing a security function - privacy.  The SIP presence
   specifications [<a href="#ref-18" title="&quot;A Presence Event Package for the Session Initiation Protocol (SIP)&quot;">18</a>] require the usage of an authorization function
   prior to the granting of presence information, and this specification
   meets that need.  Presence authorization documents inherit the
   privacy properties of the common policy format on which they are
   based.  This format has been designed to be privacy-safe, which means
   that failure of the presence server to obtain or understand an
   authorization document can never reveal more information than is



<span class="grey">Rosenberg                   Standards Track                    [Page 23]</span>
</pre><pre class="newpage"><a name="page-24" id="page-24" href="#page-24" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


   desired about the user, only less.  This is a consequence of the fact
   that all permissions are positive grants of information, and not
   negative grants.

   A consequence of this design is that the results of combining several
   authorization documents can be non-obvious to end users.  For
   example, if one authorization document grants permission for all
   users from the example.com domain to see their presence, and another
   document blocks joe@example.com, the combination of these will still
   provide presence to joe@example.com.  Designers of user interfaces
   are encouraged to carefully pay attention to the results of combining
   multiple rules.

   Another concern is cases where a user sets their privacy preferences
   from one client, uploads their presence authorization document to a
   server, and then modifies them from a different client.  If the
   clients support different subsets of the document format, users may
   be confused about what information is being revealed.  Clients
   retrieving presence authorization documents from a server SHOULD
   render, to the users, information about rules that they do not
   understand, so that users can be certain what rules are in place.

<span class="h2"><h2><a name="section-11">11</a>.  IANA Considerations</h2></span>

   There are several IANA considerations associated with this
   specification.

<span class="h3"><h3><a name="section-11.1">11.1</a>.  XCAP Application Usage ID</h3></span>

   This section registers an XCAP Application Usage ID (AUID) according
   to the IANA procedures defined in [<a href="#ref-2" title="&quot;The Extensible Markup Language (XML) Configuration Access Protocol (XCAP)&quot;">2</a>].

      Name of the AUID: pres-rules

      Description: Presence rules are documents that describe the
      permissions that a presentity [<a href="#ref-17" title="&quot;A Model for Presence and Instant Messaging&quot;">17</a>] has granted to users that seek
      to watch their presence.














<span class="grey">Rosenberg                   Standards Track                    [Page 24]</span>
</pre><pre class="newpage"><a name="page-25" id="page-25" href="#page-25" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


<span class="h3"><h3><a name="section-11.2">11.2</a>.  URN Sub-Namespace Registration</h3></span>

   This section registers a new XML namespace, per the guidelines in
   [<a href="#ref-11" title="&quot;The IETF XML Registry&quot;">11</a>]

      URI: The URI for this namespace is
      urn:ietf:params:xml:ns:pres-rules.

      Registrant Contact: IETF, SIMPLE working group (simple@ietf.org),
      Jonathan Rosenberg (jdrosen@jdrosen.net).

      XML:

      BEGIN

      &lt;?xml version="1.0"?&gt;
      &lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML Basic 1.0//EN"
       "<a href="http://www.w3.org/TR/xhtml-basic/xhtml-basic10.dtd">http://www.w3.org/TR/xhtml-basic/xhtml-basic10.dtd</a>"&gt;
      &lt;html xmlns="http://www.w3.org/1999/xhtml"&gt;
      &lt;head&gt;
        &lt;meta http-equiv="content-type"
           content="text/html;charset=iso-8859-1"/&gt;
        &lt;title&gt;Presence Rules Namespace&lt;/title&gt;
      &lt;/head&gt;
      &lt;body&gt;
        &lt;h1&gt;Namespace for Permission Statements&lt;/h1&gt;
        &lt;h2&gt;urn:ietf:params:xml:ns:pres-rules&lt;/h2&gt;
      &lt;p&gt;See &lt;a href="http://www.rfc-editor.org/rfc/rfc5025.txt"&gt;
      <a href="http://tools.ietf.org/html/rfc5025">RFC5025</a>&lt;/a&gt;.&lt;/p&gt;
      &lt;/body&gt;
      &lt;/html&gt;
      END

<span class="h3"><h3><a name="section-11.3">11.3</a>.  XML Schema Registrations</h3></span>

   This section registers an XML schema per the procedures in [<a href="#ref-11" title="&quot;The IETF XML Registry&quot;">11</a>].

      URI: urn:ietf:params:xml:schema:pres-rules.

      Registrant Contact: IETF, SIMPLE working group (simple@ietf.org),
      Jonathan Rosenberg (jdrosen@jdrosen.net).

      The XML for this schema can be found as the sole content of
      <a href="#section-7">Section 7</a>.







<span class="grey">Rosenberg                   Standards Track                    [Page 25]</span>
</pre><pre class="newpage"><a name="page-26" id="page-26" href="#page-26" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


<span class="h2"><h2><a name="section-12">12</a>.  Acknowledgements</h2></span>

   The author would like to thank Richard Barnes, Jari Urpalainen, Jon
   Peterson, and Martin Hynar for their comments.

<span class="h2"><h2><a name="section-13">13</a>.  References</h2></span>

<span class="h3"><h3><a name="section-13.1">13.1</a>.  Normative References</h3></span>

   [<a name="ref-1" id="ref-1">1</a>]  Bradner, S., "Key words for use in RFCs to Indicate Requirement
        Levels", <a href="http://tools.ietf.org/html/bcp14">BCP 14</a>, <a href="http://tools.ietf.org/html/rfc2119">RFC 2119</a>, March 1997.

   [<a name="ref-2" id="ref-2">2</a>]  Rosenberg, J., "The Extensible Markup Language (XML)
        Configuration Access Protocol (XCAP)", <a href="http://tools.ietf.org/html/rfc4825">RFC 4825</a>, May 2007.

   [<a name="ref-3" id="ref-3">3</a>]  Sugano, H., Fujimoto, S., Klyne, G., Bateman, A., Carr, W., and
        J. Peterson, "Presence Information Data Format (PIDF)", <a href="http://tools.ietf.org/html/rfc3863">RFC</a>
        <a href="http://tools.ietf.org/html/rfc3863">3863</a>, August 2004.

   [<a name="ref-4" id="ref-4">4</a>]  Franks, J., Hallam-Baker, P., Hostetler, J., Lawrence, S.,
        Leach, P., Luotonen, A., and L. Stewart, "HTTP Authentication:
        Basic and Digest Access Authentication", <a href="http://tools.ietf.org/html/rfc2617">RFC 2617</a>, June 1999.

   [<a name="ref-5" id="ref-5">5</a>]  Rosenberg, J., Schulzrinne, H., Camarillo, G., Johnston, A.,
        Peterson, J., Sparks, R., Handley, M., and E. Schooler, "SIP:
        Session Initiation Protocol", <a href="http://tools.ietf.org/html/rfc3261">RFC 3261</a>, June 2002.

   [<a name="ref-6" id="ref-6">6</a>]  Rosenberg, J., "A Watcher Information Event Template-Package for
        the Session Initiation Protocol (SIP)", <a href="http://tools.ietf.org/html/rfc3857">RFC 3857</a>, August 2004.

   [<a name="ref-7" id="ref-7">7</a>]  Roach, A., "Session Initiation Protocol (SIP)-Specific Event
        Notification", <a href="http://tools.ietf.org/html/rfc3265">RFC 3265</a>, June 2002.

   [<a name="ref-8" id="ref-8">8</a>]  Schulzrinne, H., Tschofenig, H., Morris, J., Cuellar, J., Polk,
        J., and J. Rosenberg, "Common Policy: A Document Format for
        Expressing Privacy Preferences", <a href="http://tools.ietf.org/html/rfc4745">RFC 4745</a>, February 2007.

   [<a name="ref-9" id="ref-9">9</a>]  Schulzrinne, H., Gurbani, V., Kyzivat, P., and J. Rosenberg,
        "RPID: Rich Presence Extensions to the Presence Information Data
        Format (PIDF)", <a href="http://tools.ietf.org/html/rfc4480">RFC 4480</a>, July 2006.

   [<a name="ref-10" id="ref-10">10</a>] Rosenberg, J., "A Data Model for Presence", <a href="http://tools.ietf.org/html/rfc4479">RFC 4479</a>, July 2006.

   [<a name="ref-11" id="ref-11">11</a>] Mealling, M., "The IETF XML Registry", <a href="http://tools.ietf.org/html/bcp81">BCP 81</a>, <a href="http://tools.ietf.org/html/rfc3688">RFC 3688</a>, January
        2004.

   [<a name="ref-12" id="ref-12">12</a>] Schulzrinne, H., "The tel URI for Telephone Numbers", <a href="http://tools.ietf.org/html/rfc3966">RFC 3966</a>,
        December 2004.



<span class="grey">Rosenberg                   Standards Track                    [Page 26]</span>
</pre><pre class="newpage"><a name="page-27" id="page-27" href="#page-27" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


   [<a name="ref-13" id="ref-13">13</a>] Duerst, M. and M. Suignard, "Internationalized Resource
        Identifiers (IRIs)", <a href="http://tools.ietf.org/html/rfc3987">RFC 3987</a>, January 2005.

   [<a name="ref-14" id="ref-14">14</a>] Peterson, J., "A Privacy Mechanism for the Session Initiation
        Protocol (SIP)", <a href="http://tools.ietf.org/html/rfc3323">RFC 3323</a>, November 2002.

<span class="h3"><h3><a name="section-13.2">13.2</a>.  Informative References</h3></span>

   [<a name="ref-15" id="ref-15">15</a>] Peterson, J. and C. Jennings, "Enhancements for Authenticated
        Identity Management in the Session Initiation Protocol (SIP)",
        <a href="http://tools.ietf.org/html/rfc4474">RFC 4474</a>, August 2006.

   [<a name="ref-16" id="ref-16">16</a>] Jennings, C., Peterson, J., and M. Watson, "Private Extensions
        to the Session Initiation Protocol (SIP) for Asserted Identity
        within Trusted Networks", <a href="http://tools.ietf.org/html/rfc3325">RFC 3325</a>, November 2002.

   [<a name="ref-17" id="ref-17">17</a>] Day, M., Rosenberg, J., and H. Sugano, "A Model for Presence and
        Instant Messaging", <a href="http://tools.ietf.org/html/rfc2778">RFC 2778</a>, February 2000.

   [<a name="ref-18" id="ref-18">18</a>] Rosenberg, J., "A Presence Event Package for the Session
        Initiation Protocol (SIP)", <a href="http://tools.ietf.org/html/rfc3856">RFC 3856</a>, August 2004.

Author's Address

   Jonathan Rosenberg
   Cisco
   Edison, NJ
   US

   EMail: jdrosen@cisco.com
   URI:   <a href="http://www.jdrosen.net/">http://www.jdrosen.net</a>




















<span class="grey">Rosenberg                   Standards Track                    [Page 27]</span>
</pre><pre class="newpage"><a name="page-28" id="page-28" href="#page-28" class="invisible"> </a>
<span class="grey"><a href="http://tools.ietf.org/html/rfc5025">RFC 5025</a>                 Presence Authorization            December 2007</span>


Full Copyright Statement

   Copyright (C) The IETF Trust (2007).

   This document is subject to the rights, licenses and restrictions
   contained in <a href="http://tools.ietf.org/html/bcp78">BCP 78</a>, 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 <a href="http://tools.ietf.org/html/bcp78">BCP 78</a> and <a href="http://tools.ietf.org/html/bcp79">BCP 79</a>.

   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
   <a href="http://www.ietf.org/ipr">http://www.ietf.org/ipr</a>.

   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.












Rosenberg                   Standards Track                    [Page 28]
</pre><pre class="newpage">
</pre><br>
<span class="noprint"><small><small>Html markup produced by rfcmarkup 1.83, available from
<a href="http://tools.ietf.org/tools/rfcmarkup/">http://tools.ietf.org/tools/rfcmarkup/</a>
</small></small></span>
</body></html>