<html>
<head>
<meta content="text/html; charset=windows-1252"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Hello,<br>
<br>
updated the subject of the email to reflect it refers to IMS
extensions, which are different than the standard IETF registrars.<br>
<br>
That makes it easier to be spotted by the people using IMS and the
dev guys can shed some light on why the implemented that way.<br>
<br>
Cheers,<br>
Daniel<br>
<br>
<div class="moz-cite-prefix">On 24/11/15 11:59, Prashant Desai
wrote:<br>
</div>
<blockquote
cite="mid:CALGsjrxNAsDZPe3OU3WEGsjza7quuEh3ew=cfaXuS8TYGp2KQg@mail.gmail.com"
type="cite">
<div dir="ltr">
<div class="gmail_quote">
<div link="blue" vlink="purple" lang="EN-US">
<div>Hi,
<p class="MsoNormal"> </p>
<p class="MsoNormal"> We observe that the following
kamailio API is trying to find out user registration by
comparing source IP and port with stored contact, if it
fails, then it compares based on incoming SIP msg
contact uri.</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">is_registered(struct sip_msg* _m,
udomain_t* _d){</p>
<p class="MsoNormal"> getContactP(_m,_d);</p>
<p class="MsoNormal">}</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">pcontact_t * getContactP(struct
sip_msg* _m, udomain_t* _d) {);</p>
<p class="MsoNormal">
//Getting pcontact from source IP and port</p>
<p class="MsoNormal">
if (ul.get_pcontact_by_src(_d, &received_host,
_m->rcv.src_port, _m->rcv.proto, &c) == 1) {</p>
<p class="MsoNormal">
LM_DBG("No entry in usrloc for %.*s:%i (Proto %i)
found!\n", received_host.len, received_host.s,
_m->rcv.src_port, _m->rcv.proto);</p>
<p class="MsoNormal">
} </p>
<p class="MsoNormal"> if (c
== NULL) {</p>
<p class="MsoNormal">
//Getting pcontact from contact uri.</p>
<p class="MsoNormal"
style="margin-left:1.0in;text-indent:.5in">if
(ul.get_pcontact(_d, &ct->uri, &c) == 0) {</p>
<p class="MsoNormal">
</p>
<p class="MsoNormal">
}</p>
<p class="MsoNormal"> }</p>
<p class="MsoNormal">We have use case where INVITE message
is from same source IP and port but having unregistered
contact.With this scenario,is_registered() will return
success.
</p>
<p class="MsoNormal">We would like to know reason behind
comparing the source IP and port to fetch the pcontact?</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">Regards,</p>
<p class="MsoNormal">Prashant</p>
</div>
</div>
</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</a>
<a class="moz-txt-link-freetext" href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users</a>
</pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
Daniel-Constantin Mierla
<a class="moz-txt-link-freetext" href="http://twitter.com/#!/miconda">http://twitter.com/#!/miconda</a> - <a class="moz-txt-link-freetext" href="http://www.linkedin.com/in/miconda">http://www.linkedin.com/in/miconda</a>
Book: SIP Routing With Kamailio - <a class="moz-txt-link-freetext" href="http://www.asipto.com">http://www.asipto.com</a>
Kamailio Advanced Training, Nov 30-Dec 2, Berlin - <a class="moz-txt-link-freetext" href="http://asipto.com/kat">http://asipto.com/kat</a></pre>
</body>
</html>