REMOTE Extensions - 1 NIC FreePBX

SIP works perfect no matter what- RTP fails because SIP EXTERNAL has to use IP of SIP Trunk instead of the WAN. How to make it work with EXTERNAL WAN IP without killing the connection to actual separate SIP Trunk?

I have a scenario which I hope someone can point me in some type of workaround. FreePBX works no problem internally or externally via VPN. However, externally, not everyone can use the VPN and need to connect direct using any VoIP phone. I’ve done numerous test and have setups that work with other similar setups. The only thing different with this setup is that FreePBX box is using one NIC. The one NIC get the external public IP of AT&T SIP. WAN (Internet) and SIP Trunk from AT&T are on two different interface on AT&T Cisco Router equipment.

ATT pfSense FreePBX

ATT Router with two interface -
ATT interface 1 goes to our pfSense WAN interface
ATT interface 2 goes to our pfSense OPT interface or the SIP Trunk
Interface 3 on pfSense is our LAN where all internal (DHCP)

External call without VPN registers but no audio (test using Conference Room) because our FreePBX system EXTERNAL for SIP uses the IP Address of the OPT or SIP Trunk. If I change the EXTERNAL IP Address of NAT to our WAN then there is audio but then we can’t make calls because now OPT or SIP is not connected or (routing?). My FreePBX is a hyper-v host has one nic and works great, but it is this one configuration that I need to see the EXTERNAL IP of WAN and OPT / SIP Trunk to be workable or routable between 2. I hope you can understand the setup above and the workaround. Thank you.

I’m confused, but the following may help:

If using chan_sip, don’t, as chan_pjsip has better support for multiple interfaces.

Treat the ITSP as being on a local network. This assumes there is no address translation on that path.

Also, you need to provide a diagram.

I am using nothing but CHAN_PJSIP - this is FreePBX 16 - Asterisk 18

5060 and 10000-20000 are Port forwarded from outside to PBX

Again, RTP is the problem because no dialtone if I change WAN to WAN address - it works using SIP Address.

I’m still confused about this:
image

There is obviously a missing cloud, and the other side of the cloud, but also is this really two independent NAT routers in one box? If not how are WAN and SIP TRUNK handled differently by it?

NAT is a hack at the best of times. Multiple NATs are even messier.

I think you are going to need two PJSIP transports, but I don’t think I have enough to be sure how to configure them.

That AT&T router is the Internet on 1 interface and SIP Trunk on the 2nd interface. It is a typical IP Flex from AT&T. PJSIP everywhere…

The EXTERNAL ADDRESS is seen by FreePBX from the WAN but I actually have to change it to the public ip of the SIP Trunk. This is where voice from outside stops working. I need a method or option where I can use the WAN address but still use the sip trunk address to get voice calls.

External call without VPN registers but no audio (test using Conference Room) because our FreePBX system EXTERNAL for SIP uses the IP Address of the OPT or SIP Trunk. If I change the EXTERNAL IP Address of NAT to our WAN then there is audio but then we can’t make calls because now OPT or SIP is not connected or (routing?). My FreePBX is a hyper-v host has one nic and works great, but it is this one configuration that I need to see the EXTERNAL IP of WAN and OPT / SIP Trunk to be workable or routable between 2. I hope you can understand the setup above and the workaround.

By the way, that ip address for external is fake for this purpose.

Clarify a bit more…RTP or voice dissapears from outside once we use the SIP Trunk public address. If we use WAN, voice works but obviously no trunk or cal in / out to world.

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.