On 7/7/14 6:23 AM, Jatin Kohli wrote:
Hi All

What should be the behavior of a SIP parser while decoding a To header having  
tel URI with escape sequence in it ?

Example:
To: <tel:%2A21%2A2246533682%23;phone-context=xyz.com>;tag=6348SIPpTag012

Is the above tel URI valid (wrt both RFCs 2806 and RFC 3966)?

According to 3261 the tel URI must first match the syntax addr-spec. It does, because it matches absoluteURI, containing an opaque-part, which allows the escaping. So far so good.

The next question is whether the escaping is to be replaced, according to the sip defined mapping, before being reparsed according to its own scheme syntax, or if the intent is simply to leave the escaping still in place and parse it according to its scheme.

AFAIK there is nothing that really says, one way or the other. But since escaping is intended to work around cases where you need to include characters that sip doesn't otherwise allow, and since the target scheme syntaxes can't have anticipated that, I think it only makes sense that the escaping *is* replaced before reparsing.

Assuming that, then the uri becomes: <tel:*21*2246533682#;phone-context=xyz.com>. This is valid according to 3966. It is not valid according to 2806 because that rfc doesn't allow an fqdn as a phone-context. (It doesn't allow ".", and not all of the alphabet. I have no idea what it was trying to do.)

What should be the behavior of a SIP parser on receipt of such a message?

Depends on whether you are processing the tel uri according the 3966 or 2806.

If you use 2806 and consider this invalid, then you can do as you wish. You could ignore the error, since it is just the To-URI and that doesn't necessarily affect anything.

If you want to reject it, then 400 is probably the response that best reflects the problem.

If you attempt to continue processing the request, then you may encounter additional errors if you don't "understand" this number. You might end up wanting to return 404 Not Found. But that would be more likely if this were in the R-URI. You really shouldn't be trying to find the To-URI.

        Thanks,
        Paul


Thanks and regards
Jatin Kohli


"DISCLAIMER: This message is proprietary to Aricent and is intended solely for the 
use of the individual to whom it is addressed. It may contain privileged or confidential 
information and should not be circulated or used for any purpose other than for what it 
is intended. If you have received this message in error, please notify the originator 
immediately. If you are not the intended recipient, you are notified that you are 
strictly prohibited from using, copying, altering, or disclosing the contents of this 
message. Aricent accepts no responsibility for loss or damage arising from the use of the 
information transmitted by this email including damage from virus."
_______________________________________________
Sip-implementors mailing list
[email protected]
https://lists.cs.columbia.edu/mailman/listinfo/sip-implementors


_______________________________________________
Sip-implementors mailing list
[email protected]
https://lists.cs.columbia.edu/mailman/listinfo/sip-implementors

Reply via email to