<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto">I don’t think the handle_ruri_alias() concept was created to handle such complications. Usually you would not have two layers of NAT...<br><br><div dir="ltr">—<div>Sent from mobile, with due apologies for brevity and errors.</div></div><div dir="ltr"><br><blockquote type="cite">On May 31, 2021, at 1:53 PM, Denys Pozniak <denys.pozniak@gmail.com> wrote:<br><br></blockquote></div><blockquote type="cite"><div dir="ltr"><div dir="ltr">Hello!<div><br></div><div>I need help understanding how the <b>handle_ruri_alias()</b> function works.</div><div><b>Call-flow:</b> Upstream operator -> Kamailio Proxy -> Edpoint.</div><div><br></div><div>The upstream operator in the initial SIP INVITE in the Contact field sends us an alias parameter, in turn, our Kamailio Proxy adds its own too.<br></div><div>The Contact after the Proxy looks something like this:<br></div><div><br></div><div><i>Contact: <sip:10.0.0.115:5060;alias=10.0.0.115~5060~1;alias=3.3.3.3~5060~1></i><br></div><div><br></div><div>When the Endpoint sends us a SIP BYE, then the 

 <b>handle_ruri_alias()</b> absorbs not the last alias, but the first one, and this leads to the incorrect formation of a $du.<br></div><div>The RURI after the Proxy looks something like this:  <br></div><div><br></div><div><i>Request-Line: BYE sip:10.0.0.115:5060;alias=3.3.3.3~5060~1 SIP/2.0</i><br></div><div><br></div><div>The first thing that comes to mind is a modification of the original Contact field with storing it's within a dialogue ...<br></div><div><br></div><div>Is it possible to elegantly solve this problem?<br></div><div><br></div><div>-- <br><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><br><div><div>BR,</div><div>Denys Pozniak<br></div><div><br></div><div><br></div></div></div></div></div></div>
<span>__________________________________________________________</span><br><span>Kamailio - Users Mailing List - Non Commercial Discussions</span><br><span>  * sr-users@lists.kamailio.org</span><br><span>Important: keep the mailing list in the recipients, do not reply only to the sender!</span><br><span>Edit mailing list options or unsubscribe:</span><br><span>  * https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users</span><br></div></blockquote></body></html>