<p>From src/core/parser/parse_uri.c</p>
<pre><code>         case SIP_URI_T:
                        /* save the original sip: URI parameters in sip_params */
                        uri->sip_params=uri->params;
                        if ((phone2tel) &&
                             (uri->user_param_val.len == 5) &&
                                 (strncmp(uri->user_param_val.s, "phone", 5) == 0)
                                ) {
                                uri->type = TEL_URI_T;
                                uri->flags |= URI_SIP_USER_PHONE;
                                /* move params from user into uri->params */
                                p=q_memchr(uri->user.s, ';', uri->user.len);
                                if (p){
                                        /* NOTE: 
                                         * specialized uri params (user, maddr, etc.) still hold
                                         * the values from the sip-uri envelope
                                         * while uri->params point to the params in the embedded tel uri
                                         */
                                        uri->params.s=p+1;
                                        uri->params.len=uri->user.s+uri->user.len-uri->params.s;
                                        uri->user.len=p-uri->user.s;
                                } else {
                                        uri->params.s=0;
                                        uri->params.len=0;
                                }
                        } else {
                                uri->flags&=~URI_USER_NORMALIZE;
                        }
                        break;
</code></pre>
<p>So not an issue. the <code>"user=phone"</code> uri param changes the behavior of the parser.</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/kamailio/kamailio/issues/953#issuecomment-275622408">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AF36ZSVo7FHCSaaYTxxSwGmnjf9LVZEhks5rWbfRgaJpZM4LvjBd">mute the thread</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/AF36ZTmbrE2upHIj5KoZrLOZ3BJJRMIWks5rWbfRgaJpZM4LvjBd.gif" width="1" /></p>
<div itemscope itemtype="http://schema.org/EmailMessage">
<div itemprop="action" itemscope itemtype="http://schema.org/ViewAction">
  <link itemprop="url" href="https://github.com/kamailio/kamailio/issues/953#issuecomment-275622408"></link>
  <meta itemprop="name" content="View Issue"></meta>
</div>
<meta itemprop="description" content="View this Issue on GitHub"></meta>
</div>

<script type="application/json" data-scope="inboxmarkup">{"api_version":"1.0","publisher":{"api_key":"05dde50f1d1a384dd78767c55493e4bb","name":"GitHub"},"entity":{"external_key":"github/kamailio/kamailio","title":"kamailio/kamailio","subtitle":"GitHub repository","main_image_url":"https://cloud.githubusercontent.com/assets/143418/17495839/a5054eac-5d88-11e6-95fc-7290892c7bb5.png","avatar_image_url":"https://cloud.githubusercontent.com/assets/143418/15842166/7c72db34-2c0b-11e6-9aed-b52498112777.png","action":{"name":"Open in GitHub","url":"https://github.com/kamailio/kamailio"}},"updates":{"snippets":[{"icon":"PERSON","message":"@linuxmaniac in #953: From src/core/parser/parse_uri.c\r\n\r\n```\r\n\t\tcase SIP_URI_T:\r\n\t\t\t/* save the original sip: URI parameters in sip_params */\r\n\t\t\turi-\u003esip_params=uri-\u003eparams;\r\n\t\t\tif ((phone2tel) \u0026\u0026\r\n\t\t\t     (uri-\u003euser_param_val.len == 5) \u0026\u0026\r\n\t\t\t\t (strncmp(uri-\u003euser_param_val.s, \"phone\", 5) == 0)\r\n\t\t\t\t) {\r\n\t\t\t\turi-\u003etype = TEL_URI_T;\r\n\t\t\t\turi-\u003eflags |= URI_SIP_USER_PHONE;\r\n\t\t\t\t/* move params from user into uri-\u003eparams */\r\n\t\t\t\tp=q_memchr(uri-\u003euser.s, ';', uri-\u003euser.len);\r\n\t\t\t\tif (p){\r\n\t\t\t\t\t/* NOTE: \r\n\t\t\t\t\t * specialized uri params (user, maddr, etc.) still hold\r\n\t\t\t\t\t * the values from the sip-uri envelope\r\n\t\t\t\t\t * while uri-\u003eparams point to the params in the embedded tel uri\r\n\t\t\t\t\t */\r\n\t\t\t\t\turi-\u003eparams.s=p+1;\r\n\t\t\t\t\turi-\u003eparams.len=uri-\u003euser.s+uri-\u003euser.len-uri-\u003eparams.s;\r\n\t\t\t\t\turi-\u003euser.len=p-uri-\u003euser.s;\r\n\t\t\t\t} else {\r\n\t\t\t\t\turi-\u003eparams.s=0;\r\n\t\t\t\t\turi-\u003eparams.len=0;\r\n\t\t\t\t}\r\n\t\t\t} else {\r\n\t\t\t\turi-\u003eflags\u0026=~URI_USER_NORMALIZE;\r\n\t\t\t}\r\n\t\t\tbreak;\r\n```\r\n\r\nSo not an issue. the ``\"user=phone\" `` uri param changes the behavior of the parser."}],"action":{"name":"View Issue","url":"https://github.com/kamailio/kamailio/issues/953#issuecomment-275622408"}}}</script>