Subject: Re: [SIP] Change in SIP URL syntax

From: Gethin Liddell <[email-masked]>
Date: Tue, 1 Aug 2000 09:48:24 +0100

On Tue, 01 Aug 2000, Ajay Chitturi wrote:
> 
> Hi,
> 
> I noticed the following change in the SIP URL syntax in the latest
> version of 2543bis
> 
> 	Added semicolon and question mark to the list of unreserved
> characters for the user part of SIP URLs
> 	to handle tel: URLs properly.
> 

there was a long discussion on this a couple of weeks back.  i will not
go over all of the arguments, for and against, yet again, but point you
in the direction of the archives instead (thread name is: "SIP URL
telephone-subscriber syntax").  If after reading these, you still
disagree with the forum's consensus then please raise this issue again
with your new objections.

> Wouldn't the change make URL parsing ambiguous ?
> 
> For eg. the URL <sip:a;b=c@d> could be parsed in two different ways :
> (i) host is a and param is b=c@d
> (ii) user is a;b=c and host is d

no, this is not ambiguous.  ; is allowed in user so the user is a;b=c 
this is black and white there is no ambiguity via the greedy parsing
algorithm.  if you wanted the former, then the url should look like:

sip:a;b=c%40d

It is the case that any character that incorrectly changes the
semantics of URI's MUST be escaped.  that is all that is happening
here.  It is suggested that @ is always escaped in parameters. even if
this is not required for example:

a@b;c@d

is user "a" host "b" param "c@d" but it is suggested to even make the
parameter here "c%40d".  mainly because this will make development
easier :)

> Am I missing something ?
> Is there a simple way to parse URL's with this change ?

perhaps this has made parsing sip url's slightly more difficult but
this is considered better than double escaping of characters or
defining new escaping techniques to enable the encapsulation of the tel
url in the user.

HTH

-- 
Gethin Liddell
Ubiquity Software Corporation

http://www.ubiquity.net
mailto:[email-masked]

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

---

From: "Ajay Chitturi" <[email-masked]>
Date: Tue, 1 Aug 2000 10:52:46 -0700

After going through the earlier discussion pointed to by Gethin,
my understanding is that "@" should be removed from param-unreserved 
and hnv-unreserved on page 18. 

Is this correct ?

Thanks

-----Original Message-----
From: Henning Schulzrinne [mailto:[email-masked]]
Sent: Tuesday, August 01, 2000 6:32 AM
To: Fairlie-Cuninghame, Robert
Cc: 'Gethin Liddell'; Ajay Chitturi; [email-masked]
Subject: Re: [SIP] Change in SIP URL syntax

The current version of the text (to be -01) says

... The set of characters not reserved in the RFC 2806 description
of \header{telephone-subscriber} contains a number of characters in
various syntax elements that need to be escaped when used in SIP URLs,
for example quotation marks (\%22), hash (\%23), colon (\%3a), at-sign
(\%40) and the ``unwise'' characters, i.e., punctuation of \%5b and
above.

---

From: "Fairlie-Cuninghame, Robert" <[email-masked]>
Date: Thu, 10 Aug 2000 19:45:00 -0700

Ok right. Good we all agree. Sorry, I was interpreting param-reserved as the
list of reserved URL characters (RFC2396) allowed (unescaped)in the
parameter field (althought I guess you would have called it be
param-unreserved in that case).

Robert.

-- My opinions are my own. I tried selling them once but everybody
	seems to already have one. -- 

> Sent: Friday, August 11, 2000 10:25 AM
> Cc: 'Ajay Chitturi'; Gethin Liddell; [email-masked]
> "Fairlie-Cuninghame, Robert" wrote:
> > 
> > Sorry, I meant to reply to this a while back.
> > 
> > This is with regards to the telephone-subscriber ambiguity (again)
> > (eg sip:ABCD;telparam=[email-masked];user=phone).
> > 
> > Was the conclusion that
> > a) an unescaped '@ is allowed in a parameter as long is it 
> is not ambiguous.
> > (ie, 
> sip:ABCD;telparam=[email-masked];toad=dog@cat;user=phone is ok)
> > or
> > b) '@' must always be escaped in parameter names and values.
> > 
> > I personally feel the latter is safer and I'm not sure if 
> your reply is
> > supporting this viewpoint.
> > 
> > If that is the case then won't '@' also have to be removed from
> > param-reserved ?
> 
> @ is a reserved character (being a separator with syntactic
> significance).
> Reserved characters must be escaped. I'm not sure from what it must be
> removed since it doesn't appear in any explicit listing of unreserved
> characters. 
> 
> unreserved    = alphanum | mark
>       mark    = "-" | "_" | "." | "!" | "~" | "*" | "'" |
>                       "(" | ")"
> 
> hnv-unreserved  = "[" | "]" | "/" | "?" | ":" | "+" | "$"
> 
> -- 
> Henning Schulzrinne   http://www.cs.columbia.edu/~hgs
> 
>