Hi, I do not think that record_route() uses the advertised_address variables. We have been using the advertised_address / advertised_port variables in the config file and although they are used in the Via headers, they are not substituted into the Record Route lines.
record_route_advertised_address() was added about 2 weeks ago for exactly this reason - using an advertised address in record routes when the transport changes. It automatically inserts double (rr2=on) routes in these cases and extra custom parameters can be added later.
However, we only needed the C API, so it isn't exported as a config file function yet. This won't be difficult.
Regards, Hugh
On 03/12/11 15:57, Ovidiu Sas wrote:
Take a look at set_advertised_address: http://www.kamailio.org/dokuwiki/doku.php/core-cookbook:3.1.x#set_advertised... Set it and then record_route() will properly fill the Record-Route header.
Regards, Ovidiu Sas