<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=KOI8-R" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
<tt>Hello,<br>
<br>
Not clear from the diagram, but the UAC2 is behind the NAT, not
OpenSIPS and UAC1, right ?<br>
<br>
As Laszlo suggested, you need a force_rport(), but not only for
INVITE, but for all requests coming from behind the NAT - like the
BYE, in your case.<br>
<br>
Regards,<br>
</tt>
<pre class="moz-signature" cols="72">Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
<a class="moz-txt-link-freetext" href="http://www.opensips-solutions.com">http://www.opensips-solutions.com</a></pre>
<br>
On 04/04/2013 05:29 PM, çÏÇÉÞÁÛ×ÉÌÉ áÎÄÒÅÊ wrote:
<blockquote
cite="mid:00c601ce3140$ddd95980$998c0c80$@gogichashvili@ptl.ru"
type="cite">
<meta http-equiv="Content-Type" content="text/html;
charset=KOI8-R">
<meta name="Generator" content="Microsoft Word 12 (filtered
medium)">
<style>
<!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:2.0cm 42.5pt 2.0cm 3.0cm;}
div.WordSection1
        {page:WordSection1;}
-->
</style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
<div class="WordSection1">
<p class="MsoNormal"><span lang="EN-US">Hello! I have some
trouble with nat
handling.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">I have such scheme:<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">uac1---opensips---(NAT)---uac2<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">I call to UAC2 and
signaling establishment
is ok. Whenš UAC2 sends BYEš opensips translates 200OK
(received from UAC1) to
the wrong port. <o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p>š</o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">BYE generated by UAC2
has such via header:<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">“Via: SIP/2.0/UDP
192.168.18.137:5060;branch=z9hG4bK8b517b11a415”<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">and the BYE comes from U
2013/04/04
17:21:50.287792 1.1.1.1:59292 -> 2.2.2.2:5068<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">Where 1.1.1.1 – nat,
2.2.2.2 -
opensips<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p>š</o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">Opensips adds one more
via header to the
BYE:<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">Via: SIP/2.0/UDP
2.2.2.2;branch=z9hG4bK7f45.debc1592.0. <o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">and changes first via
header by adding
received field:<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">Via: SIP/2.0/UDP
192.168.18.137:5060;received=1.1.1.1;branch=z9hG4bK8b517b11a415<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p>š</o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">200 OK got from UAC1
opensips tries to send
not to 1.1.1.1:59292 but to 1.1.1.1:5060<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">The question is how can
we make opensips to
send 200 OK to 59292 port?<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p>š</o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">Thank you for any help.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p>š</o:p></span></p>
<p class="MsoNormal"><o:p>š</o:p></p>
</div>
<pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a>
<a class="moz-txt-link-freetext" href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a>
</pre>
</blockquote>
</body>
</html>