<html>
  <head>
    <meta content="text/html; charset=windows-1252"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <tt>Lo<tt>uis,<br>
        <br>
        <tt>Please open a feature request on the opensips GITHUB tracker
          and <tt>p<tt>robably it will be an easy one to do <tt>directly
                in the C <tt>code.<br>
                  <br>
                  <tt>Regards,</tt><br>
                </tt></tt></tt></tt></tt></tt></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>
    <div class="moz-cite-prefix">On 17.11.2015 22:35, Louis Rochon
      wrote:<br>
    </div>
    <blockquote
cite="mid:5E14682204D78E488EC3435C01D723E3015CFF770BA9@SolaMail.solacom.com"
      type="cite">
      <meta http-equiv="Content-Type" content="text/html;
        charset=windows-1252">
      <meta name="Generator" content="Microsoft Word 14 (filtered
        medium)">
      <style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:Verdana;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";
        color:black;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
pre
        {mso-style-priority:99;
        mso-style-link:"HTML Preformatted Char";
        margin:0in;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New","serif";
        color:black;}
tt
        {mso-style-priority:99;
        font-family:"Courier New","serif";}
span.HTMLPreformattedChar
        {mso-style-name:"HTML Preformatted Char";
        mso-style-priority:99;
        mso-style-link:"HTML Preformatted";
        font-family:Consolas;
        color:black;}
span.EmailStyle20
        {mso-style-type:personal;
        font-family:"Verdana","sans-serif";
        color:windowtext;}
span.EmailStyle21
        {mso-style-type:personal-reply;
        font-family:"Verdana","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
      <div class="WordSection1">
        <p class="MsoNormal"><span
style="font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">Bogdan,<o:p></o:p></span></p>
        <p class="MsoNormal"><span
style="font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p> </o:p></span></p>
        <p class="MsoNormal"><span
style="font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">Thank
            you for the detailed reply. Your test with
            remove_hf()+append_hf() confirms my observations.<o:p></o:p></span></p>
        <p class="MsoNormal"><span
style="font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p> </o:p></span></p>
        <p class="MsoNormal"><span
style="font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">And
            yes, my goal is to preserve the username part in B2B
            Contact, while retaining the top hiding function by
            substituting the host part – which it does already.<o:p></o:p></span></p>
        <p class="MsoNormal"><span
style="font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p> </o:p></span></p>
        <p class="MsoNormal"><span
style="font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">Any
            idea how to accomplish this?<o:p></o:p></span></p>
        <p class="MsoNormal"><span
style="font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p> </o:p></span></p>
        <p class="MsoNormal"><span
style="font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D">Louis
            <o:p></o:p></span></p>
        <p class="MsoNormal"><span
style="font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p> </o:p></span></p>
        <p class="MsoNormal"><span
style="font-family:&quot;Verdana&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p> </o:p></span></p>
        <div>
          <div style="border:none;border-top:solid #B5C4DF
            1.0pt;padding:3.0pt 0in 0in 0in">
            <p class="MsoNormal"><b><span
style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;;color:windowtext">From:</span></b><span
style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;;color:windowtext">
                Bogdan-Andrei Iancu [<a class="moz-txt-link-freetext" href="mailto:bogdan@opensips.org">mailto:bogdan@opensips.org</a>] <br>
                <b>Sent:</b> Wednesday, October 28, 2015 12:09 PM<br>
                <b>To:</b> OpenSIPS users mailling list; Louis Rochon<br>
                <b>Subject:</b> Re: [OpenSIPS-Users] remove_hf doesn't
                seem to work in route[b2b_reply]<o:p></o:p></span></p>
          </div>
        </div>
        <p class="MsoNormal"><o:p> </o:p></p>
        <p class="MsoNormal"><tt><span style="font-size:10.0pt">Hi
              Louis,</span></tt><span
            style="font-size:10.0pt;font-family:&quot;Courier
            New&quot;,&quot;serif&quot;"><br>
            <br>
            <tt>The b2b_reply route is invoked for int incoming reply.
              This reply is internally consumed and another one is
              generated on the other side of the B2B (basically there
              are two back 2 back transactions).</tt><br>
            <br>
            <tt>The new reply (on A side) is built based on information
              from the incoming reply (on B side) - considering that the
              original INVITE went from A to B.</tt><br>
            <br>
            <tt>So, any change you do on incoming rely will be discards
              because a new reply is to be built on the other side.
              Headers (as a whole) may propagate via "custom_headers"
              parameters. Otherwise, whatever append_hf() you do in
              b2b_reply will be lost (not translated to the other side).</tt><br>
            <br>
            <tt>Even more, the Contact has a special treatment as it is
              completely rebuilt by the B2B - old Contact hdr is
              discarded and a new one (pointing to B2B) is added in the
              outbound reply. So your changes over the incoming contact
              do conflict with the changed the B2B module does over the
              contact.</tt><br>
            <br>
            <tt>In my test, having "contact" in the "custom_headers" and
              doing remove_hf()+append_hf() on a contact on b2b_reply,
              results in two Contact headers :</tt><br>
            <tt>    - the one removed, added and carried via custom
              header (from the incoming reply)</tt><br>
            <tt>    - the one built and added internally by the B2B,
              pointing to it self</tt><br>
            <br>
            <tt>So, remove_hf() actually works, but you end up with that
              conflict in having you and the B2B changing both the
              Contact hdr.</tt><br>
            <br>
            <tt>As I understand, your goal is to preserve the username
              part in B2B right ?</tt><br>
            <br>
            <tt>Best regards,</tt><br>
            <br>
          </span><o:p></o:p></p>
        <pre>Bogdan-Andrei Iancu<o:p></o:p></pre>
        <pre>OpenSIPS Founder and Developer<o:p></o:p></pre>
        <pre><a moz-do-not-send="true" href="http://www.opensips-solutions.com">http://www.opensips-solutions.com</a><o:p></o:p></pre>
        <div>
          <p class="MsoNormal">On 15.10.2015 21:40, Louis Rochon wrote:<o:p></o:p></p>
        </div>
        <blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">remove_hf doesn't seem to
              work in route[b2b_reply]….Running OpenSIPS 1.11.5 on
              CentOS 6.</span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;"> </span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">This problem started when I
              discovered that b2b_init_requests removes the user part of
              the URI in the Contact: field.</span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;"> </span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">To correct that, did a bit of
              scripting to correct the outgoing invite:</span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;"> </span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">First, handle contacts
              manually:</span><o:p></o:p></p>
          <p class="MsoNormal" style="text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">modparam("b2b_logic",
              "custom_headers",
              "Priority;Calluid;Geolocation;Geolocation-Routing;Contact")</span><o:p></o:p></p>
          <p class="MsoNormal" style="text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;"> </span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">Second, check out the
              incoming INVITE, and modify the host part to be the
              OpenSIPs server itself (192.168.130.105):</span><o:p></o:p></p>
          <p class="MsoNormal" style="text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">$var(ContactURI)=$ct.fields(uri);</span><o:p></o:p></p>
          <p class="MsoNormal" style="text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">$var(ContactURIHost)=$(var(ContactURI){uri.host});</span><o:p></o:p></p>
          <p class="MsoNormal" style="text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">$var(ContactURIUser)=$(var(ContactURI){uri.user});</span><o:p></o:p></p>
          <p class="MsoNormal" style="text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">$var(regedit)="/"+$(var(ContactURIHost))+"/192.168.130.105/g";</span><o:p></o:p></p>
          <p class="MsoNormal" style="text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">$var(URIwSub)=$(var(ContactURI){re.subst,$var(regedit)});</span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;"> </span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">Third, in local_route, remove
              the incoming contact and replace with my own:</span><o:p></o:p></p>
          <p class="MsoNormal" style="text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">remove_hf("Contact");</span><o:p></o:p></p>
          <p class="MsoNormal" style="text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">append_hf("Contact:
              $var(URIwSub)\r\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;"> </span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">Fourth, send off the invite
              downstream (to 192.168.131.203):</span><o:p></o:p></p>
          <p class="MsoNormal" style="text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">b2b_init_request("FailOver",
              <a moz-do-not-send="true"
                href="mailto:sip:$tU@192.168.131.203">"sip:$tU@192.168.131.203"</a>);</span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;"> </span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">All this works! Great, but
              the reply route, not:</span><o:p></o:p></p>
          <p class="MsoNormal" style="text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">route[b2b_reply] {</span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">          xlog("b2b_reply
              Route ($ci)\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">###Debug Code</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Protocol
              of received message: $pr\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Body
              of request/reply: $rb\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Return
              Code: $rc\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Request
              Method: $rm\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Reply
              Reason: $rr\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Reply
              Status: $rs\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Transport
              protocol of original R-URI: $oP\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Transport
              protocol of R-URI: $rP\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Transport
              protocol of destination uri: $dP\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Destination
              set: $ds\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Destination
              uri: $du\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:URI
              of From header: $fu\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Domain
              in request's original R-URI: $od\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;" lang="FR-CA">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Request's
              original URI: $ou\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Username
              in request's original URI: $oU\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Domain
              in URI of 'To' header: $td\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Complete
              Request URI: $ru\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Username
              in Request URI: $rU\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Username
              in URI of 'To' header: $tU\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Surname
              in URI of 'From' header : $fU\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Contact
              name:$ct.fields(name)\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Contact
              uri:$ct.fields(uri)\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Contact
              q param:$ct.fields(q)\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Contact
              expires:$ct.fields(expires)\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Contact
              methods:$ct.fields(methods)\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:Contact
              params:$ct.fields(params)\n");</span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;"> </span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">$var(ContactURIRR)=$ct.fields(uri);</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">$var(ContactURIHostRR)=$(var(ContactURIRR){uri.host});</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">$var(regeditRR)="/"+$(var(ContactURIHostRR))+"/192.168.130.105/g";</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">$var(URIwSubRR)=$(var(ContactURIRR){re.subst,$var(regeditRR)});</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">if(remove_hf("Contact"))</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">{</span><o:p></o:p></p>
          <p class="MsoNormal"
            style="margin-left:1.0in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:removed
              Contact\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">} else {</span><o:p></o:p></p>
          <p class="MsoNormal"
            style="margin-left:1.0in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">xlog("&gt;&gt;&gt;&gt;&gt;B2BRR:DID
              NOT removed Contact\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">};</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">#</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;"># xlog("Substituted Contact
              URI Variable Reply Route:$var(URIwSubRR)\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">append_hf("Contact:
              $var(URIwSubRR)\r\n");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">#replace_body_all("Contact",
              "BlaBla");</span><o:p></o:p></p>
          <p class="MsoNormal" style="margin-left:.5in;text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">}</span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;"> </span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">So in route[b2b_reply], do
              the same treatment as in the invite. The xlog says that it
              did remove the Contact, but it’s still there, according to
              wireshark. The append_hf works fine, but the remove_hf
              never works. I end up with 2 Contact.</span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;"> </span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">Any ideas?</span><o:p></o:p></p>
          <p class="MsoNormal" style="text-indent:.5in"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;">     </span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;"> </span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Courier
              New&quot;,&quot;serif&quot;"> </span><o:p></o:p></p>
          <p class="MsoNormal"><b><span lang="FR-CA">Louis Rochon</span></b><o:p></o:p></p>
          <p class="MsoNormal"><span lang="FR-CA">Senior Systems
              Designer</span><o:p></o:p></p>
          <p class="MsoNormal"><span lang="FR-CA">Solacom Technologies</span><o:p></o:p></p>
          <p class="MsoNormal"><span lang="FR-CA">819 205 8100 ext. 274</span><o:p></o:p></p>
          <p class="MsoNormal"><i><span lang="FR-CA"><a
                  moz-do-not-send="true" href="http://www.solacom.com/"><a class="moz-txt-link-freetext" href="http://www.solacom.com">http://www.solacom.com</a></a></span></i><o:p></o:p></p>
          <p class="MsoNormal"><span lang="FR-CA"> </span><o:p></o:p></p>
          <p class="MsoNormal"><b><i><span style="font-size:7.5pt"
                  lang="FR-CA">IMPORTANT EMAIL / FAX INFORMATION</span></i></b><o:p></o:p></p>
          <p class="MsoNormal"><span style="font-size:7.5pt">The
              information in this email is confidential and may be
              legally privileged. It is intended solely for the
              addressee. Any disclosure, copying, distribution or any
              action taken or omitted to be taken in reliance on it, is
              prohibited and may be unlawful. If you are not the
              intended addressee please contact the sender, at (613)
              693-0641 and dispose of this email.  </span><span
              style="font-size:7.5pt" lang="FR-CA">Thanks !</span><o:p></o:p></p>
          <p class="MsoNormal"><span style="font-size:7.5pt"
              lang="FR-CA"> </span><o:p></o:p></p>
          <p class="MsoNormal"><b><i><span style="font-size:7.5pt"
                  lang="FR-CA">MISE EN GARDE CONCERNANT LA
                  CONFIDENTIALITE DES RENSEIGNEMENTS CONTENUS DANS CE
                  FAX/COURRIEL</span></i></b><o:p></o:p></p>
          <p class="MsoNormal"><i><span style="font-size:7.0pt"
                lang="FR-CA">La présente communication est
                confidentielle et transmise sous le sceau du secret
                professionnel et destiné au destinataire seulement.. Il
                est expressément interdit d’en dévoiler la teneur, de la
                copier, de la distribuer ou de prendre quelque mesure
                fondée sur l’information qui y est contenue. Si vous
                avez reçu cette communication par erreur, veillez S.V.P.
                la détruire et nous en aviser immédiatement par
                téléphone, au (613) 693-0641. Merci !</span></i><o:p></o:p></p>
          <p class="MsoNormal"><span style="font-family:&quot;Courier
              New&quot;,&quot;serif&quot;"> </span><o:p></o:p></p>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Times New
              Roman&quot;,&quot;serif&quot;"><br>
              <br>
              <br>
              <o:p></o:p></span></p>
          <pre>_______________________________________________<o:p></o:p></pre>
          <pre>Users mailing list<o:p></o:p></pre>
          <pre><a moz-do-not-send="true" href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a><o:p></o:p></pre>
          <pre><a moz-do-not-send="true" href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><o:p></o:p></pre>
        </blockquote>
        <p class="MsoNormal"><span
            style="font-size:12.0pt;font-family:&quot;Times New
            Roman&quot;,&quot;serif&quot;"><o:p> </o:p></span></p>
        <div>
          <p class="MsoNormal"><span
              style="font-size:12.0pt;font-family:&quot;Times New
              Roman&quot;,&quot;serif&quot;;color:windowtext"><br>
              --<br>
              Scanned by Total Defense Email Cloud Security <a
                moz-do-not-send="true"
                href="http://cloud.totaldefense.com"><a class="moz-txt-link-freetext" href="http://cloud.totaldefense.com">http://cloud.totaldefense.com</a></a>
              <o:p></o:p></span></p>
        </div>
      </div>
    </blockquote>
    <br>
  </body>
</html>