IP (tos 0x10, ttl 64, id 53886, offset 0, flags [none], proto UDP (17), length 1509)10.99.8.107.5060 > 10.99.8.107.1024: [bad udp cksum 0x2b7e -> 0xf867!] UDP, length 1481E....~..@.|.c.kc.k......+~INVITE sip:301@10.99.8.107:1024 SIP/2.0Record-Route: <sip:18.156.22.8;lr=on;ftag=51c5ba2b8447498798a4e630dca6c17a>Via: SIP/2.0/UDP 10.99.8.107:5060;branch=z9hG4bKa09f.30a09da6e92bdfa999ccb517ecba6f97.0Via: SIP/2.0/UDP 10.9.18.77:50342;received=37.202.8.10;rport=50342;branch=z9hG4bKPj888cd8a8501547fc851e5724ef3f7b1aMax-Forwards: 69From: <sip:74807310@18.156.22.8>;tag=51c5ba2b8447498798a4e630dca6c17aTo: <sip:301@18.156.22.8>Contact: <sip:74807310@10.9.18.77:50342;alias=37.202.8.10~50342~1;alias=37.202.8.10~50342~1;ob>Call-ID: f92450e6fad14d59bfea70100358bd05CSeq: 232 INVITEAllow: PRACK, INVITE, ACK, BYE, CANCEL, UPDATE, INFO, SUBSCRIBE, NOTIFY, REFER, MESSAGE, OPTIONSSupported: replaces, 100rel, timer, norefersubSession-Expires: 1800Min-SE: 90User-Agent: MicroSIP/3.19.28Authorization: Digest username="74807310", realm="hpbx200-1.euc1.telecomsvc.com", nonce="Xt3p017d6KfFSpRngRjuDCInFYIAVnPB", uri="sip:301@18.156.22.8", response="5e8f6a54064aba0d703c62dcbc746807"Content-Type: application/sdpContent-Length: 386P-Debug-header: advertized local
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
From: sr-dev <sr-dev-bounces@lists.kamailio.org> On Behalf Of Andrey Deykunov
Sent: Friday, June 5, 2020 2:33 PM
To: Kamailio (SER) - Development Mailing List <sr-dev@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