#########################################################
#
# For Patton 2 to 8 FXO
# Supported firmware versions R6.x
#
# Author: Tommaso Missoni
# Contact: [email protected]
#
#########################################################
webserver port 80 language en
system
ic voice 0
low-bitrate-codec g729
sntp-client
sntp-client server primary xxx.xxx.xxx.xxx
profile ppp default
profile call-progress-tone defaultDialtone
flush-play-list
play 1 1000 350 -13 440 -13
profile call-progress-tone defaultAlertingtone
flush-play-list
play 1 1000 440 -19 480 -19
pause 2 3000
profile call-progress-tone defaultBusytone
flush-play-list
play 1 500 480 -24 620 -24
pause 2 500
profile call-progress-tone defaultReleasetone
flush-play-list
play 1 250 480 -24 620 -24
pause 2 250
profile call-progress-tone defaultCongestiontone
flush-play-list
play 1 250 480 -24 620 -24
pause 2 250
profile tone-set default
profile voip default
codec 1 g711ulaw64k rx-length 20 tx-length 20 silence-suppression
codec 2 g711alaw64k rx-length 20 tx-length 20 silence-suppression
codec 3 g729 rx-length 20 tx-length 20 silence-suppression
fax transmission 1 relay t38-udp
profile pstn default
echo-canceler-hybrid-loss 0
echo-canceler-nlp silence
profile sip default
profile aaa default
method 1 local
method 2 none
context ip router
interface IF_IP_WAN
ipaddress dhcp
tcp adjust-mss rx mtu
tcp adjust-mss tx mtu
interface IF_IP_LAN
ipaddress xxx.xxx.xxx.xxx 255.255.255.0
tcp adjust-mss rx mtu
tcp adjust-mss tx mtu
context ip router
route 0.0.0.0 0.0.0.0 xxx.xxx.xxx.x 0
context cs switch
routing-table called-e164 RT_SIP_TO_FXO
route .% dest-service HG_TO_FXO
routing-table called-e164 RT_FXO_00_TO_SIP
route default dest-interface IF_SIP MT_CALL_ID_00
routing-table called-e164 RT_FXO_01_TO_SIP
route default dest-interface IF_SIP MT_CALL_ID_01
routing-table called-e164 RT_FXO_02_TO_SIP
route default dest-interface IF_SIP MT_CALL_ID_02
routing-table called-e164 RT_FXO_03_TO_SIP
route default dest-interface IF_SIP MT_CALL_ID_03
mapping-table called-e164 to called-e164 MT_CALL_ID_00
map .% to 000000
mapping-table called-e164 to called-e164 MT_CALL_ID_01
map .% to 000001
mapping-table called-e164 to called-e164 MT_CALL_ID_02
map .% to 000002
mapping-table called-e164 to called-e164 MT_CALL_ID_03
map .% to 000003
service hunt-group HG_TO_FXO
drop-cause destination-out-of-order
drop-cause user-busy
drop-cause normal-unspecified
drop-cause no-circuit-channel-available
drop-cause network-out-of-order
drop-cause temporary-failure
drop-cause switching-equipment-congestion
drop-cause access-info-discarded
drop-cause circuit-channel-not-available
drop-cause resources-unavailable
route call 1 dest-interface IF_FXO_0
interface sip IF_SIP
bind context sip-gateway GW_SIP
early-disconnect
route call dest-table RT_SIP_TO_FXO
remote 10.1.104.17 5060
trust remote
address-translation outgoing-call request-uri user-part fix 10002 host-part to-header target-param none
address-translation incoming-call called-e164 request-uri
interface fxo IF_FXO_0
route call dest-table RT_FXO_00_TO_SIP
loop-break-duration min 300 max 1200
caller-id format bell
ring-number on-caller-id
mute-dialing
disconnect-signal loop-break
disconnect-signal busy-tone
dial-after timeout 1
interface fxo IF_FXO_1
route call dest-table RT_FXO_01_TO_SIP
loop-break-duration min 300 max 1200
caller-id format bell
ring-number on-caller-id
mute-dialing
disconnect-signal loop-break
disconnect-signal busy-tone
dial-after timeout 1
interface fxo IF_FXO_2
route call dest-table RT_FXO_02_TO_SIP
loop-break-duration min 300 max 1200
caller-id format bell
ring-number on-caller-id
mute-dialing
disconnect-signal loop-break
disconnect-signal busy-tone
dial-after timeout 1
interface fxo IF_FXO_3
route call dest-table RT_FXO_03_TO_SIP
loop-break-duration min 300 max 1200
caller-id format bell
ring-number on-caller-id
mute-dialing
disconnect-signal loop-break
disconnect-signal busy-tone
dial-after timeout 1
context cs switch
no shutdown
authentication-service AS_ALL_LINES
realm 1 3CXPhoneSystem
username 10002 password hkjhduiud
location-service LS_10002
domain 1 xxx.xxx.xxx.xxx
identity-group default
authentication outbound
authenticate 1 authentication-service AS_ALL_LINES username 10002
identity 10002
authentication outbound
authenticate 1 authentication-service AS_ALL_LINES
registration outbound
registrar xxx.xxx.xxx.xxx 5060
lifetime 300
register auto
register auto
context sip-gateway GW_SIP
interface LAN
bind interface IF_IP_LAN context router port 5060
context sip-gateway GW_SIP
bind location-service LS_10002
no shutdown
port ethernet 0 0
medium auto
encapsulation ip
bind interface IF_IP_LAN router
no shutdown
port ethernet 0 1
medium auto
encapsulation ip
bind interface IF_IP_WAN router
no shutdown
port fxo 0 0
use profile fxo us
encapsulation cc-fxo
bind interface IF_FXO_0 switch
no shutdown
port fxo 0 1
use profile fxo us
encapsulation cc-fxo
bind interface IF_FXO_1 switch
no shutdown
port fxo 0 2
use profile fxo us
encapsulation cc-fxo
bind interface IF_FXO_2 switch
no shutdown
port fxo 0 3
use profile fxo us
encapsulation cc-fxo
bind interface IF_FXO_3 switch
no shutdown
context cs
no IF_FXO_1
no IF_FXO_2
no IF_FXO_3
port fxo 0 1
shutdown
port fxo 0 2
shutdown
port fxo 0 3
shutdown