Great. Thanks for the info.<br>
<br>
One more question. Since a call can be forwarded to another SIP phone
or to a PSTN phone, I need to determine how to route the REFER message.<br>
<br>
So would I basically do something like this:<br>
<br>
route {<br>
<br>
&nbsp;&nbsp;&nbsp; if (method=='REFER') {<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if (!regeristered(&quot;location&quot;)) {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
rewritehostport(&quot;xxx.xxx.xxx.xxx&quot;); # IP of the PSTN gateway<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; t_relay();<br>
&nbsp;&nbsp;&nbsp; }<br>
}<br>
<br>
<br>
Regards,<br>
Paul<br><br><div><span class="gmail_quote">On 6/1/05, <b class="gmail_sendername">Marian Dumitru</b> &lt;<a href="mailto:marian.dumitru@voice-sistem.ro">marian.dumitru@voice-sistem.ro</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;">
Hi Paul,<br><br>Just two comments:<br><br>1) the message shouldn't be RURI driven, but ROUTE driven, so it<br>shouldn't hit location.<br><br>2) Refer-to URI shouldn't be used for routing the REFER - this header<br>will tell to the destination user which user to contact/refer.
<br><br>Regards,<br>Marian<br><br>Java Rockx wrote:<br>&gt; Hi All.<br>&gt;<br>&gt; I've got a question about handling REFER messages. Below is a REFER<br>&gt; message that my Grandstream GXP2000 phone generated when I transferred a
<br>&gt; call to another SIP phone on the same SER proxy.<br>&gt;<br>&gt; The problem is that SER did a lookup('location') and couldn't find the<br>&gt; phone number in the subscriber table, so it routed the message to the
<br>&gt; PSTN gateway.<br>&gt;<br>&gt; SER should have looked at the Refer-To header to get the actual<br>&gt; destination of the message.<br>&gt;<br>&gt; How can I get SER to handle this message correctly? Should REFER<br>
&gt; messages hit the lookup('location') function in my ser.cfg script?<br>&gt;<br>&gt; NOTE: my SER proxy sits behind a Cisco 3600 so the ALG functionality has<br>&gt; altered the IP. The message shows my SER server as IP address 
<a href="http://10.3.0.221">10.3.0.221</a><br>&gt; &lt;<a href="http://10.3.0.221">http://10.3.0.221</a>&gt;<br>&gt;<br>&gt; Regards,<br>&gt; Paul<br>&gt;<br>&gt; U 2005/06/01 14:22:24.073518 <a href="http://66.90.46.29:5060">
66.90.46.29:5060</a> &lt;<a href="http://66.90.46.29:5060">http://66.90.46.29:5060</a>&gt;<br>&gt; -&gt; <a href="http://10.3.0.221:5060">10.3.0.221:5060</a> &lt;<a href="http://10.3.0.221:5060">http://10.3.0.221:5060</a>
&gt;<br>&gt; REFER sip:4075552279@66.243.109.99:5060 SIP/2.0.<br>&gt; Via: SIP/2.0/UDP <a href="http://172.31.130.139">172.31.130.139</a><br>&gt; &lt;<a href="http://172.31.130.139">http://172.31.130.139</a>&gt;;branch=z9hG4bK09ff837994d9e898.
<br>&gt; Route: &lt;sip:4075552279@10.3.0.221:5060;nat=yes;ftag=204ed7cd9666ebba;lr&gt;.<br>&gt; Route: &lt;sip:<a href="http://216.229.127.60:5060">216.229.127.60:5060</a> &lt;<a href="http://216.229.127.60:5060">http://216.229.127.60:5060
</a>&gt;;lr&gt;.<br>&gt; From: 3212514238 &lt;sip:3212514238@66.243.109.99:5060&gt;;tag=204ed7cd9666ebba.<br>&gt; To: <a href="mailto:sip:4075552279@66.236.245.100">sip:4075552279@66.236.245.100</a><br>&gt; &lt;mailto:<a href="mailto:sip">
sip</a>:<a href="mailto:4075552279@66.236.245.100">4075552279@66.236.245.100</a>&gt;;tag=EB25EC-B85.<br>&gt; Contact: &lt;<a href="mailto:sip:3212514238@172.31.130.139">sip:3212514238@172.31.130.139</a><br>&gt; &lt;mailto:
<a href="mailto:sip">sip</a>:<a href="mailto:3212514238@172.31.130.139">3212514238@172.31.130.139</a>&gt;&gt;.<br>&gt; Supported: replaces.<br>&gt; Refer-To: &lt;<a href="mailto:sip:3212814820@sip.mycompany.com">sip:3212814820@sip.mycompany.com
</a><br>&gt; &lt;mailto:<a href="mailto:sip">sip</a>:<a href="mailto:3212814820@sip.mycompany.com">3212814820@sip.mycompany.com</a>&gt;&gt;.<br>&gt; Referred-By: &lt;<a href="mailto:sip:3212514238@172.31.130.139">sip:3212514238@172.31.130.139
</a><br>&gt; &lt;mailto:<a href="mailto:sip">sip</a>:<a href="mailto:3212514238@172.31.130.139">3212514238@172.31.130.139</a>&gt;&gt;.<br>&gt; Call-ID: <a href="mailto:13195134-3326638548-685571@66.243.109.99">13195134-3326638548-685571@66.243.109.99
</a><br>&gt; &lt;mailto:<a href="mailto:13195134-3326638548-685571@66.243.109.99">13195134-3326638548-685571@66.243.109.99</a>&gt;.<br>&gt; CSeq: 51906 REFER.<br>&gt; User-Agent: Grandstream GXP2000 <a href="http://1.0.1.8">
1.0.1.8</a> &lt;<a href="http://1.0.1.8">http://1.0.1.8</a>&gt;.<br>&gt; Max-Forwards: 70.<br>&gt; Allow:<br>&gt; INVITE,ACK,CANCEL,BYE,NOTIFY,REFER,OPTIONS,INFO,SUBSCRIBE,UPDATE,PRACK.<br>&gt; Content-Length: 0.<br><br>--
<br>Voice System<br><a href="http://www.voice-system.ro">http://www.voice-system.ro</a><br></blockquote></div><br>