<?xml version="1.0" encoding="UTF-8"?>
  <?xml-stylesheet type="text/xsl" href="rfc2629.xslt" ?>
  <!-- generated by https://github.com/cabo/kramdown-rfc2629 version 1.0.30 -->

<!DOCTYPE rfc SYSTEM "rfc2629.dtd" [
<!ENTITY RFC3261 SYSTEM "http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.3261.xml">
<!ENTITY RFC5234 SYSTEM "http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.5234.xml">
<!ENTITY RFC3515 SYSTEM "http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.3515.xml">
<!ENTITY RFC5002 SYSTEM "http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.5002.xml">
<!ENTITY RFC5318 SYSTEM "http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.5318.xml">
<!ENTITY RFC5360 SYSTEM "http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.5360.xml">
<!ENTITY RFC5502 SYSTEM "http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.5502.xml">
]>

<?rfc toc="yes"?>

<rfc ipr="trust200902" docName="draft-sparks-sipcore-name-addr-guidance-00" category="std" updates="3261, 3515, 5002, 5318, 5360, 5502">

  <front>
    <title abbrev="Name-addr Clarifications">Clarifications for when to use the name-addr production in SIP messages</title>

    <author initials="R." surname="Sparks" fullname="Robert Sparks">
      <organization>Oracle</organization>
      <address>
        <email>rjsparks@nostrum.com</email>
      </address>
    </author>

    <date year="2016" month="June" day="07"/>

    
    
    

    <abstract>


<t>RFC3261 constrained several SIP header fields whose grammar contains 
the “name-addr / addr-spec” alternative to use name-addr when certain
characters appear. Unfortunately it expressed the constraints with
prose copied into each header field definition, and at least one
header field was missed. Further, the constraint has not been 
copied into documents defining extension headers whose grammar 
contains the alternative.</t>

<t>This document updates RFC3261 to state the constraint generically,
and clarifies that the constraint applies to all SIP header fields 
where there is a choice between using name-addr or addr-spec. 
It also updates those extension SIP header fields that use the alternative
to clarify that the constraint applies (RFCs 3261, 3515, 5002, 5318, 5360,
and 5502).</t>



    </abstract>


  </front>

  <middle>


<section anchor="introduction" title="Introduction">

<t><xref target="RFC3261"/> defines several header fields that contain URIs to allow
both a form that contains the bare URI (addr-spec) and one that provides
a name and the URI (name-addr). This subset, taken from the ABNF <xref target="RFC5234"/> 
specified in <xref target="RFC3261"/> shows the relevant part of the definition of the 
syntax of the “From” header field:</t>

<figure><artwork><![CDATA[
  From        =  ( "From" / "f" ) HCOLON from-spec
  from-spec   =  ( name-addr / addr-spec )
                 *( SEMI from-param )
  name-addr      =  [ display-name ] LAQUOT addr-spec RAQUOT
  addr-spec      =  SIP-URI / SIPS-URI / absoluteURI
]]></artwork></figure>

<t>The prose in section 20.20 of <xref target="RFC3261"/>, which discusses the “From” 
header field, constrains how the production may be used by saying:</t>

<figure><artwork><![CDATA[
   Even if the "display-name" is empty, the "name-addr" form 
   MUST be used if the "addr-spec" contains a comma, question 
   mark, or semicolon.
]]></artwork></figure>

<t>Section 20.39, which discusses the “To” header field contains no such
constraining text.</t>

<t>This constraint is specified slightly differently, but with the same intent,
in the introduction to section 20:</t>

<figure><artwork><![CDATA[
  The Contact, From, and To header fields contain a URI.  If the URI
  contains a comma, question mark or semicolon, the URI MUST be
  enclosed in angle brackets (< and >). 
]]></artwork></figure>

<t>Unfortunately, this can be read to only apply to the Contact, From, and To
header fields, making it necessary to provide the constraint explicitly
in the prose discussing any other header field using the name-addr or 
addr-spec alternative.</t>

<t>As extension header fields were standardized, the specifications sometimes
failed to include the constraint. Many errata have been entered to correct
this omission. When the constraint was called out, the form has not been
consistent.</t>

<t>This memo updates the specifications of SIP and its extensions to clarify that
the constraint to use the name-addr form applies anywhere there is a choice
between the name-addr and addr-spec production rules in the grammar for SIP
header fields.</t>

<t>It is important to note that a message formed without honoring the constraint
will still be syntactically valid, but would be interpreted differently. The
characters after the comma, question mark, or semicolon would be interpreted
as header field parameters or additional header field values as discussed in
section 7.3.1 of <xref target="RFC3261"/>.</t>

</section>
<section anchor="updates-to-rfc3261" title="Updates to RFC3261">

<t>This text from the introduction to section 20 of <xref target="RFC3261"/>:</t>

<figure><artwork><![CDATA[
  The Contact, From, and To header fields contain a URI.  If the URI
  contains a comma, question mark or semicolon, the URI MUST be
  enclosed in angle brackets (< and >).
]]></artwork></figure>

<t>is replaced with:</t>

<figure><artwork><![CDATA[
  When constructing the value of any SIP header field whose grammar 
  allows choosing between name-addr and addr-spec, such as those 
  that use the form '(name-addr / addr-spec)', the "addr-spec" form
  MUST NOT be used if its value would contain a comma, semicolon,
  or question mark.

  The header fields defined in this specification that allow this
  choice are "To", "From", "Contact",  and "Reply-To".
]]></artwork></figure>

</section>
<section anchor="updates-to-rfcs-defining-sip-extension-header-fields" title="Updates to RFCs defining SIP Extension header fields">

<t><xref target="RFC3515"/>, <xref target="RFC5002"/>, <xref target="RFC5318"/>, <xref target="RFC5360"/>, and <xref target="RFC5502"/>
are updated to include:</t>

<figure><artwork><![CDATA[
  This RFC contains the definition of one or more SIP header fields
  that allow choosing between addr-spec and name-addr when
  constructing header field values. As specified in RFCxxxx,
  the "addr-spec" form MUST NOT be used if its value would contain
  a comma, semicolon, or question mark.
]]></artwork></figure>

</section>
<section anchor="iana-considerations" title="IANA Considerations">

<t>This memo has no considerations for IANA.</t>

</section>
<section anchor="security-considerations" title="Security Considerations">

<t>The updates specified in this memo clarify a constraint on the grammar for
producing SIP messages. It introduces no new security considerations. One
pre-existing consideration is worth reiterating: messages produced without
honoring the constraint will be mis-interpreted by the receiving element.</t>

</section>
<section anchor="acknowledgments" title="Acknowledgments">

<t>Brett Tate identified this issue in several extension documents, submitted
several corresponding errata, and drove the discussion that led to this memo.
Substantive comments leading to this text were provided by Paul Kyzivat,
Gonzalo Camarillo, and Dale Worley.</t>

</section>
<section anchor="instructions-to-the-rfc-editor" title="Instructions to the RFC Editor">

<t>Please remove this section in its entirety before publication as an RFC.</t>

<t>Please replace any instances of RFCxxxx with the RFC number assigned to this memo.</t>

<t>This memo, if it is approved, obviates Errata 3744, 3894, and 4648-4652 inclusive.</t>

</section>


  </middle>

  <back>

    <references title='Normative References'>

&RFC3261;
&RFC5234;
&RFC3515;
&RFC5002;
&RFC5318;
&RFC5360;
&RFC5502;


    </references>




  </back>
</rfc>

