I’m migrating my telephony from a commercial platform to FreePBX.
All registered trunks from various providers migrated fine.
There’s still a toll-free number that we received through a trunk without registration, and I can’t get this trunk up and running.
I’ve created a routing for it.
The provider says they’re sending me traffic, but I’m not receiving anything in return.
The provider sent me a sample setup for pure Asterisk as support, but I have FreePBX 16, and there’s no field to enter a portion of the Asterisk configuration. There are only fields for entering specific values, but not all the necessary ones.
I need help: how do I implement the following configuration on FreePBX 16?
Or can I enter it directly into the Asterisk configuration?
Won’t FreePBX overwrite the Asterisk configuration I’ve written?
This doesn’t look like pure Asterisk; it looks like an attempt to give a FreePBX configuration for the, obsolete, chan_sip driver.
It also contains obvious mistakes, which make me think it cannot be trusted, specifically:
Only one host address is possible in chan_sip. (chan_pjsip allows multiple source addresses, but, I think is still restricted to one destination.)
This is ignored without a secret. insecure=port is rarely needed, unless using TCP, or TLS, and tends to indicate the starting point for the configuration was copy and paste, without considering the meaning.
type=friend was over-used, and needs a specific section name, to give the user name. That section name needs to appear in the From header, from the provider, which is rather unlikely, otherwise this just degenerates to type=peer, with an added security vulnerability.
I’m fairly sure that this was never a valid alternative. The deprecated form of this is canreinvite, and the official current one is directmedia. Turning this on for a provider is unusual, and most FreePBX configurations do things that make it ineffective, as FreePBX tends to need access to the media stream. It isn’t going to necessary to fix your problem.
I think this will only have an effect if you used domain names, rather than IP addresses, and I believe chan_sip support for this is limited.
Generally, if you are using the two sections chan_sip method, you need to duplicate more settings than are shown here, between the two. chan_sip doesn’t always need the in and out hack, but chan_pjsip can handles cases where the former needs it, but without two sections.
I would remove g729, unless you have a specific need for it.
You’ve already said that there is no registration. That configuration indicates there is no authentication. I’d try the chan_psjip configuration, with server set to “xxx.xxx.xxx.xxx”, and match/permit set to “xxx.xxx.xxx.xxx,xxx.xxx.xxx.yyy”. Set both registration and authentication to none.
If it doesn’t work, provide us with the full log, and use the cli command “pjsip set logger on”, to allow capture of the SIP exchange.
If you think “reinvite” will be needed, enable direct media, however, if it is really needed, you are going to have to disable lots of features.