<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 5.5.2654.45">
<TITLE>R: [Serusers] How to intercept reply messages</TITLE>
</HEAD>
<BODY>

<P><FONT SIZE=2>Thanks for the answer.</FONT>
<BR><FONT SIZE=2>Now I am able to intercept the reply but I am not still able to stop these messages.</FONT>
<BR><FONT SIZE=2>Cn I change the type of the reply? For example I could substitute a "302 moved Temporarily" with a &quot;403 Forbidden&quot; in order to avoid the call divert. </FONT></P>

<P><FONT SIZE=2>Daniele</FONT>
</P>

<P><FONT SIZE=2>-----Messaggio originale-----</FONT>
<BR><FONT SIZE=2>Da: Klaus Darilion [<A HREF="mailto:klaus.mailinglists@pernau.at">mailto:klaus.mailinglists@pernau.at</A>]</FONT>
<BR><FONT SIZE=2>Inviato: mercoledì 16 giugno 2004 17.29</FONT>
<BR><FONT SIZE=2>A: Zappasodi Daniele</FONT>
<BR><FONT SIZE=2>Cc: serusers@lists.iptel.org</FONT>
<BR><FONT SIZE=2>Oggetto: Re: [Serusers] How to intercept reply messages</FONT>
</P>
<BR>

<P><FONT SIZE=2>you have to set up a reply route:</FONT>
</P>
<BR>

<P><FONT SIZE=2>route{</FONT>
<BR><FONT SIZE=2>&nbsp;&nbsp;&nbsp;&nbsp; ....</FONT>
<BR><FONT SIZE=2>&nbsp;&nbsp;&nbsp;&nbsp; t_on_reply(&quot;3&quot;);</FONT>
<BR><FONT SIZE=2>&nbsp;&nbsp;&nbsp;&nbsp; ....</FONT>
<BR><FONT SIZE=2>};</FONT>
</P>

<P><FONT SIZE=2>onreply_route[3]{</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2>if ( (status=~&quot;200&quot; || status=~&quot;183&quot;) ) {</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2>force_rtp_proxy();</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2>append_hf(&quot;P-RTP-Proxy: YES\r\n&quot;);</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2>};</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2>log(1, &quot;leaving onreply_route(1)\n&quot;);</FONT>
<BR><FONT SIZE=2>}</FONT>
</P>
<BR>

<P><FONT SIZE=2>regards,</FONT>
<BR><FONT SIZE=2>klaus</FONT>
</P>
<BR>

<P><FONT SIZE=2>Zappasodi Daniele wrote:</FONT>
</P>

<P><FONT SIZE=2>&gt; Hi all,</FONT>
<BR><FONT SIZE=2>&gt; I need to intercept the reply messages (&quot;302 Moved Temporarily&quot;, &quot;200 </FONT>
<BR><FONT SIZE=2>&gt; Accepted&quot;,&nbsp; &quot;405 Method not allow&quot; etc. ) and execute different actions </FONT>
<BR><FONT SIZE=2>&gt; for different status codes (for example I could block all the &quot;Moved </FONT>
<BR><FONT SIZE=2>&gt; Temporally&quot; messages or, in the Failure_route block, I could route the </FONT>
<BR><FONT SIZE=2>&gt; calls to different destinations for each different failure reason : </FONT>
<BR><FONT SIZE=2>&gt; Busy, no response, not available ...).&nbsp; </FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; How can I do this thing with the ser.cfg file?&nbsp;&nbsp; </FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; I have tried with the &quot;method&quot; operand and with the &quot;search&quot; function </FONT>
<BR><FONT SIZE=2>&gt; but I'm not able to intercept the reply messages with these functions.</FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; ------------------------------------------------------------------------</FONT>
<BR><FONT SIZE=2>&gt; </FONT>
<BR><FONT SIZE=2>&gt; _______________________________________________</FONT>
<BR><FONT SIZE=2>&gt; Serusers mailing list</FONT>
<BR><FONT SIZE=2>&gt; serusers@lists.iptel.org</FONT>
<BR><FONT SIZE=2>&gt; <A HREF="http://lists.iptel.org/mailman/listinfo/serusers" TARGET="_blank">http://lists.iptel.org/mailman/listinfo/serusers</A></FONT>
</P>

</BODY>
</HTML>