Hi Gang
How is record_route() determining if it needs to add two RR Header?
Kamailio 5.8.4
I'm attempting to perform route header hiding by by rebuilding some of the topos functionality with perl.
So towards the CPE I'm removing all existing RR header and want to replace them with one header containing an attribute which the CPE is then sending back and allows me to restore the Route header.
But I came across an issue which an empty RR header being created with this (simplified) script:
modparam("rr", "enable_double_rr", 1)
perl_exec("hide_route"); # Stores Route-Set and sets $avp(rrattr) as id remove_hf("Record-Route"); msg_apply_changes(); loose_route(); # Required for record_route()? add_rr_param(";rr=$avp(rrattr)"); # Add Param to identify saved route set record_route();
I end up with:
Record-Route: sip:;r2=on;lr;rr=id007 Record-Route: sip:157.161.x.x;r2=on;lr;rr=id007
The first header missing the IP address, the message being dropped by the CPE
There is no transport change. If I set enable_double_rr to 0 only the 2nd RR header is created and this works as expected but I am not sure if some situations would need double RR.
What causes the double RR to be created in my case?
Mit freundlichen Grüssen
-Benoît Panizzon-