[SR-Users] How to determine correct port to set in record-route header

Daniel Tryba d.tryba at pocos.nl
Tue Jan 24 16:58:41 CET 2017


On Tue, Jan 24, 2017 at 03:50:24PM +0000, Pranathi Venkatayogi wrote:
>   I am using Kamailio behind NAT, unable to figure how to make it put “public ip” in Record-route header, I am manually inserting the hard-coded header myself as below.
>   However now I am having trouble choosing the right port number in all scenarios.


Take a look at https://www.kamailio.org/wiki/cookbooks/4.4.x/core#listen
and the mentioned set_advertised_address() / set_advertised_port() cfg
functions.

To quote the documentation:
 A typical use case for advertise address is when running SIP server
 behind a NAT/Firewall, when the local IP address (to be used for bind)
 is different than the public IP address (to be used for advertising). 




More information about the sr-users mailing list