hello asterisk team,
i’m implementing TLS support in call system. for that i use this server . first i make this server on ec2 instance for public handle.and i successfully done with UDP. Now i want TLS feature. for that i do following changes in pjsip.conf file. also i’m able to register the account in server but when i dial the call it is not connect.
below i put the my pjsip.conf file and extension.conf file.
please chack once and tell me that is there any changes required.
1)pjsip.conf
; =========================
; GLOBAL SETTINGS
; =========================
[global]
type=global
user_agent=Asterisk
;endpoint_identifier_order=username,ip,anonymous
; =========================
; TRANSPORT (UDP)
; =========================
;[transport-udp]
;type=transport
;protocol=udp
;bind=0.0.0.0
;external_media_address=51.21.198.44
;external_signaling_address=51.21.198.44
; =========================
; TRANSPORT (TLS)
; =========================
[transport-tls]
type=transport
protocol=tls
bind=0.0.0.0:5061
external_media_address=51.21.198.44
external_signaling_address=51.21.198.44
local_net=172.31.0.0/16
cert_file=/etc/asterisk/keys/asterisk.pem
priv_key_file=/etc/asterisk/keys/asterisk.key
ca_list_file=/etc/asterisk/keys/ca.crt
method=tlsv1_2
verify_client=no
verify_server=no
allow_reload=yes
require_client_cert=no
;cipher=ADH-AES256-SHA,ADH-AES128-SHA
; =========================
; ENDPOINT 7001
; =========================
[7001]
type=endpoint
context=default
disallow=all
allow=ulaw,alaw
auth=7001-auth
aors=7001
transport=transport-tls
;nat=force_rport,comedia
direct_media=no
rtp_symmetric=yes
rewrite_contact=yes
force_rport=yes
media_encryption=sdes
media_encryption_optimistic=yes
[7001-auth]
type=auth
auth_type=userpass
username=7001
password=7001
[7001]
type=aor
max_contacts=1
remove_existing=yes
qualify_frequency=30
2)extensions.conf
[default]
; dial 7001
exten => 7001,1,NoOp(Call to 7001)
same => n,Dial(PJSIP/7001,30)
same => n,Hangup()
; dial 7002
exten => 7002,1,NoOp(Call to 7002)
same => n,Dial(PJSIP/7002,30)
same => n,Hangup()
; dial 7003
exten => 7003,1,NoOp(Call to 7003)
same => n,Dial(PJSIP/7003,30)
same => n,Hangup()
; dial 7004
exten => 7004,1,NoOp(Call to 7004)
same => n,Dial(PJSIP/7004,30)
same => n,Hangup()