Kobi,<div>Thanks for your quick reply. Unfortunately  the last ACK to the provider doesn&#39;t have a contact header in it, so I don&#39;t think this will do anything..</div><div><br class="webkit-block-placeholder"></div>
<div>Here&#39;s the last invite that goes to the provider:</div><div><br class="webkit-block-placeholder"></div><div><p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">INVITE <a href="mailto:sip%3A0123455219848071234@204.13.14.15">sip:0123455219848071234@204.13.14.15</a> SIP/2.0.</p>

<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">Record-Route: &lt;sip:70.99.100.101;lr=on&gt;.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">Via: SIP/2.0/UDP 70.99.100.101;branch=z9hG4bKa252.d9e0fc8.0.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">Via: SIP/2.0/UDP 208.124.125.126:5060;received=208.124.125.126;rport=5060;branch=z9hG4bKc0a80c0c0000003049adcae6226108aa00000032.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">Content-Length: 370.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">Contact: &lt;<a href="http://sip:anonymous@208.124.125.126:5060">sip:anonymous@208.124.125.126:5060</a>&gt;.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">Call-ID: <a href="mailto:3843BD36-1DD2-11B2-8F19-FE592D5F1AFE@192.168.12.12">3843BD36-1DD2-11B2-8F19-FE592D5F1AFE@192.168.12.12</a>.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">Content-Type: application/sdp.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">CSeq: 1 INVITE.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">From: &quot;unknown&quot;&lt;<a href="mailto:sip%3Aanonymous@70.99.100.101">sip:anonymous@70.99.100.101</a>&gt;;tag=34708247451729444157.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">Max-Forwards: 69.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">To: &lt;<a href="mailto:sip%3A5219848071234@70.99.100.101">sip:5219848071234@70.99.100.101</a>&gt;.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">User-Agent: SJphone/1.60.299a/L (SJ Labs).</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial; min-height: 15.0px"><br></p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial; min-height: 15.0px"><br></p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial; min-height: 15.0px">And here&#39;s the last ACK.. which is subsequently the last packet on the call, ever (unless the originator, customer, hangs up)</p><p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial; min-height: 15.0px">
<br class="webkit-block-placeholder"></p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">ACK <a href="mailto:sip%3A0123455219848071234@204.13.233.223">sip:0123455219848071234@204.13.233.223</a> SIP/2.0.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">Record-Route: &lt;sip:70.99.100.101;lr=on&gt;.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">Via: SIP/2.0/UDP 70.99.100.101;branch=z9hG4bKa252.d9e0fc8.2.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">Via: SIP/2.0/UDP 208.124.125.126:5060;received=208.124.125.126;rport=5060;branch=z9hG4bKc0a80c0c0000003049adcb09107fe28800000037.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">Content-Length: 0.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">Call-ID: <a href="mailto:3843BD36-1DD2-11B2-8F19-FE592D5F1AFE@192.168.12.12">3843BD36-1DD2-11B2-8F19-FE592D5F1AFE@192.168.12.12</a>.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">CSeq: 1 ACK.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">From: &quot;unknown&quot;&lt;<a href="mailto:sip%3Aanonymous@70.99.100.101">sip:anonymous@70.99.100.101</a>&gt;;tag=34708247451729444157.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">Max-Forwards: 69.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">Route: &lt;sip:204.13.14.15;lr=on;ftag=34708247451729444157&gt;.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">To: &lt;<a href="mailto:sip%3A5219848071234@70.99.100.101">sip:5219848071234@70.99.100.101</a>&gt;;tag=as59051861.</p>
<p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">User-Agent: SJphone/1.60.299a/L (SJ Labs).</p><p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial"><br class="webkit-block-placeholder"></p><p style="margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Arial">
<br class="webkit-block-placeholder"></p>
</div><div><br class="webkit-block-placeholder"></div><div><div><br></div><div class="gmail_quote">On Tue, Mar 3, 2009 at 7:00 PM, Kobi Eshun <span dir="ltr">&lt;<a href="mailto:kobi@sightspeed.com">kobi@sightspeed.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div style="word-wrap:break-word">Don&#39;t know if this will help you, but we ran into a similar problem with one of our PSTN providers. In essence, their GW (incorrectly) updated the contact info of an established dialog when it got an ACK. In our case, the ACK sometimes contained a contact with an RFC 1918 IP address, and subsequent in-dialog requests from the remote GW would be lost. This code snippet addressed the issue:<div>
<br></div><div><div><span style="white-space:pre"><font face="&#39;Courier New&#39;">        </font></span><font face="&#39;Courier New&#39;">if (loose_route()) {</font></div><div><span style="white-space:pre"><font face="&#39;Courier New&#39;">                </font></span><font face="&#39;Courier New&#39;">xlog (&quot;L_DBG&quot;, &quot;loose_route;$rm\n&quot;);</font></div>
<div><span style="white-space:pre"><font face="&#39;Courier New&#39;">                </font></span><font face="&#39;Courier New&#39;">if(is_method(&quot;ACK&quot;)) {</font></div><div><span style="white-space:pre"><font face="&#39;Courier New&#39;">                        </font></span><font face="&#39;Courier New&#39;">if(is_present_hf(&quot;Contact&quot;)) remove_hf(&quot;Contact&quot;);</font></div>
<div><span style="font-family:&#39;Courier New&#39;;white-space:pre">                };</span></div><div><font face="&#39;Courier New&#39;"><span style="white-space:pre">        };</span></font></div><div><font face="&#39;Courier New&#39;"><span style="white-space:pre"><br>
</span></font></div></div><div><br></div><div>Be interested to hear how you resolve this. Cheers,<br><div> <div style="word-wrap:break-word"><div>--</div><div>kobi</div></div><br> </div><br><div><div><div><span id="q_11fcf1153eeeb45d_1" class="h4">- Show quoted text -</span></div>
<div class="h5"><div>On Mar 3, 2009, at 4:41 PM, Brett Nemeroff wrote:</div><br></div></div><blockquote type="cite"><div><div><span id="q_11fcf1153eeeb45d_3" class="h4">- Show quoted text -</span></div><div class="h5">Question...<div>
<br></div><div>In general the receipient of an INVITE should respond to that invite to the address in the contact header, right?</div><div><br> </div><div>What if there is a record-route header? That should prevail, right?</div>
<div><br></div><div>I&#39;m having a problem that with a single provider, some (not all) calls they don&#39;t send the BYE from the FAR side of the call back via me, instead it goes direct to the originator.</div> <div><br>
</div><div>Example:</div><div><br></div><div>My customer places a call to me. I send to my provider. Provider sends it to destination.</div><div><br> </div><div>Destination hangs up, BYE goes to my customer instead of me.. My INVITE to my provider DOES have a record-route header init.</div>
<div><br></div><div>Originally, this problem began because my customer would reinvite the call right after the call was established and the re-invite, because it was in-dialog wouldn&#39;t get record routed.</div> <div><br>
</div><div>So I moved my record-route block to before my loose route block.  Now, sometimes I get byes.. I&#39;m not sure what I&#39;m doing wrong.. any ideas?</div><div>-Brett</div> <div><br></div></div></div> _______________________________________________<br>
Users mailing list<br><a href="mailto:Users@lists.opensips.org" target="_blank">Users@lists.opensips.org</a><br><a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>
</blockquote></div><br></div></div></blockquote></div><br></div>