<div dir="ltr"><div>If you need any additional data please let me know.</div><div><br></div><div>Cheers,</div><div><br></div><div>Diego</div></div><div class="gmail_extra"><br><div class="gmail_quote">2017-01-12 15:04 GMT-03:00 Diego Nadares <span dir="ltr"><<a href="mailto:dnadares@gmail.com" target="_blank">dnadares@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi Daniel!<div><br></div><div>Thanks for your answer.  The idea is to show only a few headers. In BYE works great. I'm removing and adding the following hdrs:</div><div><div><b><br></b></div><div><b>User-Agent: Kamailio. <---I will try what you said</b></div><div><b>Supported:.</b></div><div><b>Allow: INVITE, OPTIONS, BYE, CANCEL, ACK, NOTIFY, INFO.</b></div><div><b>Accept: application/sdp, application/gtd.</b></div></div><div><br></div><div>For example in following messages ( Kamailio is 172.16.213.38)</div><div><br></div><div><div>#</div><div>U 2017/01/12 14:51:10.593782 <a href="http://172.16.200.159:57270" target="_blank">172.16.200.159:57270</a> -> <a href="http://172.16.213.38:5060" target="_blank">172.16.213.38:5060</a></div></div><div><div>BYE sip:127.0.0.8:5060;line=sr-<wbr>9879879879798** SIP/2.0.</div><div>Via: SIP/2.0/UDP  172.16.200.159:5060;branch=<wbr>z9hG4bK12B9605ED.</div><div>From: xx <<a href="mailto:sip%3Axx@172.16.213.38" target="_blank">sip:xx@172.16.213.38</a>>;tag=<wbr>95E7E4A4-23F2.</div><div>To: xxx <<a href="mailto:sip%3Axxx@172.16.213.38" target="_blank">sip:xxx@172.16.213.38</a>>;tag=<wbr>SDmmb7201-as0518eb07.</div><div>Date: Thu, 12 Jan 2017 17:51:05 GMT.</div><div>Call-ID: SDmmb7201-<wbr>f5ded6cf4cd5d84736b088e39277e8<wbr>db-c540dl1.</div><div>User-Agent: Cisco-SIPGateway/IOS-12.x.</div><div>Max-Forwards: 15.</div><div>Route: <sip:172.16.213.38;lr;ftag=<wbr>SDmmb7201-as0518eb07;did=bf.<wbr>cab>.</div><div>Timestamp: 1484243470.</div><div>CSeq: 101 BYE.</div><div>Reason: Q.850;cause=16.</div><div>Content-Disposition: signal;handling=optional.</div><div>Content-Type: application/gtd.</div><div>Content-Length: 26.</div><div>.</div><div>.....</div><div>.</div><div><br></div><div>#</div><div>U 2017/01/12 14:51:10.647164 <a href="http://172.16.213.38:5060" target="_blank">172.16.213.38:5060</a> -> <a href="http://172.16.50.41:5060" target="_blank">172.16.50.41:5060</a></div><div>BYE <a href="http://sip:xxx@172.16.50.41:5060">sip:xxx@172.16.50.41:5060</a>;<wbr>transport=udp SIP/2.0.</div><div>Via: SIP/2.0/UDP 172.16.213.38;branch=<wbr>z9hG4bKdcf6.<wbr>f898feef02d601e36a22d26bf3ae5e<wbr>4a.0.</div><div>Via: SIP/2.0/UDP 127.0.0.8;branch=z9hG4bKsr-<wbr>asdfasdfF.</div><div>From: xx <<a href="mailto:sip%3Axx@172.16.213.38" target="_blank">sip:xx@172.16.213.38</a>>;tag=<wbr>95E7E4A4-23F2.</div><div>To: xxx <<a href="mailto:sip%3Axxx@172.16.50.41" target="_blank">sip:xxx@172.16.50.41</a>>;tag=<wbr>SDmmb7201-as0518eb07.</div><div>Call-ID: SDmmb7201-<wbr>f5ded6cf4cd5d84736b088e39277e8<wbr>db-c540dl1.</div><div>Max-Forwards: 14.</div><div>CSeq: 101 BYE.</div><div>Content-Type: application/gtd.</div></div><div><div>Content-Length: 26.</div><div><b>User-Agent: Kamailio.</b></div><div><b>Supported:.</b></div><div><b>Allow: INVITE, OPTIONS, BYE, CANCEL, ACK, NOTIFY, INFO.</b></div><div><b>Accept: application/sdp, application/gtd.</b></div><div>.</div><div>......</div></div><div><br></div><div>But in ok I can't</div><div><br></div><div><div>#</div><div>U 2017/01/12 14:51:10.653701 <a href="http://172.16.50.41:5060" target="_blank">172.16.50.41:5060</a> -> <a href="http://172.16.213.38:5060" target="_blank">172.16.213.38:5060</a></div><div>SIP/2.0 200 OK.</div><div>Via: SIP/2.0/UDP 172.16.213.38;branch=<wbr>z9hG4bKdcf6.<wbr>f898feef02d601e36a22d26bf3ae5e<wbr>4a.0.</div><div>Via: SIP/2.0/UDP 127.0.0.8;branch=z9hG4bKsr-<wbr>sadfasdf.</div><div>From: xx <<a href="mailto:sip%3Axx@172.16.213.38" target="_blank">sip:xx@172.16.213.38</a>>;tag=<wbr>95E7E4A4-23F2.</div><div>To: xxx <<a href="mailto:sip%3Axxx@172.16.50.41" target="_blank">sip:xxx@172.16.50.41</a>>;tag=<wbr>SDmmb7201-as0518eb07.</div><div>Call-ID: SDmmb7201-<wbr>f5ded6cf4cd5d84736b088e39277e8<wbr>db-c540dl1.</div><div>CSeq: 101 BYE.</div><div>Server: Asterisk PBX 11.17.0.</div><div>Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE.</div><div>Supported: replaces, timer.</div><div>Content-Length: 0.</div><div>.</div><div>FY, INFO.</div><div>Accept</div><div>#</div><div>U 2017/01/12 14:51:10.669460 <a href="http://172.16.213.38:5060" target="_blank">172.16.213.38:5060</a> -> <a href="http://172.16.200.159:5060" target="_blank">172.16.200.159:5060</a></div><div>SIP/2.0 200 OK.</div><div>Via: SIP/2.0/UDP  172.16.200.159:5060;branch=<wbr>z9hG4bK12B9605ED.</div><div>From: xx <<a href="mailto:sip%3Axx@172.16.213.38" target="_blank">sip:xx@172.16.213.38</a>>;tag=<wbr>95E7E4A4-23F2.</div><div>To: xxx <<a href="mailto:sip%3Axxx@172.16.213.38" target="_blank">sip:xxx@172.16.213.38</a>>;tag=<wbr>SDmmb7201-as0518eb07.</div><div>Call-ID: SDmmb7201-<wbr>f5ded6cf4cd5d84736b088e39277e8<wbr>db-c540dl1.</div><div>CSeq: 101 BYE.</div><div><b>Server: Asterisk PBX 11.17.0.</b></div><div><b>Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE.</b></div><div><b>Supported: replaces, timer.</b></div><div>Content-Length: 0.</div><div>.</div></div><div><br></div><div><br></div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">2017-01-12 13:23 GMT-03:00 Daniel-Constantin Mierla <span dir="ltr"><<a href="mailto:miconda@gmail.com" target="_blank">miconda@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
  
    
  
  <div bgcolor="#FFFFFF" text="#000000">
    <p>Hello,</p>
    <p>if you are looking to remove the server header (server
      signature), that can be controlled via global parameters:</p>
    <p>  -
      <a class="m_-409734095957794762m_-1776178681903754250moz-txt-link-freetext" href="https://www.kamailio.org/wiki/cookbooks/4.4.x/core#server_header" target="_blank">https://www.kamailio.org/wiki/<wbr>cookbooks/4.4.x/core#server_he<wbr>ader</a></p>
    <p>Note that there is another header, User-Agent, that may be added
      by Kamailio in local generate request. There is a global parameter
      to control it as well.<br>
    </p>
    If you want more than that, can you add a bit more details, because
    CANCEL and BYE are processed differently. With which one you get
    issues?<br>
    <br>
    Cheers,<br>
    Daniel<div><div class="m_-409734095957794762h5"><br>
    <br>
    <div class="m_-409734095957794762m_-1776178681903754250moz-cite-prefix">On 12/01/2017 17:00, Diego Nadares
      wrote:<br>
    </div>
    </div></div><blockquote type="cite"><div><div class="m_-409734095957794762h5">
      <div dir="ltr">Hi List,
        <div><br>
        </div>
        <div>I'm trying to add and remove some headers in 200 canceling
          and 200 ok to BYEs with no success.</div>
        <div><br>
        </div>
        <div>I don't know in which route to add my remove_hf and
          append_hf. It seems that I can't catch it on reply either on
          request route.</div>
        <div><br>
        </div>
        <div>I tried adding it in </div>
        <div><br>
        </div>
        <div>
          <div>event_route[tm:local-response] {</div>
          <div>        xlog("L_ERR", "TM LOCAL REPONSE!");</div>
          <div>        route(MANAGE_HEADERS);</div>
          <div>}</div>
        </div>
        <div><br>
        </div>
        <div>This is my route to manage hdrs:</div>
        <div><br>
        </div>
        <div>
          <div>route[MANAGE_HEADERS]{</div>
          <div><br>
          </div>
          <div>        xlog("L_ERR", "MANAGE HDRS !");</div>
          <div><br>
          </div>
          <div>        keep_hf("TH"); # for topoh</div>
        </div>
        <div><br>
        </div>
        <div>        append("AHDR1:asdf\r\n");</div>
        <div><br>
        </div>
        <div>        return;</div>
        <div>}</div>
        <div><br>
        </div>
        <div>I suppose SERVER HDR should be removed but:</div>
        <div><br>
        </div>
        <div>
          <div>U 2017/01/12 12:45:41.566733 <a href="http://172.16.213.38:5060" target="_blank">172.16.213.38:5060</a>
            -> <a href="http://172.16.50.41:5060" target="_blank">172.16.50.41:5060</a></div>
          <div>SIP/2.0 200 canceling.</div>
          <div>Via: SIP/2.0/UDP 172.16.50.41:5060;branch=z9hG4<wbr>bKgg8ekd3080braugkm700.1.</div>
          <div>CSeq: 102 CANCEL.</div>
          <div>From: <<a href="mailto:sip%3Axx@172.16.50.41" target="_blank">sip:xx@172.16.50.41</a>>;tag=SD7b<wbr>10b01-as5ba5e269.</div>
          <div>To: <<a href="mailto:sip%3Axxx@172.16.213.38" target="_blank">sip:xxx@172.16.213.38</a>>;tag=4a<wbr>86e96addfb27a943bc86e1872032b6<wbr>-0a8b.</div>
          <div>Call-ID: SD7b10b01-6a7d1089793bda79481f<wbr>25cf88c023ed-c540dl1.</div>
          <div>Server: kamailio (4.4.4 (x86_64/linux)).</div>
          <div>Content-Length: 0.</div>
        </div>
        <div><br>
        </div>
        <div><br>
        </div>
        <div>Any help will be very appreciated.<br>
        </div>
        <div><br>
        </div>
        <div>Thanks in advance!</div>
        <div><br>
        </div>
        <div>Diego</div>
      </div>
      <br>
      <fieldset class="m_-409734095957794762m_-1776178681903754250mimeAttachmentHeader"></fieldset>
      <br>
      </div></div><pre>______________________________<wbr>_________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
<a class="m_-409734095957794762m_-1776178681903754250moz-txt-link-abbreviated" href="mailto:sr-users@lists.sip-router.org" target="_blank">sr-users@lists.sip-router.org</a>
<a class="m_-409734095957794762m_-1776178681903754250moz-txt-link-freetext" href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users" target="_blank">http://lists.sip-router.org/cg<wbr>i-bin/mailman/listinfo/sr-user<wbr>s</a><span class="m_-409734095957794762HOEnZb"><font color="#888888">
</font></span></pre><span class="m_-409734095957794762HOEnZb"><font color="#888888">
    </font></span></blockquote><span class="m_-409734095957794762HOEnZb"><font color="#888888">
    <br>
    <pre class="m_-409734095957794762m_-1776178681903754250moz-signature" cols="72">-- 
Daniel-Constantin Mierla
<a class="m_-409734095957794762m_-1776178681903754250moz-txt-link-abbreviated" href="http://www.twitter.com/miconda" target="_blank">www.twitter.com/miconda</a> -- <a class="m_-409734095957794762m_-1776178681903754250moz-txt-link-abbreviated" href="http://www.linkedin.com/in/miconda" target="_blank">www.linkedin.com/in/miconda</a>
Kamailio World Conference - May 8-10, 2017 - <a class="m_-409734095957794762m_-1776178681903754250moz-txt-link-abbreviated" href="http://www.kamailioworld.com" target="_blank">www.kamailioworld.com</a></pre>
  </font></span></div>

<br>______________________________<wbr>_________________<br>
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list<br>
<a href="mailto:sr-users@lists.sip-router.org" target="_blank">sr-users@lists.sip-router.org</a><br>
<a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users" rel="noreferrer" target="_blank">http://lists.sip-router.org/cg<wbr>i-bin/mailman/listinfo/sr-user<wbr>s</a><br>
<br></blockquote></div><br></div>
</div></div></blockquote></div><br></div>