[sr-dev] Removing Record-Route header

Henning Westerholt hw at skalatan.de
Sun Jun 7 11:35:46 CEST 2020


Hello,

not know the details of your cfg, but did you tried already to deactivate this parameter:

https://kamailio.org/docs/modules/devel/modules/rr.html#rr.p.enable_double_rr

Another option could be not not use record_route() but this function instead:

https://kamailio.org/docs/modules/devel/modules/rr.html#rr.f.record_route_adv_addr

Cheers,

Henning

--
Henning Westerholt – https://skalatan.de/blog/
Kamailio services – https://gilawa.com<https://gilawa.com/>

From: sr-dev <sr-dev-bounces at lists.kamailio.org> On Behalf Of Andrey Deykunov
Sent: Friday, June 5, 2020 2:33 PM
To: Kamailio (SER) - Development Mailing List <sr-dev at lists.kamailio.org>
Subject: [sr-dev] Removing Record-Route header

Hi guys,

I'm using Kamailio 5.3.1 in the AWS cloud. For this purpose I'm setting up a 'nat_public_ipaddr' in the 'advertise' feature:


listen=tls:<%= @ipaddr %>:5061 advertise <%= node['hpbx']['nat_public_ipaddr'] %>:5061
listen=tcp:<%= @ipaddr %>:5060 advertise <%= node['hpbx']['nat_public_ipaddr'] %>:5060
listen=udp:<%= @ipaddr %>:5060 advertise <%= node['hpbx']['nat_public_ipaddr'] %>:5060



When I need relaying an incoming message to one of our internal services (for example B2BUA, VMAIL etc) I'm setting up an internal address '@ipaddr'  in the Via header instead of 'nat_public_ipaddr' :


set_advertised_address("<%= @ipaddr %>");
set_advertised_port(5060);



All works fine, but Kamailio adds a 'Record-Route' header containing  'nat_public_ipaddr' automatically into such messages. How can I remove this header or insert my internal address instead before relaying the message? Is it possible?

Thanks,
Andrey



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-dev/attachments/20200607/63ba4bbb/attachment-0001.html>


More information about the sr-dev mailing list