<br><br><div class="gmail_quote">On Fri, Jun 19, 2009 at 9:13 PM, Juha Heinanen <span dir="ltr">&lt;<a href="mailto:jh@tutpro.com">jh@tutpro.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">

<div class="im">Pascal Maugeri writes:<br>
<br>
 &gt; So if I understand well (please correct me if I&#39;m wrong) the &quot;plan&quot; is:<br>
 &gt;<br>
 &gt; 1º) I install MediaProxy and use Kamailio MEDIAPROXY module instead of<br>
 &gt; rtpproxy/NATHelper<br>
 &gt;<br>
 &gt; 2º) filter the app/sdp part with<br>
 &gt;<br>
 &gt; if (has_body(&quot;multipart/mixed&quot;)) {<br>
 &gt;     if (filter_body(&quot;application/sdp&quot;) {<br>
 &gt;         remove_hf(&quot;Content-Type&quot;);<br>
 &gt;<br>
 &gt;         append_hf(&quot;Content-Type: application/sdp\r\n&quot;);<br>
 &gt;     } else {<br>
 &gt;<br>
 &gt;         xlog(&quot;Body part application/sdp not found\n&quot;);<br>
 &gt;     }<br>
 &gt; }<br>
<br>
</div>you don&#39;t need to call filter_body if you use mediaproxy.<br>
<div class="im"><br>
 &gt; 3º) then engage the media proxy with<br>
 &gt;<br>
 &gt; if (method==INVITE &amp;&amp; !has_totag()) {<br>
 &gt;<br>
 &gt;     # We can also use a specific media relay if we need to<br>
 &gt;     #$avp(s:media_relay) = &quot;1.2.3.4&quot;;<br>
 &gt;     engage_media_proxy();<br>
 &gt; }<br>
<br>
</div>i have never used engage_media_proxy() functions, because it makes some<br>
assumptions that are not generally true.  i use use_media_proxy() instead.<br>
<div class="im"><br>
 &gt; 4º) finally put the body part(s) that have been removed in 1º) and relay the<br>
 &gt; INVITE to my next hop.<br>
 &gt;      I believe I can save the body part(s) in 1º) and put them back using<br>
 &gt; set_body(txt, content_type).<br>
<br>
</div>you don&#39;t need to do anything like that if you use use_media_proxy()<br>
function, because it does not remove anything.<br>
<font color="#888888"></font></blockquote><div><br>Thanks Juha ! I can&#39;t wait for monday to test it :-)<br><br>Have a nice week-end<br>Pascal<br><br> </div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">

<font color="#888888"><br>
-- juha<br>
</font></blockquote></div><br>