<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
i tried also with <span style="color:rgb(32, 31, 30);font-family:"Segoe UI", "Segoe UI Web (West European)", "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", sans-serif;font-size:14.6667px;background-color:rgb(255, 255, 255);display:inline !important">remove_hf_value<span>
but still the same problem.</span></span></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span style="color:rgb(32, 31, 30);font-family:"Segoe UI", "Segoe UI Web (West European)", "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", sans-serif;font-size:14.6667px;background-color:rgb(255, 255, 255);display:inline !important"><span><br>
</span></span></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span style="color:rgb(32, 31, 30);font-family:"Segoe UI", "Segoe UI Web (West European)", "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", sans-serif;font-size:14.6667px;background-color:rgb(255, 255, 255);display:inline !important"><span>sometimes
i have a line only with </span></span></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span style="color:rgb(32, 31, 30);font-family:"Segoe UI", "Segoe UI Web (West European)", "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", sans-serif;font-size:14.6667px;background-color:rgb(255, 255, 255);display:inline !important"><span><span style="color:rgb(0, 0, 0);font-family:Calibri, Arial, Helvetica, sans-serif;font-size:16px;background-color:rgb(255, 255, 255);display:inline !important">"<b>;received=x.x.x.x;rport=xxxx</b>"</span><br>
</span></span></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span style="color:rgb(32, 31, 30);font-family:"Segoe UI", "Segoe UI Web (West European)", "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", sans-serif;font-size:14.6667px;background-color:rgb(255, 255, 255);display:inline !important"><span><span style="color:rgb(0, 0, 0);font-family:Calibri, Arial, Helvetica, sans-serif;font-size:16px;background-color:rgb(255, 255, 255);display:inline !important"><br>
</span></span></span></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span style="color:rgb(32, 31, 30);font-family:"Segoe UI", "Segoe UI Web (West European)", "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", sans-serif;font-size:14.6667px;background-color:rgb(255, 255, 255);display:inline !important"><span><span style="color:rgb(0, 0, 0);font-family:Calibri, Arial, Helvetica, sans-serif;font-size:16px;background-color:rgb(255, 255, 255);display:inline !important">and
sometimes even worse the next header does not start on a new line like this</span></span></span></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span style="color:rgb(32, 31, 30);font-family:"Segoe UI", "Segoe UI Web (West European)", "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", sans-serif;font-size:14.6667px;background-color:rgb(255, 255, 255);display:inline !important"><span><span style="color:rgb(0, 0, 0);font-family:Calibri, Arial, Helvetica, sans-serif;font-size:16px;background-color:rgb(255, 255, 255);display:inline !important"><span style="background-color:rgb(255, 255, 255);display:inline !important">"<b>;received=x.x.x.x;rport=xxxx</b></span><span style="background-color: rgb(255, 255, 255); display: inline !important; color: rgb(237, 92, 87);"><b>Max-Forward:
70</b></span><span style="background-color:rgb(255, 255, 255);display:inline !important">"</span><br>
</span></span></span></div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>De :</b> sr-users <sr-users-bounces@lists.kamailio.org> de la part de James Browne <james@frideo.com><br>
<b>Envoyé :</b> mercredi 16 mars 2022 12:30<br>
<b>À :</b> Kamailio (SER) - Users Mailing List <sr-users@lists.kamailio.org><br>
<b>Objet :</b> Re: [SR-Users] properly removing First Via header received</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt;">
<div class="PlainText">I don't know about the lump, but maybe try remove_hf_value instead.<br>
This should also work if/when multiple Via values are comma-separated<br>
in a single header field.<br>
<a href="https://www.kamailio.org/docs/modules/devel/modules/textopsx.html#textopsx.f.remove_hf_value">https://www.kamailio.org/docs/modules/devel/modules/textopsx.html#textopsx.f.remove_hf_value</a><br>
<br>
James<br>
<br>
On Wed, 16 Mar 2022 at 08:19, Patrick Karton <patrickarton@hotmail.com> wrote:<br>
><br>
> i want to remove the First Via Header received from uac to kamailio.<br>
><br>
> so in my script i use remove_hf("Via") but in the relayed request i see that ";received=x.x.x.x;rport=xxxx" is left without any header before it.<br>
><br>
> i think internally kamailio adds a lump before i call the remove_hf function.<br>
><br>
> how to do it properly ?<br>
><br>
> Thanks<br>
> __________________________________________________________<br>
> Kamailio - Users Mailing List - Non Commercial Discussions<br>
> * sr-users@lists.kamailio.org<br>
> Important: keep the mailing list in the recipients, do not reply only to the sender!<br>
> Edit mailing list options or unsubscribe:<br>
> * <a href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users">https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users</a><br>
<br>
__________________________________________________________<br>
Kamailio - Users Mailing List - Non Commercial Discussions<br>
* sr-users@lists.kamailio.org<br>
Important: keep the mailing list in the recipients, do not reply only to the sender!<br>
Edit mailing list options or unsubscribe:<br>
* <a href="https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users">https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users</a><br>
</div>
</span></font></div>
</body>
</html>