Итак, у меня довольно сложная проблема. Я пытаюсь подключить свой Asterisk к клиентской телефонной системе 3cx.
Итак, есть sip-телефон, подключенный к системе 3cx с расширением 351
На моем Asterisk я добавил клиентскую систему 3cx в sip.conf следующим образом:
[3cx]
type=friend
host=151.236.XX.XXX
username=400
secret=secret
context=main
canreinvite=no
;authname=authname
;fromuser=fromuser
;fromdomain=fromdomain
insecure=port,invite
trustrpid=yes
disallow=all
allow=alaW
В моем extension.conf у меня есть следующая строка
exten => _X.,n,Dial(SIP/${EXTEN}@3cx,,ro)
Однако, когда он пытается набрать 'SIP / 351 @ 3cx' using landline that routes to my asterisk I am getting the following output
[Oct 4 20:05:22] VERBOSE[22119] chan_sip.c:
<--- SIP read from UDP:151.236.XX.XXX:5060 --->
SIP/2.0 404 User unknown.
Via: SIP/2.0/UDP 85.13.XXX.XXX:5060;branch=z9hG4bK17f3106e
To: <sip:351@151.236.XX.XXX>;tag=9e38f119
From: "+442084526XXX"<sip:+442084526XXX@85.13.XXX.XXX>;tag=as33bb12fb
Call-ID: 5cc7443b00658b746ff822895e557d3c@85.13.XXX.XXX:5060
CSeq: 103 INVITE
User-Agent: 3CXPhoneSystem 14.0.49169.513 (48654)
Content-Length: 0
However I have downloaded a soft phone (MicroSIP) to my desktop and registered ths soft phone directly with client 3cx system. When i dial 351 I am connected straight to the agent.
I was looking online for solutions and i have found that adding register
to sip.conf (so essentially i register my asterisk as sip phone to 3cx system) should help but it did not work.
my sip.conf
register entry:
register => 400:secret@151.236.XX.XXX
I am slightly lost here so any help greatly appreciated
Thanks
Убедитесь, что fromdomain=<ваш 3x домен>
и qualify=да
добавлены к вашему глотку. conf
, и это type=peer
для вашей задачи. Final sip.conf
register=>400:secret@151.236.XX.XXX/from-3cx
[3cx]
type=peer
dtmfmode=rfc2833
insecure=port,invite
qualify=yes
canreinvite=no
directmedia=yes
disallow=all
allow=ulaw
allow=g729
defaultuser=400
secret=secret
context=from-3cx
[phone-connected-to-asterisk]
type=friend
host=dynamic
transport=udp
secret=secret
disallow=all
allow=ulaw
context=from-asterisk
insecure=port,invite
И убедитесь, что к вашему extensions.conf
добавлен входящий контекст. Финал extensions.conf
:
[general]
static=yes
writeprotect=yes
clearglobalvars=yes
[default]
include => incoming
[incoming]
include => from-3cx
[from-asterisk]
exten => _X.,1,Dial(SIP/${EXTEN}@3cx,45)
[from-3cx]
exten => _X.,1,Progress()
exten => _X.,n,Dial(SIP/${EXTEN},60,gt)
exten => _X.,n,Hangup()