<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=utf-8">
  </head>
  <body bgcolor="#FFFFFF" text="#000066">
    <font face="Courier New, Courier, monospace">Hello;<br>
          i have trouble with BYE routing and loose routing and kamailio
      sometimes looping itselft Bye packets.i checked loose routing and
      bye packet routing here
<a class="moz-txt-link-rfc2396E" href="https://voipmagazine.wordpress.com/2014/12/05/strict-and-loose-routing-of-sip-sequential-requests/">"https://voipmagazine.wordpress.com/2014/12/05/strict-and-loose-routing-of-sip-sequential-requests/"</a>
      and here <a class="moz-txt-link-freetext" href="http://www.ietf.org/rfc/rfc3261.txt">http://www.ietf.org/rfc/rfc3261.txt</a> .<br>
      <br>
      i tought that if top route header with lr is itself , next route
      header will be sent but it sending itself so looping. once , it
      was happened on INVITE transaction and i disabled register_myself
      on domain module. , couldnt figure out why it happens.<br>
      <br>
      Kamailio2 and Asterisk has same interface but different port. i
      put and exit method when looping itself and saved day.<br>
      <br>
      <br>
      Thanks for helps<br>
      <br>
      Here is call flow<br>
      <br>
      INVITE <br>
      UAC---> Kamailio-1:5060 ---> Kamailio2:5061--->Asterisk<br>
      <br>
      <br>
      BYE<br>
      UAC   Kamailio-1:5060    Kamailio-2:5061 <----- Asterisk:5060<br>
                               Kamailio-2:5061 <----- Kamailio-2:5061<br>
                               </font><font face="Courier New, Courier,
      monospace">Kamailio-2:5061 <----- Kamailio-2:5061<br>
                                  .....<br>
                                  .....<br>
                                  .....<br>
      <br>
      BYE sip:02165783@uacip:5061 SIP/2.0<br>
      Via: SIP/2.0/UDP
      kamailio2-asterisk-ip:5060;branch=z9hG4bK0a96e9e7;rport<br>
      Route:
<sip:kamailio2-asterisk-ip:5061;lr;ftag=a186f178d9678251c214192a12fae999;did=ec.4872;vsf=AAAAAAkCAwcDAg8LAwQGcHEBFgQeFggAAB4yMDI->,<sip:kamailio1ip;lr;ftag=a186f178d9678251c214192a12fae999><br>
      Max-Forwards: 70<br>
      From: <sip:0545402@kamailio1ip>;tag=as5cbb7b4a<br>
      To: 902165783
<sip:902165783@kamailio2-asterisk-ip>;tag=a186f178d9678251c214192a12fae999<br>
      Call-ID: <a class="moz-txt-link-abbreviated" href="mailto:462c9c3e105cb2d84b9e47cf79926a55@10.10.0.70">462c9c3e105cb2d84b9e47cf79926a55@10.10.0.70</a><br>
      CSeq: 102 BYE<br>
      User-Agent: sipgw2<br>
      X-Asterisk-HangupCause: Normal Clearing<br>
      X-Asterisk-HangupCauseCode: 16<br>
      Content-Length: 0<br>
    </font>
  </body>
</html>