Subject: [sipcore] SIP-URI Without Userinfo

From: Adnan Aziz <[email-masked]>
Date: Mon, 7 Nov 2016 10:49:47 +0100

Hello Everyone,

According to the rfc3261, the userinfo in the sip-uri is optional.
If there is no userinfo part then there should not be any "@" sign as well
in the sip-uri.

I have couple of questions

1) If I am receiving a sip request without userinfo part in the sip-usri,
starting with "@" then is it a malformed packet?

2) What should be the standard behavior of SIP server while responding to
such packets?

Regards,
Adnan Aziz
-- 
*Adnan Aziz*

---

From: Christer Holmberg <[email-masked]>
Date: Mon, 7 Nov 2016 10:46:43 +0000

Hi,

>If there is no userinfo part then there should not be any "@" sign as well in the sip-uri.

Correct.

>1) If I am receiving a sip request without userinfo part in the sip-usri, starting with "@" then is it a malformed packet?

It’s a malformed SIP URI.

>2) What should be the standard behavior of SIP server while responding to such packets?

Send a response with an error response code.

Regards,

Christer

---

From: [email-masked] (Dale R. Worley)
Date: Mon, 07 Nov 2016 09:44:20 -0500

To amplify Christer's replyP:

Christer Holmberg <[email-masked]> writes:
>>1) If I am receiving a sip request without userinfo part in the
>>sip-usri, starting with "@" then is it a malformed packet?
>
> It's a malformed SIP URI.

In particular, it is syntactically incorrect, which you can see by
comparison with the ABNF in RFC 3261 section 25.1 production "SIP-URI".

> Send a response with an error response code.

Specifically, a 400 response:

   21.4.1 400 Bad Request

   The request could not be understood due to malformed syntax.  The
   Reason-Phrase SHOULD identify the syntax problem in more detail, for
   example, "Missing Call-ID header field".

However, there is a certain amount of freedom that SIP servers have
regarding precisely what 4xx response codes they give for particular
requests, because the errors in SIP requests cannot be precisely
categorized.

Dale