Trunks configuration


(Templeusz) #1

I have an unusual configuration from the VoIP operator (neofon):
domain: neofon.tp.pl
port: 5060
User name (extensions): 48111111111
Authorization user name (ID) 48111111111@nefon.tp.pl
password: xxxxxx
proxy: neofon.to.pl
that’s all

If I use this data in the voip 3cx application, the connections are made correctly (I do not introduce a proxy server)

I wanted to log in with this data on the freepbx switchboard, unfortunately without success.
I tried to use trunk sip and pjsip:
22494 [2021-01-03 19:45:36] ERROR[14473] res_pjsip.c: Unable to create outbound OPTIONS request to endpoint Test as URI 'sip:48111111111@neofon.tp.pl@neofon.tp.pl:5060' is not valid

22495 [2021-01-03 19:45:36] ERROR[14473] res_pjsip/pjsip_options.c: Unable to create request to qualify contact sip:48111111111@neofon.tp.pl@neofon.tp.pl:5060 on AOR Test

1
2
3
4


#2

Unfortunately, the FreePBX GUI doesn’t provide a setting for Authorization user. Trying to work around that by putting it in Username and overriding other uses causes various trouble, as you have seen.

Please try these settings, where you set Authorization user manually in a config file:

Edit /etc/asterisk/pjsip.auth_custom_post.conf to contain (in addition to anything already there)
[Test](+type=auth)
username=48111111111@nefon.tp.pl

Change these settings for trunk Test:
Username: 48111111111
Contact User: (if multiple DIDs on the trunk, leave blank; otherwise don’t change)
Client URI: (leave blank)
Server URI: (leave blank)

Restart Asterisk and test. If you still have trouble, at the Asterisk command prompt type
pjsip set logger on
make or receive a failing call, paste the Asterisk log for the call at pastebin.freepbx.org and post the link here.

If registration fails, paste a registration attempt instead of a call.