<div dir="ltr">Hello,<div><br></div><div>The question is not quite clear. In your opensips.cfg you call "<span style="color:rgb(0,0,0);font-family:'Courier New',Courier,monospace;font-size:14px">fix_nated_contact()" on both route and reply route. that's why it changes the route.</span></div>
<div><font color="#000000" face="Courier New, Courier, monospace"><span style="font-size:14px"><br></span></font></div><div><div class="gmail_extra">There is no such a thing as direction in opensips unless it's implemented in your logic. A message goes through your route or reply route scripts when it reaches opensips. </div>
<div class="gmail_extra"><br></div><div class="gmail_extra">Regards,</div><div class="gmail_extra">Ali</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Nov 22, 2013 at 1:10 AM, dpa <span dir="ltr"><<a href="mailto:denis7979@mail.ru" target="_blank">denis7979@mail.ru</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div bgcolor="white" background="cid:image001.gif@01CEE766.C25ABCD0" lang="RU" link="#660000" vlink="#003399">
<img src="cid:image001.gif@01CEE766.C25ABCD0" width="0" height="0" style="width: 0px; min-height: 0px;"><div><p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext">Hello<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext"><u></u> <u></u></span></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext">I have a one question about nat processing of Opensips.<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext"><u></u> <u></u></span></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext">There is such scheme<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext"><u></u> <u></u></span></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext">UAC1 (softphone behind nat) </span><span lang="EN-US" style="font-size:11pt;font-family:Wingdings;color:windowtext">ŕ</span><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext"> Opensips -> UAC2 (another softswitch), i.e. UAC1 initiates a call to Opensips and a signaling port = 5068.<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext"><u></u> <u></u></span></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext">So UAC2 becomes “ringing” by sending 183 message.<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext"><u></u> <u></u></span></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext">In attachment 183 message from UAC2 and some parts of opensips.cfg<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext"><u></u> <u></u></span></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext">After 183 processing by Opensips port in Contact header of 183 (and later 200 OK) messages become 5060, i.e. Opensips detects NAT and changes Contact header.<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext"><u></u> <u></u></span></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext">So my question is, Why does Opensips changes Contact header?<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext">Once Opensips detects nat transaction (setting setflag(21)) is it check all reply messages (and doesn`t matter from which UAC they have been received) or Opensips can detect direction and makes decision about nat process?<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext"><u></u> <u></u></span></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext">Thank you for any help.<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11pt;font-family:Calibri,sans-serif;color:windowtext"><u></u> <u></u></span></p><p class="MsoNormal"><span lang="EN-US"><u></u> <u></u></span></p><p class="MsoNormal">
<span lang="EN-US"><u></u> <u></u></span></p><p class="MsoNormal"><span lang="EN-US"><u></u> <u></u></span></p><p class="MsoNormal"><span lang="EN-US"><u></u> <u></u></span></p></div></div><br>_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a><br>
<a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>
<br></blockquote></div><br></div><img class="" src="https://contactmonkey.com/api/v1/tracker?cm_session=7aa93c28-7e0d-4b18-9de6-8fd4319e3154&cm_type=open&cm_user_email=alipey@gmail.com"></div></div>