<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix"><tt>Hello Tito,<br>
        <br>
        Simply use the setbflag() functions:<br>
           
        <a class="moz-txt-link-freetext" href="http://www.opensips.org/Documentation/Script-CoreFunctions-1-11#toc21">http://www.opensips.org/Documentation/Script-CoreFunctions-1-11#toc21</a><br>
           
        <a class="moz-txt-link-freetext" href="http://www.opensips.org/Documentation/Script-CoreFunctions-1-11#toc50">http://www.opensips.org/Documentation/Script-CoreFunctions-1-11#toc50</a><br>
        <br>
        Regards,<br>
      </tt>
      <pre class="moz-signature" cols="72">Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
<a class="moz-txt-link-freetext" href="http://www.opensips-solutions.com">http://www.opensips-solutions.com</a></pre>
      On 24.09.2014 22:11, Tito Cumpen wrote:<br>
    </div>
    <blockquote
cite="mid:CANZPVB6CSyXrvUC9=QEVjNgZcJtZZy6pyaGeOFSNw5_ne3h+9w@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div>Bogdan,</div>
        <div><br>
        </div>
        <div><br>
        </div>
        After reconsidering the requirements I find the easiest thing to
        do would be to set a flag on the branch during its creation and
        remove the header in the per branch route. Although I cant seem
        to find examples of setting a branch flag and referencing to it.
        Do you have documentation or examples you can point me to?
        <div><br>
        </div>
        <div>Thanks,</div>
        <div>Tito</div>
      </div>
      <div class="gmail_extra"><br>
        <div class="gmail_quote">On Wed, Sep 17, 2014 at 3:36 AM,
          Bogdan-Andrei Iancu <span dir="ltr">&lt;<a
              moz-do-not-send="true" href="mailto:bogdan@opensips.org"
              target="_blank">bogdan@opensips.org</a>&gt;</span> wrote:<br>
          <blockquote class="gmail_quote" style="margin:0 0 0
            .8ex;border-left:1px #ccc solid;padding-left:1ex">
            <div text="#000000" bgcolor="#FFFFFF">
              <div><tt>Hi Tito,<br>
                  <br>
                  Instead of consume_credentials() you can simply do
                  remove_hf("Proxy-Authorization") - it does the same.<br>
                  <br>
                  Regarding the second part, I do not get the problem -
                  in branch route, if $du or $ru does not point to you,
                  you want to remove the credentials - what the is the
                  problem here ?<br>
                  <br>
                  Regards,<br>
                </tt><span class="">
                  <pre cols="72">Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
<a moz-do-not-send="true" href="http://www.opensips-solutions.com" target="_blank">http://www.opensips-solutions.com</a></pre>
                </span>
                <div>
                  <div class="h5"> On 17.09.2014 08:13, Tito Cumpen
                    wrote:<br>
                  </div>
                </div>
              </div>
              <div>
                <div class="h5">
                  <blockquote type="cite">
                    <div dir="ltr">Bogdan,
                      <div><br>
                      </div>
                      <div>the branch route seems pretty limited in
                        functionality. How would you compare a $du to
                        allow credentials to traverse when they are
                        going to a neighbor proxy? Also noticed you cant
                        use consume_credentials(). </div>
                      <div><br>
                      </div>
                      <div>
                        <p><span>if(uri !</span><span>=</span> myself )
                          { </p>
                        <p><span>                </span>#consume_credentials();</p>
                        <p>                xlog("This is branch is not
                          for me $ru")<span>;</span></p>
                        <p><br>
                        </p>
                        <p>}</p>
                        <p><br>
                        </p>
                        <p>the above will not work since branches are
                          going to aor entries along with neighbor
                          proxies set like this:</p>
                        <p>                    while loop{</p>
                        <p>                                       
                          avp_subst("$avp(myloc<span>[$var(i)]</span>)",
                          "/(.+)/\sip:\0/")<span>;</span></p>
                        <p><br>
                        </p>
                        <p>                                       
                          xlog("$avp(myloc<span>[$var(i)]</span>)\n")<span>;</span></p>
                        <p>                                       
                          avp_pushto("$du","$avp(myloc<span>[$var(i)]</span>)")<span>;</span></p>
                        <p>                                       
                          insert_hf("Subject:traversal\r\n",  "p-hint")<span>;</span></p>
                        <p>                                       
                          append_branch()<span>;</span><br>
                        </p>
                        <p> </p>
                        <p><br>
                        </p>
                        <p>}</p>
                        <p><br>
                        </p>
                      </div>
                      <div>Much Appreciated,</div>
                      <div><br>
                      </div>
                      <div>Tito</div>
                    </div>
                    <div class="gmail_extra"><br>
                      <div class="gmail_quote">On Fri, Sep 12, 2014 at
                        5:45 PM, Tito Cumpen <span dir="ltr">&lt;<a
                            moz-do-not-send="true"
                            href="mailto:tito@xsvoce.com"
                            target="_blank">tito@xsvoce.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 dir="ltr">Thanks Bogdan,
                            <div><br>
                            </div>
                            <div>I found this shortly after I am now
                              allowing calls from neighbor proxies to
                              enter if the ret code is only 3 stale.
                              Thanks for your suggestion on handling
                              this in branch route I will now check if
                              $du (neighbor) proxy is the branch hop in
                              order to allow credentials to linger or be
                              removed.</div>
                            <div><br>
                            </div>
                            <div><br>
                            </div>
                          </div>
                          <div>
                            <div>
                              <div class="gmail_extra"><br>
                                <div class="gmail_quote">On Fri, Sep 12,
                                  2014 at 9:41 AM, Bogdan-Andrei Iancu <span
                                    dir="ltr">&lt;<a
                                      moz-do-not-send="true"
                                      href="mailto:bogdan@opensips.org"
                                      target="_blank">bogdan@opensips.org</a>&gt;</span>
                                  wrote:<br>
                                  <blockquote class="gmail_quote"
                                    style="margin:0 0 0
                                    .8ex;border-left:1px #ccc
                                    solid;padding-left:1ex">
                                    <div text="#000000"
                                      bgcolor="#FFFFFF">
                                      <div><tt>Hi Tito,<br>
                                          <br>
                                          If you do not to "consume
                                          credentials" after auth, the
                                          credentials will stay in your
                                          requests and they will be
                                          forwarded to the next hop
                                          (this is what you want, right
                                          ?).<br>
                                          <br>
                                          You can use branch_route[] to
                                          remove the credentials in a
                                          per branch manner .<br>
                                          <br>
                                          Regards,<br>
                                        </tt>
                                        <pre cols="72">Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
<a moz-do-not-send="true" href="http://www.opensips-solutions.com" target="_blank">http://www.opensips-solutions.com</a></pre>
                                        <div>
                                          <div> On 10.09.2014 23:59,
                                            Tito Cumpen wrote:<br>
                                          </div>
                                        </div>
                                      </div>
                                      <blockquote type="cite">
                                        <div>
                                          <div>
                                            <div dir="ltr">Group,
                                              <div><br>
                                              </div>
                                              <div><br>
                                              </div>
                                              <div>What is the adequate
                                                way to include or insert
                                                nonce response after a
                                                proxy challenge?</div>
                                              <div>I am forwarding
                                                invites to local and
                                                remote locations by
                                                forking. The remote
                                                proxy checks againsts
                                                the same db for
                                                authentication.
                                                Therefore I would to
                                                include the proxy
                                                authorization header
                                                when forwarding the
                                                invite to the remote
                                                locations. Currently I
                                                am being sent a 407 by
                                                the remote proxy which
                                                consequently kills ends
                                                the branch.</div>
                                              <div><br>
                                              </div>
                                              <div><br>
                                                Thanks,</div>
                                              <div>Tito</div>
                                            </div>
                                            <br>
                                            <fieldset></fieldset>
                                            <br>
                                          </div>
                                        </div>
                                        <pre>_______________________________________________
Users mailing list
<a moz-do-not-send="true" href="mailto:Users@lists.opensips.org" target="_blank">Users@lists.opensips.org</a>
<a moz-do-not-send="true" href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a>
</pre>
                                      </blockquote>
                                      <br>
                                    </div>
                                  </blockquote>
                                </div>
                                <br>
                              </div>
                            </div>
                          </div>
                        </blockquote>
                      </div>
                      <br>
                    </div>
                  </blockquote>
                  <br>
                </div>
              </div>
            </div>
          </blockquote>
        </div>
        <br>
      </div>
    </blockquote>
    <br>
  </body>
</html>