<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <p>Hello,<br>
    </p>
    in the new email, the t_load_contacts() and drop are commented.<br>
    <br>
    Is it how you have them in the config or again some formatting
    issue?<br>
    <br>
    Cheers,<br>
    Daniel<br>
    <br>
    <div class="moz-cite-prefix">On 04/07/16 15:13, John Petrini wrote:<br>
    </div>
    <blockquote
cite="mid:CAD4AmV4B4o+LkFj6tyc8W9EwqV8EJ51MV-ETjthD2cNtFPoBdg@mail.gmail.com"
      type="cite">
      <div dir="ltr">Hi Daniel,
        <div><br>
        </div>
        <div>I made a mistake with my formatting when I pasted here. I
          am calling append_branch() before t_load_contacts. I've
          attached a view of the entire route including where I was
          using drop; below. Also a packet capture that shows Kamailio
          forwarding the reply from the cnam provider back to the phone.
          I've discovered t_cancel_branches("this") and that seems to be
          doing the job of killing the second branch as well as the
          reply to the phone.</div>
        <div><br>
        </div>
        <div>My main issue right now is serializing the branches,
          append_branch creates an additional branch but t_load_contacts
          fails. I've tried appending multiple branches and also using
          seturi to replicate the documentation as closely as possible
          with no luck.</div>
        <div><br>
        </div>
        <div>
          <div style="font-size:12.8px">route[CNAM_DIPS] {</div>
          <div style="font-size:12.8px">  if ($avp(direction) == "in") {</div>
          <span class="im" style="font-size:12.8px">
            <div>    t_on_branch("CNAM_DIPS");</div>
            <div>    t_on_reply("CNAM_DIPS");</div>
            <div>    t_on_failure("CNAM_DIPS");</div>
          </span>
          <div style="font-size:12.8px">    $var(reply_count) = 0;<br>
          </div>
          <div style="font-size:12.8px">
            <div>    append_branch("sip:<a moz-do-not-send="true"
                href="tel:2152974400" value="+12152974400"
                target="_blank">8888888888</a>@<span
                style="font-size:small">222.22.222.22</span>:5060;trans-type=5",
              "0.5");</div>
            <div>    #t_load_contacts();</div>
            <div>    t_next_contacts();</div>
            <div>    t_relay();</div>
            <div>    break;</div>
          </div>
          <div style="font-size:12.8px">
            <div>  }</div>
            <div>}</div>
          </div>
          <div style="font-size:12.8px"><br>
          </div>
          <div style="font-size:12.8px">
            <div>branch_route[CNAM_DIPS] {</div>
            <div>  $var(modified_from) = "sip:" + $fU + "@<a
                moz-do-not-send="true" href="http://sip.core.com/"
                target="_blank">sip.core.com</a>";</div>
            <div>  uac_replace_from("$var(modified_from)");</div>
            <div>}</div>
          </div>
          <div style="font-size:12.8px"><br>
          </div>
          <div style="font-size:12.8px">
            <div>onreply_route[CNAM_DIPS] {</div>
            <div>  $var(reply_count) = $var(reply_count) + 1;</div>
            <div>  if (t_check_status("380")) {</div>
            <div>    $avp(cnam) = $(hdr(P-Asserted-Identity){<a
                moz-do-not-send="true" href="http://nameaddr.name/"
                target="_blank">nameaddr.name</a>});</div>
            <div>  } else {</div>
            <div>      xlog("L_ERROR", "INFO: Received bad reply
              (on_reply_route[CNAM_DIPS]):"); </div>
            <div>  };</div>
            <div>
              <div>  if ($var(reply_count) = 1) {</div>
              <div>    t_cancel_branches("this");</div>
              <div>  }</div>
            </div>
            <div>  #drop;</div>
            <div>}</div>
          </div>
          <div style="font-size:12.8px"><br>
          </div>
          <div style="font-size:12.8px">
            <div>failure_route[CNAM_DIPS] {</div>
            <div>  if (!t_next_contacts()) {</div>
            <div>    xlog("L_ERR", "ERROR: Gateway failure
              (failure_route[CNAM_DIPS]): Failed to ship call");</div>
            <div>    exit;</div>
            <div>  } else {</div>
            <div>      t_next_contacts();</div>
            <div>      t_relay();</div>
            <div>  };</div>
            <div>}</div>
          </div>
        </div>
        <div><br>
        </div>
        <div>
          <div><br>
          </div>
          <div>Packet capture using drop in the on_reply route rather
            than t_cancel_branches("this"):</div>
          <div><br>
          </div>
          <div>
            <div>U 2016/07/04 08:46:41.223295 44.444.4.444:5060 ->
              333.33.33.3:5060</div>
            <div>INVITE <a moz-do-not-send="true"
                href="http://sip:+12222222222@core.com:5060">sip:+12222222222@core.com:5060</a>
              SIP/2.0.</div>
            <div>Via: SIP/2.0/UDP
              44.444.4.444:5060;branch=z9hG4bK04Bef9112d99372eace.</div>
            <div>From: "UNKNOWN"
              <a class="moz-txt-link-rfc2396E" href="sip:+13333333333@44.444.4.444;isup-oli=62"><sip:+13333333333@44.444.4.444;isup-oli=62></a>;tag=gK046fcff6.</div>
            <div>To: <<a moz-do-not-send="true"
                href="mailto:sip%3A2222222222@core.com">sip:2222222222@core.com</a>>.</div>
            <div>Call-ID: <a class="moz-txt-link-abbreviated" href="mailto:1698991986_66771899@44.444.4.444">1698991986_66771899@44.444.4.444</a>.</div>
            <div>CSeq: 468700 INVITE.</div>
            <div>Max-Forwards: 70.</div>
            <div>Allow: INVITE,ACK,CANCEL,BYE,OPTIONS.</div>
            <div>Accept: application/sdp.</div>
            <div>Contact: "UNKNOWN"
              <a class="moz-txt-link-rfc2396E" href="sip:+13333333333@44.444.4.444:5060"><sip:+13333333333@44.444.4.444:5060></a>.</div>
            <div>P-Asserted-Identity: "UNKNOWN"
              <a class="moz-txt-link-rfc2396E" href="sip:+13333333333@44.444.4.444:5060"><sip:+13333333333@44.444.4.444:5060></a>.</div>
            <div>Supported: replaces.</div>
            <div>Content-Length:   281.</div>
            <div>Content-Disposition: session; handling=required.</div>
            <div>Content-Type: application/sdp.</div>
            <div>.</div>
            <div>v=0.</div>
            <div>o=Sonus_UAC 807784 731434 IN IP4 44.444.4.444.</div>
            <div>s=SIP Media Capabilities.</div>
            <div>c=IN IP4 55.555.5.55.</div>
            <div>t=0 0.</div>
            <div>m=audio 54018 RTP/AVP 0 18 101.</div>
            <div>a=rtpmap:0 PCMU/8000.</div>
            <div>a=rtpmap:18 G729/8000.</div>
            <div>a=fmtp:18 annexb=no.</div>
            <div>a=rtpmap:101 telephone-event/8000.</div>
            <div>a=fmtp:101 0-15.</div>
            <div>a=sendrecv.</div>
            <div>a=ptime:20.</div>
            <div><br>
            </div>
            <div><br>
            </div>
            <div>U 2016/07/04 08:46:41.230033 333.33.33.3:5060 ->
              44.444.4.444:5060</div>
            <div>SIP/2.0 100 trying -- your call is important to us.</div>
            <div>Via: SIP/2.0/UDP
              44.444.4.444:5060;branch=z9hG4bK04Bef9112d99372eace.</div>
            <div>From: "UNKNOWN"
              <a class="moz-txt-link-rfc2396E" href="sip:+13333333333@44.444.4.444;isup-oli=62"><sip:+13333333333@44.444.4.444;isup-oli=62></a>;tag=gK046fcff6.</div>
            <div>To: <<a moz-do-not-send="true"
                href="mailto:sip%3A2222222222@core.com">sip:2222222222@core.com</a>>.</div>
            <div>Call-ID: <a class="moz-txt-link-abbreviated" href="mailto:1698991986_66771899@44.444.4.444">1698991986_66771899@44.444.4.444</a>.</div>
            <div>CSeq: 468700 INVITE.</div>
            <div>Server: kamailio (4.2.7 (x86_64/linux)).</div>
            <div>Content-Length: 0.</div>
            <div>.</div>
            <div><br>
            </div>
            <div><br>
            </div>
            <div>U 2016/07/04 08:46:41.234143 333.33.33.3:5060 -> <a
                moz-do-not-send="true" href="http://222.22.222.22:5060">222.22.222.22:5060</a></div>
            <div>INVITE <a class="moz-txt-link-freetext" href="sip:8888888888@222.22.222.22:5060;trans-type=5">sip:8888888888@222.22.222.22:5060;trans-type=5</a>
              SIP/2.0.</div>
            <div>Record-Route:
<a class="moz-txt-link-rfc2396E" href="sip:333.33.33.3;lr;ftag=gK046fcff6;vsf=AAAAAAAAAAAAAAAAAAAAAABFXl4cUF5cXABSXl87aXN1cC1vbGk9NjI-"><sip:333.33.33.3;lr;ftag=gK046fcff6;vsf=AAAAAAAAAAAAAAAAAAAAAABFXl4cUF5cXABSXl87aXN1cC1vbGk9NjI-></a>.</div>
            <div>Via: SIP/2.0/UDP
              333.33.33.3;branch=z9hG4bK8ac3.daa229dcb24f16332fa5a21927e9a72f.0.</div>
            <div>Via: SIP/2.0/UDP
              44.444.4.444:5060;branch=z9hG4bK04Bef9112d99372eace.</div>
            <div>From: "UNKNOWN" <<a moz-do-not-send="true"
                href="mailto:sip%3A%2B13333333333@sip.core.com">sip:+13333333333@sip.core.com</a>>;tag=gK046fcff6.</div>
            <div>To: <<a moz-do-not-send="true"
                href="mailto:sip%3A2222222222@core.com">sip:2222222222@core.com</a>>.</div>
            <div>Call-ID: <a class="moz-txt-link-abbreviated" href="mailto:1698991986_66771899@44.444.4.444">1698991986_66771899@44.444.4.444</a>.</div>
            <div>CSeq: 468700 INVITE.</div>
            <div>Max-Forwards: 69.</div>
            <div>Allow: INVITE,ACK,CANCEL,BYE,OPTIONS.</div>
            <div>Accept: application/sdp.</div>
            <div>Contact: "UNKNOWN"
              <a class="moz-txt-link-rfc2396E" href="sip:+13333333333@44.444.4.444:5060"><sip:+13333333333@44.444.4.444:5060></a>.</div>
            <div>P-Asserted-Identity: "UNKNOWN"
              <a class="moz-txt-link-rfc2396E" href="sip:+13333333333@44.444.4.444:5060"><sip:+13333333333@44.444.4.444:5060></a>.</div>
            <div>Supported: replaces.</div>
            <div>Content-Length:   281.</div>
            <div>Content-Disposition: session; handling=required.</div>
            <div>Content-Type: application/sdp.</div>
            <div>P-hint: branch_route CNAM_DIPS.</div>
            <div>.</div>
            <div>v=0.</div>
            <div>o=Sonus_UAC 807784 731434 IN IP4 44.444.4.444.</div>
            <div>s=SIP Media Capabilities.</div>
            <div>c=IN IP4 55.555.5.55.</div>
            <div>t=0 0.</div>
            <div>m=audio 54018 RTP/AVP 0 18 101.</div>
            <div>a=rtpmap:0 PCMU/8000.</div>
            <div>a=rtpmap:18 G729/8000.</div>
            <div>a=fmtp:18 annexb=no.</div>
            <div>a=rtpmap:101 telephone-event/8000.</div>
            <div>a=fmtp:101 0-15.</div>
            <div>a=sendrecv.</div>
            <div>a=ptime:20.</div>
            <div><br>
            </div>
            <div><br>
            </div>
            <div>U 2016/07/04 08:46:41.367868 <a moz-do-not-send="true"
                href="http://222.22.222.22:5060">222.22.222.22:5060</a>
              -> 333.33.33.3:5060</div>
            <div>SIP/2.0 380 cnam lookup.</div>
            <div>Via: SIP/2.0/UDP
              333.33.33.3;branch=z9hG4bK8ac3.daa229dcb24f16332fa5a21927e9a72f.0.</div>
            <div>Via: SIP/2.0/UDP
              44.444.4.444:5060;branch=z9hG4bK04Bef9112d99372eace.</div>
            <div>From: "UNKNOWN" <<a moz-do-not-send="true"
                href="mailto:sip%3A%2B13333333333@sip.core.com">sip:+13333333333@sip.core.com</a>>;tag=gK046fcff6.</div>
            <div>To:  <<a moz-do-not-send="true"
                href="mailto:sip%3A2222222222@core.com">sip:2222222222@core.com</a>>;tag=CNAM-16688-1467636671937.</div>
            <div>Call-ID: <a class="moz-txt-link-abbreviated" href="mailto:1698991986_66771899@44.444.4.444">1698991986_66771899@44.444.4.444</a>.</div>
            <div>CSeq: 468700 INVITE.</div>
            <div>Contact: "CNAM" <<a moz-do-not-send="true"
                href="mailto:sip%3Acnam_gw@10.212.16.30">sip:cnam_gw@10.212.16.30</a>>;
              transport=udp.</div>
            <div>Max-Forwards: 10.</div>
            <div>P-Asserted-Identity: "Unavailable" <<a
                moz-do-not-send="true"
                href="mailto:sip%3A%2B13333333333@sip.core.com"><a class="moz-txt-link-freetext" href="sip:+13333333333@sip.core.com">sip:+13333333333@sip.core.com</a></a>>.</div>
            <div>Content-Length: 0.</div>
            <div>.</div>
            <div><br>
            </div>
            <div><br>
            </div>
            <div>U 2016/07/04 08:46:41.368421 333.33.33.3:5060 -> <a
                moz-do-not-send="true" href="http://222.22.222.22:5060">222.22.222.22:5060</a></div>
            <div>ACK <a class="moz-txt-link-freetext" href="sip:8888888888@222.22.222.22:5060;trans-type=5">sip:8888888888@222.22.222.22:5060;trans-type=5</a>
              SIP/2.0.</div>
            <div>Via: SIP/2.0/UDP
              333.33.33.3;branch=z9hG4bK8ac3.daa229dcb24f16332fa5a21927e9a72f.0.</div>
            <div>From: "UNKNOWN" <<a moz-do-not-send="true"
                href="mailto:sip%3A%2B13333333333@sip.core.com">sip:+13333333333@sip.core.com</a>>;tag=gK046fcff6.</div>
            <div>To:  <<a moz-do-not-send="true"
                href="mailto:sip%3A2222222222@core.com">sip:2222222222@core.com</a>>;tag=CNAM-16688-1467636671937.</div>
            <div>Call-ID: <a class="moz-txt-link-abbreviated" href="mailto:1698991986_66771899@44.444.4.444">1698991986_66771899@44.444.4.444</a>.</div>
            <div>CSeq: 468700 ACK.</div>
            <div>Max-Forwards: 69.</div>
            <div>Content-Length: 0.</div>
            <div>.</div>
            <div><br>
            </div>
            <div><br>
            </div>
            <div>U 2016/07/04 08:46:44.227076 333.33.33.3:5060 ->
              44.444.4.444:5060</div>
            <div>SIP/2.0 380 cnam lookup.</div>
            <div>Via: SIP/2.0/UDP
              44.444.4.444:5060;branch=z9hG4bK04Bef9112d99372eace.</div>
            <div>From: "UNKNOWN"
              <a class="moz-txt-link-rfc2396E" href="sip:+13333333333@44.444.4.444;isup-oli=62"><sip:+13333333333@44.444.4.444;isup-oli=62></a>;tag=gK046fcff6.</div>
            <div>To:  <<a moz-do-not-send="true"
                href="mailto:sip%3A2222222222@core.com">sip:2222222222@core.com</a>>;tag=CNAM-16688-1467636671937.</div>
            <div>Call-ID: <a class="moz-txt-link-abbreviated" href="mailto:1698991986_66771899@44.444.4.444">1698991986_66771899@44.444.4.444</a>.</div>
            <div>CSeq: 468700 INVITE.</div>
            <div>Contact: "CNAM" <<a moz-do-not-send="true"
                href="mailto:sip%3Acnam_gw@10.212.16.30">sip:cnam_gw@10.212.16.30</a>>;
              transport=udp.</div>
            <div>Max-Forwards: 10.</div>
            <div>P-Asserted-Identity: "Unavailable" <<a
                moz-do-not-send="true"
                href="mailto:sip%3A%2B13333333333@sip.core.com"><a class="moz-txt-link-freetext" href="sip:+13333333333@sip.core.com">sip:+13333333333@sip.core.com</a></a>>.</div>
            <div>Content-Length: 0.</div>
            <div>P-hint: onreply CNAM_DIPS.</div>
            <div>.</div>
          </div>
          <div><br>
          </div>
          <div><br>
          </div>
          <div><br>
          </div>
        </div>
        <div><br>
        </div>
      </div>
      <div class="gmail_extra"><br clear="all">
        <div>
          <div class="gmail_signature" data-smartmail="gmail_signature">
            <div dir="ltr">
              <div>
                <div dir="ltr">
                  <div>
                    <div dir="ltr">
                      <div dir="ltr">
                        <div dir="ltr">
                          <p
style="margin-top:8px;margin-bottom:8px;font-family:Helvetica,Verdana,Arial,sans-serif;font-size:0.85em;color:rgb(51,51,51);line-height:1.4"><span
                              style="font-size:0.85em;line-height:1.4">___</span><br>
                          </p>
                          <p
style="margin-top:8px;margin-bottom:8px;font-family:Helvetica,Verdana,Arial,sans-serif;font-size:1.1em;color:rgb(51,51,51);line-height:1.4">John
                            Petrini</p>
                          <p
style="margin-top:8px;margin-bottom:8px;font-family:Helvetica,Verdana,Arial,sans-serif;font-size:0.85em;color:rgb(51,51,51);line-height:1.6">NOC
                            Systems Administrator   //   <strong>CoreDial,
                              LLC</strong>   //   <a
                              moz-do-not-send="true"
                              href="http://coredial.com/"
                              title="CoreDial"
                              style="color:rgb(35,104,179);text-decoration:none"
                              target="_blank">coredial.com</a>   //   <a
                              moz-do-not-send="true"
                              href="https://twitter.com/coredial"
                              target="_blank"><img
                                moz-do-not-send="true"
src="http://cdn2.hubspot.net/hub/210539/file-2353637622-gif/email/twitter-1.gif"
                                alt="Twitter"
                                style="vertical-align:text-bottom"></a>   <a
                              moz-do-not-send="true"
                              href="http://www.linkedin.com/company/99631"
                              target="_blank"><img
                                moz-do-not-send="true"
src="http://cdn2.hubspot.net/hub/210539/file-2351103565-gif/email/linkedin-1.gif"
                                alt="LinkedIn"
                                style="vertical-align:text-bottom"></a>   <a
                              moz-do-not-send="true"
                              href="https://plus.google.com/104062177220750809525/posts"
                              target="_blank"><img
                                moz-do-not-send="true"
src="http://cdn2.hubspot.net/hub/210539/file-2353637617-gif/email/googleplus-1.gif"
                                alt="Google Plus"
                                style="vertical-align:text-bottom"></a>   <a
                              moz-do-not-send="true"
                              href="http://success.coredial.com/blog"
                              target="_blank"><img
                                moz-do-not-send="true"
src="http://cdn2.hubspot.net/hub/210539/file-2351103560-gif/email/rss-1.gif"
                                alt="Blog"
                                style="vertical-align:text-bottom"></a> <br>
                            Hillcrest I, 751 Arbor Way, Suite 150,
                            Blue Bell PA, 19422 <br>
                            <strong>P: </strong><a
                              moz-do-not-send="true"
                              style="color:rgb(35,104,179)">215.297.4400</a> x232
                              //   <strong>F: </strong><a
                              moz-do-not-send="true"
                              style="color:rgb(35,104,179)">215.297.4401</a>   //   <strong>E: </strong><a
                              moz-do-not-send="true"
                              href="mailto:jpetrini@coredial.com"
                              style="color:rgb(35,104,179);text-decoration:none"
                              target="_blank"><a class="moz-txt-link-abbreviated" href="mailto:jpetrini@coredial.com">jpetrini@coredial.com</a></a></p>
                          <p style="color:rgb(0,0,0);font-family:'Times
                            New Roman';font-size:medium"><a
                              moz-do-not-send="true"
href="http://cta-redirect.hubspot.com/cta/redirect/210539/4c492538-6e4b-445e-9480-bef676787085"
                              target="_blank"><img
                                moz-do-not-send="true"
src="https://no-cache.hubspot.com/cta/default/210539/4c492538-6e4b-445e-9480-bef676787085.png"
                                alt="Exceptional people. Proven
                                Processes. Innovative Technology.
                                Discover CoreDial - watch our video"
                                style="border-width:0px"></a></p>
                          <p
style="padding-top:15px;padding-bottom:15px;max-width:600px;font-family:Helvetica,Verdana,Arial,sans-serif;font-size:0.6em;color:rgb(51,51,51);line-height:1.4">The
                            information transmitted is intended only for
                            the person or entity to which it is
                            addressed and may contain confidential
                            and/or privileged material. Any review,
                            retransmission,  dissemination or other use
                            of, or taking of any action in reliance
                            upon, this information by persons or
                            entities other than the intended recipient
                            is prohibited. If you received this in
                            error, please contact the sender and delete
                            the material from any computer.</p>
                        </div>
                      </div>
                    </div>
                  </div>
                </div>
              </div>
            </div>
          </div>
        </div>
        <br>
      </div>
    </blockquote>
    <br>
    <pre class="moz-signature" cols="72">-- 
Daniel-Constantin Mierla
<a class="moz-txt-link-freetext" href="http://www.asipto.com">http://www.asipto.com</a> - <a class="moz-txt-link-freetext" href="http://www.kamailio.org">http://www.kamailio.org</a>
<a class="moz-txt-link-freetext" href="http://twitter.com/#!/miconda">http://twitter.com/#!/miconda</a> - <a class="moz-txt-link-freetext" href="http://www.linkedin.com/in/miconda">http://www.linkedin.com/in/miconda</a></pre>
  </body>
</html>