<h3>Description</h3>
<p>I have an instance of Kamailio running with topos module enabled as described bellow:</p>
<p>(Core network)    <--->   (<strong>Kamailio</strong> running on 192.168.70.106:5061)  <--> (Provider network)</p>
<p>Here is the scenario:</p>
<ol>
<li>An INVITE comming from Core network through Kamailio to the Provider network and the call is established correctly (with 200 OK and ACK correctly routed).</li>
<li>The call is put on hold by the callee. A RE-INVITE comming from Provider network through Kamailio to the Core network. This REINVITE is routed correctly.</li>
<li>The Core network sent 200 OK reply to the RE-INVITE. The 200 OK message reached the Kamailio and was dropped there. (It SHOULD go back to the Provider network).</li>
</ol>
<h4>Log Messages</h4>

<p>When Kamailio received this 200 OK, I see this log message:</p>
<pre><code>ERROR: topos [tps_storage.c:1299]: tps_db_update_dialog(): no valid dlg uuid (0: - 0:)
</code></pre>
<h4>SIP Traffic</h4>

<p><strong>Here is the REINVITE message arriving from our provider:</strong></p>
<pre><code>INVITE sip:btpsh-5acddf40-d74-5@192.168.70.106:5061 SIP/2.0
Call-ID: 79acbb714c21354c
Contact: sip:80.10.231.10:5060;transport=udp
Content-Type: application/sdp
CSeq: 1 INVITE
From: sip:xxxx@xxxx;user=phone;tag=SDt2dkc98-04020267673121
Max-Forwards: 63
Record-Route: sip:192.168.70.126:5060;user=i0o0S000000ad;lr;Cpkt=XWJOA;C=xxxx,sip:192.168.70.126:5070;user=00000214;lr;Cpkt=YJJEE;C=xxx
To: sip:+yyyy@xxxx;user=phone;tag=1713351228
Via: SIP/2.0/UDP 192.168.70.126:5060;branch=z9hG4bK-XWJO-000227ab-7eda6242,SIP/2.0/UDP 192.168.70.126:5070;received=192.168.70.126;rport=5070;branch=z9hG4bK-YJJE-000a057c-0bf8ef7c,SIP/2.0/UDP 193.200.4.20:5060;emission,SIP/2.0/UDP 80.10.231.10:5060;received=80.10.231.10;rport=5060;branch=z9hG4bK5g8vgn00cobc0atd6hf0sb0000g00.1
Accept: application/sdp
Allow: INVITE,ACK,CANCEL,BYE,OPTIONS,PRACK
Content-Length: 236
</code></pre>
<p><strong>Here is the REINVITE comming out of Kamailio into our core side:</strong></p>
<pre><code>INVITE sip:192.168.40.106:5090;did=d03.e3be0354 SIP/2.0
Via: SIP/2.0/UDP 192.168.70.106:5061;branch=z9hG4bK443f.2ec12863719a69f1e3851178d9cb21d0.0
Call-ID: 79acbb714c21354c
Content-Type: application/sdp
CSeq: 1 INVITE
From: sip:+xxx@xxxx;tag=SDt2dkc98-04020267673121
Max-Forwards: 62
To: sip:xxx@xxxx;tag=1713351228
Accept: application/sdp
Allow: INVITE,ACK,CANCEL,BYE,OPTIONS,PRACK
Content-Length: 236
Route: xxx
Contact: sip:atpsh-5acddf40-d75-5@192.168.70.106:5061
</code></pre>
<p><strong>Here is the 200 OK for this REINVITE message comming from the Core network</strong> (This message arrived to Kamailio but is never sent to our provider).</p>
<pre><code>SIP/2.0 200 OK
Via: SIP/2.0/UDP 192.168.70.106:5061;branch=z9hG4bK443f.2ec12863719a69f1e3851178d9cb21d0.0
From: sip:+xxx@xxxx;tag=SDt2dkc98-04020267673121
To: sip:xxx@xxxx;tag=1713351228
Call-ID: 79acbb714c21354c
CSeq: 1 INVITE
Contact: sip:192.168.40.106:5090;did=d03.e3be0354
Allow: ACK, INVITE, BYE, CANCEL, REGISTER, REFER, OPTIONS, INFO
Content-Type: application/sdp
Content-Length: 197
</code></pre>
<h3>Additional Information</h3>
<ul>
<li><strong>Kamailio Version</strong> - output of <code>kamailio -v</code></li>
</ul>
<p>kamailio 5.1.2</p>
<ul>
<li><strong>Operating System</strong>:</li>
</ul>

<p>Centos Linux 3.10.0-514.26.1.el7.x86_64</p>
<ul>
<li><strong>Database</strong>:</li>
</ul>
<p>PostgreSQL 9.4</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/kamailio/kamailio/issues/1496">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AF36ZaaShCcyEV3cDmqE8hVmKJR5jIJwks5tnhFVgaJpZM4TQIEB">mute the thread</a>.<img src="https://github.com/notifications/beacon/AF36ZbhtSd3ArxZiQUygNTzNo85KPFNCks5tnhFVgaJpZM4TQIEB.gif" height="1" width="1" alt="" /></p>
<div itemscope itemtype="http://schema.org/EmailMessage">
<div itemprop="action" itemscope itemtype="http://schema.org/ViewAction">
  <link itemprop="url" href="https://github.com/kamailio/kamailio/issues/1496"></link>
  <meta itemprop="name" content="View Issue"></meta>
</div>
<meta itemprop="description" content="View this Issue on GitHub"></meta>
</div>

<script type="application/json" data-scope="inboxmarkup">{"api_version":"1.0","publisher":{"api_key":"05dde50f1d1a384dd78767c55493e4bb","name":"GitHub"},"entity":{"external_key":"github/kamailio/kamailio","title":"kamailio/kamailio","subtitle":"GitHub repository","main_image_url":"https://cloud.githubusercontent.com/assets/143418/17495839/a5054eac-5d88-11e6-95fc-7290892c7bb5.png","avatar_image_url":"https://cloud.githubusercontent.com/assets/143418/15842166/7c72db34-2c0b-11e6-9aed-b52498112777.png","action":{"name":"Open in GitHub","url":"https://github.com/kamailio/kamailio"}},"updates":{"snippets":[{"icon":"DESCRIPTION","message":"200 OK message for RE-INVITE is dropped when using topos module (#1496)"}],"action":{"name":"View Issue","url":"https://github.com/kamailio/kamailio/issues/1496"}}}</script>