Asterisk PJSIP Print

  • 103


pjsip.conf

[transport-udp]
type = transport
protocol = udp
bind = 0.0.0.0

[icttechnet]
type = registration
transport = transport-udp
outbound_auth = icttechnet
client_uri = sip:100000@atlanta.icttech.net:5060     ; (one of our multiple servers, you can choose the one closer to your location)
server_uri = sip:atlanta.icttech.net:5060            ; (one of our multiple servers, you can choose the one closer to your location)

[icttechnet]
type = auth
auth_type = userpass
username = 100000            ; (Replace with your 6 digit Main SIP Account User ID or Sub Account username, i.e. 123456 or 123456_sub)
password = johnspassword     ; your password

[icttechnet]
type = aor
contact = sip:100000@atlanta.icttech.net             ; (one of our multiple servers, you can choose the one closer to your location)

[icttechnet]
type = endpoint
transport = transport-udp
context = mycontext
disallow = all
allow = ulaw
; allow=g729                 ; uncomment if you support g729
from_user = 100000           ; (Replace with your 6 digit Main SIP Account User ID or Sub Account username, i.e. 123456 or 123456_sub)
auth = icttechnet
outbound_auth = icttechnet
aors = icttechnet
; NAT parameters:
rtp_symmetric = yes
rewrite_contact = yes
send_rpid = yes

[icttechnet]
type = identify
endpoint = icttechnet
match = atlanta.icttech.net      ; (one of our multiple servers, you can choose the one closer to your location)

extensions.conf

[mycontext]
; Make sure to include inbound prior to outbound because the _NXXNXXXXXX handler will match the incoming call and create a loop
include => icttechnet-inbound
include => icttechnet-outbound

[icttechnet-outbound]
exten => _1NXXNXXXXXX,1,Dial(PJSIP/${EXTEN}@icttechnet)
exten => _1NXXNXXXXXX,n,Hangup()
exten => _NXXNXXXXXX,1,Dial(PJSIP/1${EXTEN}@icttechnet)
exten => _NXXNXXXXXX,n,Hangup()
exten => _011.,1,Dial(PJSIP/${EXTEN}@icttechnet)
exten => _011.,n,Hangup()
exten => _00.,1,Dial(PJSIP/${EXTEN}@icttechnet)
exten => _00.,n,Hangup()

; inbound context example for your DID numbers, do not add the number 1 in front

[icttechnet-inbound]
exten => 7863643011,1,Answer() ;your DID

 

Asterisk IP Auth. (PJSIP)

pjsip.conf

Note: You'll need to create a sub account to use IP Auth

[transport-udp]
type = transport
protocol = udp
bind = 0.0.0.0

[icttechnet]
type = aor
contact = sip:100000@atlanta.icttech.net             ; (one of our multiple servers, you can choose the one closer to your location)

[icttechnet]
type = endpoint
transport = transport-udp
context = mycontext
disallow = all
allow = ulaw
; allow=g729                 ; uncomment if you support g729
from_user = 100000           ; (Replace with your 6 digit Main SIP Account User ID or Sub Account username, i.e. 123456 or 123456_sub)
aors = icttechnet
; NAT parameters:
rtp_symmetric = yes
rewrite_contact = yes
send_rpid = yes

[icttechnet]
type = identify
endpoint = icttechnet
match = atlanta.icttech.net      ; (one of our multiple servers, you can choose the one closer to your location)

extensions.conf

[mycontext]
; Make sure to include inbound prior to outbound because the _NXXNXXXXXX handler will match the incoming call and create a loop
include => icttechnet-inbound
include => icttechnet-outbound

[icttechnet-outbound]
exten => _1NXXNXXXXXX,1,Dial(PJSIP/${EXTEN}@icttechnet)
exten => _1NXXNXXXXXX,n,Hangup()
exten => _NXXNXXXXXX,1,Dial(PJSIP/1${EXTEN}@icttechnet)
exten => _NXXNXXXXXX,n,Hangup()
exten => _011.,1,Dial(PJSIP/${EXTEN}@icttechnet)
exten => _011.,n,Hangup()
exten => _00.,1,Dial(PJSIP/${EXTEN}@icttechnet)
exten => _00.,n,Hangup()

; inbound context example for your DID numbers, do not add the number 1 in front

[icttechnet-inbound]
exten => 7863643011,1,Answer() ;your DID


Was this answer helpful?

« Back