everything works well, but after 31 seconds the call is dropped
if I use alg then it replaces contact host and the call is not dropped
how to replace Contact header host using asterisk ?
values From Domain and Media Address are filled with 192.0.3.1 and address of ISP(192.0.4.1) is in local_net
but Contact header host is not rewriting by VDS(192.0.3.1) and still PBX(192.0.2.1)
I cant change NAT settings external ip address because extensions connected via internet will be down
You didn’t explain that you had multiple disjoint private networks.
I think you need to give a much more detailed explanation of your network.
What does VDS stand for?
ISP isn’t actually going to be your ISP, but possibly part of the infrastructure; basically this network is complicate and it needs a lot of detail to properly understand it.
A local network with only one address looks wrong. I’m not sure if it will be accepted.
You don’t seem to have said what should be in the Contact header; potentially you may need multiple type=transport sections, which will mean using custom configurations.
I just noticed that there are 192.0, not 192.168 addresses, and the whois entry for the “ISP” doesn’t look like an ISP, to me. I think there has been confusing redaction here! Doing NAT between public addresses is not something that should be happening.
However, taken at face value, the transport for that endpoint needs to have signalling and media addresses 192.0.3.1, and local network is probably 192.0.2.0/24, although you haven’t said what the inside address of VDM is. I don’t though, know how well chan_pjsip handles this sort of, multi-transport, situation, and I’m pretty sure you have to go outside the FreePBX GUI to set it up. chan_sip does not handle such configurations, at all.
what difference does it make what IP addresses ? if it makes it easier for you then let it be 192.168.10.1 and 192.168.20.1 and 192.168.30.1,
it feels like you’re filling up the comment counter
if this could be done in the FreePBX web interface, then I would limit myself to the official documentation, but I asked a specific question how to modify Contact header host
if this can be done using cli or a configuration not described in the documentation or perhaps a side effect of some function, then please point me in the right direction, but if you want to answer something like don’t do that, the provider shouldn’t do that, change the provider, change the infrastructure, change the system administrator
then please refrain from commenting