<div dir="ltr"><div style="font-family:arial,sans-serif;font-size:13px">Hello, </div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">I&#39;m having a really strange issue on billing related to late negotiation. The call end up hanged with no BYE.  </div>
<div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">There is a dialer sending thousands of calls through and OpenSIPS to a termination based on FreeSwitch. I have a SIP call flow as below. Some times during the day, when the volume is high, the UAC drops some 200Ok  and FS send a reinvite in the middle of the Initial transaction.</div>
<div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px"><font face="courier new, monospace">----INVITE ---------------   Proxy --INVITE ---------------&gt; FS</font></div>
<div style="font-family:arial,sans-serif;font-size:13px"><font face="courier new, monospace">&lt;----200 OK --------------   Proxy &lt;---200 OK- ------------- FS</font></div><div style="font-family:arial,sans-serif;font-size:13px">
<font face="courier new, monospace">&lt;--REINVITE---------------   Proxy &lt;-REINVITE--------------- FS  </font></div><div style="font-family:arial,sans-serif;font-size:13px"><font face="courier new, monospace">---481 leg does not exit-&gt;   Proxy ---481------------------&gt; FS</font></div>
<div style="font-family:arial,sans-serif;font-size:13px"><font face="courier new, monospace">&lt;-- ACK (REINVITE)--------   Proxy &lt;-ACK(REINVITE)---------- FS</font></div><div style="font-family:arial,sans-serif;font-size:13px">
<font face="courier new, monospace">----CANCEL ---------------&gt;  Proxy ---CANCEL --------------&gt; FS </font></div><div style="font-family:arial,sans-serif;font-size:13px"><font face="courier new, monospace">&lt;---200 Ok ----------------  Proxy &lt;----200 Ok ------------- FS</font></div>
<div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">FS is sending a reinvite before ACK comes from the client.</div><div style="font-family:arial,sans-serif;font-size:13px">
<br></div><div style="font-family:arial,sans-serif;font-size:13px">I have two questions:</div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">1) Is it valid to send a reinvite in the middle of an existing transaction?</div>
<div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">According to the RFC3261 Section 14. </div><div style="font-family:arial,sans-serif;font-size:13px">
<br></div><div style="font-family:arial,sans-serif;font-size:13px"><pre style="white-space:pre-wrap;font-size:1em;margin-bottom:0px;margin-top:0px">Note that a UAC MUST NOT initiate a new INVITE transaction within a
dialog while another INVITE transaction is in progress in either
direction.

1. If there is an ongoing INVITE client transaction, the TU MUST
   wait until the transaction reaches the completed or terminated
   state before initiating the new INVITE.

2. If there is an ongoing INVITE server transaction, the TU MUST
wait until the transaction reaches the confirmed or terminated
state before initiating the new INVITE.</pre></div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">But it is confusing because just below it says the opposite. </div>
<div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px"><pre style="white-space:pre-wrap;font-size:1em;margin-bottom:0px;margin-top:0px">However, a UA MAY initiate a regular transaction while an INVITE
transaction is in progress.  A UA MAY also initiate an INVITE
transaction while a regular transaction is in progress.</pre></div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">2. Shouldn&#39;t FS send a BYE after sending a 200Ok and not receiving the ACK?</div>
<div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px"><pre style="white-space:pre-wrap;font-size:1em;margin-bottom:0px;margin-top:0px">If a UAS generates a 2xx response and never receives an ACK, it
SHOULD generate a BYE to terminate the dialog.</pre></div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">Best regards, </div><br clear="all" style="font-family:arial,sans-serif;font-size:13px">
<div style="font-family:arial,sans-serif;font-size:13px"><div dir="ltr">Flavio E. Goncalves</div></div><div><div dir="ltr"><div><br></div></div></div>
</div>