Hello,

you can skip setting advertise for listen and try to play with set_advertised_address() and record_route_preset() along with domain alias for public address.

Cheers,
Daniel

On 22.05.23 19:11, Calvin E. wrote:
Using 5.6.x, a scenario designed for a public IP now needs to support life in the cloud behind NAT. I'd like to avoid having two listeners to separate on-net from off-net traffic. In a HA  scenario, it would be nice to have only one floating IP.

Is it possible to use the same local address and port for external/public and internal/private traffic?
Should set_advertised_address() override the listen advertise address?

Initial testing did not produce the expected result. I want to make sure I'm following a sane pattern before going down a rabbit hole. The idea is to toggle the advertised address by checking if the sender or recipient is rfc1918().

For the dispatcher module, is it possible to use socket names like below? In testing it appeared that only one of the two names was valid.

listen=udp:10.0.0.10:5060 name "onnet"
listen=udp:10.0.0.10:5060 advertise 11.11.11.11:5060 name "offnet"



__________________________________________________________
Kamailio - Users Mailing List - Non Commercial Discussions
To unsubscribe send an email to sr-users-leave@lists.kamailio.org
Important: keep the mailing list in the recipients, do not reply only to the sender!
Edit mailing list options or unsubscribe:
-- 
Daniel-Constantin Mierla -- www.asipto.com
www.twitter.com/miconda -- www.linkedin.com/in/miconda
Kamailio World Conference - June 5-7, 2023 - www.kamailioworld.com