Now that my rtpproxy actually passes traffic I stumbled on another problem. When the called party hangs up the call (asterisk command Hangup()) the soft phone remains connected. Yet, when I click the Hangup button on the softphone, SER receives BYE messages.
<br><br><div><span class="gmail_quote">On 3/9/06, <b class="gmail_sendername">Vitaly Nikolaev</b> &lt;<a href="mailto:vnikolaev@intermedia.net">vnikolaev@intermedia.net</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div style="direction: ltr;">











<div>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">Looks like forward
includes relay in it. And by putting force_rtpproxy AFTER forward you does not
give it a chance </span></font><font color="navy" face="Wingdings" size="2"><span style="font-size: 10pt; font-family: Wingdings; color: navy;" lang="EN-US">J</span></font><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">
 on_reply route is also MUST be there.</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">&nbsp;</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">&nbsp;</span></font></p>

<div>

<div style="text-align: center;" align="center"><font face="Times New Roman" size="3"><span style="font-size: 12pt;" lang="EN-US">

<hr align="center" size="2" width="100%">

</span></font></div>

<p><b><font face="Tahoma" size="2"><span style="font-size: 10pt; font-family: Tahoma; font-weight: bold;" lang="EN-US">From:</span></font></b><font face="Tahoma" size="2"><span style="font-size: 10pt; font-family: Tahoma;" lang="EN-US">

<a href="mailto:users-bounces@openser.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">users-bounces@openser.org</a> [mailto:<a href="mailto:users-bounces@openser.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
users-bounces@openser.org</a>] <b><span style="font-weight: bold;">On Behalf Of </span></b>Script Head<br>
<b><span style="font-weight: bold;">Sent:</span></b> Thursday, March 09, 2006
12:59 PM<br>
<b><span style="font-weight: bold;">To:</span></b> <a href="mailto:users@openser.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">users@openser.org</a><br>
<b><span style="font-weight: bold;">Subject:</span></b> Re: [Users] forcing
rtpproxy on a call</span></font><span lang="EN-US"></span></p>

</div></div><div style="direction: ltr;"><span class="e" id="q_109e02e5c5b8a457_1">

<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">&nbsp;</span></font></p>

<p style="margin-bottom: 12pt;"><font face="Times New Roman" size="3"><span style="font-size: 12pt;">Thank you guys, it's
working now.<br>
<br>
Apparently, rewritehostport(&quot;&lt;ip&gt;:&lt;port&gt;&quot;) works great
with rptproxy while forward does exactly that, forwards the call to the
destination bypassing the force_rtp_proxy request. This should be documented
somewhere. <br>
<br>
ScriptHead</span></font></p>

<div>

<p><span><font face="Times New Roman" size="3"><span style="font-size: 12pt;">On 3/9/06, <b><span style="font-weight: bold;">Vitaly
Nikolaev</span></b> &lt;<a href="mailto:vnikolaev@intermedia.net" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">vnikolaev@intermedia.net</a>&gt;
wrote:</span></font></span></p>

<div>

<div>

<ol start="1" type="1">
 <li style="color: navy;"><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial;" lang="EN-US">I never used
     forward, see my example, I do not know if it actually relay call or not</span></font></li>
 <li style="color: navy;"><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial;" lang="EN-US">if you do not have
     NAT between client and server you do not need force_rport, and try to
     avoid any nat_uac_test, etc if you are actually working on private ips
     without nat</span></font></li>
 <li style="color: navy;"><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial;" lang="EN-US">you MUST enable
     proxy also for reply</span></font></li>
</ol>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">&nbsp;</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">route[x] {</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">&nbsp;</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">…..</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">&nbsp;</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">force_rtp_proxy();</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">t_on_reply(&quot;1&quot;);</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">rewritehostport(&quot;x.x.x.x:5060&quot;);</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">if (!t_relay()) {</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
sl_reply_error();</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">};</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">}</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">&nbsp;</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">&nbsp;</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">onreply_route[1] {</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if
(!(status=~&quot;183&quot; || status=~&quot;200&quot;))</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
break;</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
force_rtp_proxy(&quot;&quot;);</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">}</span></font></p>

<p><font color="navy" face="Arial" size="2"><span style="font-size: 10pt; font-family: Arial; color: navy;" lang="EN-US">&nbsp;</span></font></p>

<div>

<div style="text-align: center;" align="center"><font face="Times New Roman" size="3"><span style="font-size: 12pt;" lang="EN-US">

<hr align="center" size="2" width="100%">

</span></font></div>

<p><b><font face="Tahoma" size="2"><span style="font-size: 10pt; font-family: Tahoma; font-weight: bold;" lang="EN-US">From:</span></font></b><font face="Tahoma" size="2"><span style="font-size: 10pt; font-family: Tahoma;" lang="EN-US">
 <a href="mailto:users-bounces@openser.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">users-bounces@openser.org</a>
[mailto:<a href="mailto:users-bounces@openser.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
users-bounces@openser.org</a>] <b><span style="font-weight: bold;">On Behalf Of </span></b>Script
Head<br>
<b><span style="font-weight: bold;">Sent:</span></b> Wednesday, March 08, 2006
6:29 PM<br>
<b><span style="font-weight: bold;">To:</span></b> <a href="mailto:users@openser.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">users@openser.org</a><br>
<b><span style="font-weight: bold;">Subject:</span></b> [Users] forcing rtpproxy
on a call</span></font></p>

</div>

<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">&nbsp;</span></font></p>

</div>

<div>

<p style="margin-bottom: 12pt;"><span><font face="Times New Roman" size="3"><span style="font-size: 12pt;">Hello everyone,</span></font></span><br>
<br>
<span>I am trying to debug why my rtpproxy isn't working. I have the
following setup, on my LAN. </span></p>

</div>

<div>

<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">softphone (<a href="http://192.168.1.100" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">192.168.1.100</a>)
-&gt; openser/rtpproxy (<a href="http://192.168.1.10" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
192.168.1.10</a>) -&gt; asterisk (<a href="http://192.168.1.12" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">192.168.1.12</a>)</span></font></p>

</div>

<div>

<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"><br>
<br>
<span>The rtpproxy is running and I see commands flying thru it.</span><br>
<br>
<span>the following route works</span><br>
<br>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if(method==&quot;INVITE&quot;)
{ </span><br>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
if(uri=~&quot;^sip:[0-9]{6}1[0-9]*{10}@&quot;) {</span></span></font></p>

</div>

<div>

<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
forward(<a href="http://192.168.1.12" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">192.168.1.12</a>,5060);</span></font></p>

</div>

<div>

<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"><br>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
};</span><br>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }</span><br>
<br>
<span>when I replace it with this route </span><br>
<br>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if(method==&quot;INVITE&quot;)
{</span><br>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
if(uri=~&quot;^sip:[0-9]{6}1[0-9]*{10}@&quot;) {</span></span></font></p>

</div>

<div>

<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
forward(<a href="http://192.168.1.12" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">192.168.1.12</a>,5060);</span></font></p>

</div>

<div>

<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;"><br>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
}; </span><br>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
force_rport();</span><br>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
force_rtp_proxy();</span><br>
<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }</span><br>
<br>
<span>I get dead air while asterisk logs show that my test message is
playing. How should I proceed to debug this?</span><br>
<br>
<span>ScriptHead</span></span></font></p>

</div>

</div>

</div>

<p><font face="Times New Roman" size="3"><span style="font-size: 12pt;">&nbsp;</span></font></p>

</span></div><div style="direction: ltr;"></div>





</div></blockquote></div><br>