Subject: RE: [SIP] Syntax for To: and From: An ambiguity ?

From: Peter Kjellerstedt <[email-masked]>
Date: Fri, 12 Jan 2001 08:32:16 +0100

Actually, all of the following headers mean exactly the same
(even though the fourth version is probably the recommended
one for readability):

To: sip:[email-masked];tag=9
To: sip:[email-masked];   tag=9
To: sip:[email-masked]   ;tag=9
To: <sip:[email-masked]>;tag=9

I.e., as soon as we see something that is not allowed in
a URL when parsing a header (in this example a semicolon,
white space or the end angle bracket) we are done with the
URL, and continue to parse, looking for header parameters,
and then white space is of course ignored.

//Peter

> -----Original Message-----
> From: Sean Olson [mailto:[email-masked]]
> Sent: Thursday, January 11, 2001 19:05
> To: [email-masked]
> Cc: [email-masked]; Shailendra Bhatnagar
> Subject: Re: [SIP] Syntax for To: and From: An ambiguity ?
> 
> Yes, this is perfectly legal.
> /sean
> 
> M. Ranganathan wrote:
> 
> > Thanks for the reply, and now here's another nitpicky question:
> > 
> > Is the following legal
> > 
> > To: sip:[email-masked];   tag=9
> > 
> > (notice the space between the semicolon and the tag.)  This is not a 
> > legal  SIP URL of course (sip url's have  no spaces in them) but is this 
> > a legal to header?
> > 
> > Sorry for being so nitpicky.
> > 
> > Thanks.
> > 
> > Ranga.
> > 
> > Shailendra Bhatnagar wrote:
> > 
> >      >From the SIP spec :
> >     
> >     " The Contact, From and To header fields contain a URL. If the URL
> >        contains a comma, question mark or semicolon, the URL MUST be
> >        enclosed in angle brackets (< and >). Any URL parameters are
> >        contained within these brackets. If the URL is not enclosed in angle
> >        brackets, any semicolon-delimited parameters are header-parameters,
> >        not URL parameters."
> >     
> >     Hope it helps.
> >     
> >     "M. Ranganathan" wrote:
> >      >
> >      > Hello!
> >      >
> >      > In the syntax for FROM and TO headers, there appears to be an ambiguity.
> >      > According to what I read,
> >      >
> >      > To:  sip:[email-masked];tag=9
> >      >
> >      > is valid but then  is the tag a url parameter or part of the To
> >      > header?  The ambiguity can be resolved  of course  by only allowing the
> >      > name-addr form of the address  i.e.
> >      >
> >      > To: <sip:[email-masked]>; tag = 9
> >      >
> >      > however, the RFC does not appear to require this. Am I missing something
> >      > here?
> >      >
> >      > Thanks
> >      >
> >      > Ranga.

_______________________________________________
SIP mailing list
[email-masked]
http://lists.bell-labs.com/mailman/listinfo/sip