├── asterisk ├── adsi.conf ├── dnsmgr.conf ├── cli.conf ├── cdr_manager.conf ├── enum.conf ├── udptl.conf ├── amd.conf ├── res_pktccops.conf ├── sip_notify.conf ├── rtp.conf ├── muted.conf ├── res_stun_monitor.conf ├── queuerules.conf ├── dsp.conf ├── cdr_custom.conf ├── telcordia-1.adsi ├── phone.conf ├── codecs.conf ├── cel_custom.conf ├── modules.conf ├── alarmreceiver.conf ├── iaxprov.conf ├── cli_permissions.conf ├── smdi.conf ├── users.conf ├── musiconhold.conf ├── agents.conf ├── http.conf ├── cdr_syslog.conf ├── extconfig.conf ├── followme.conf ├── asterisk.adsi ├── asterisk.conf ├── osp.conf ├── cel.conf ├── logger.conf ├── mgcp.conf ├── manager.conf ├── vpb.conf ├── cli_aliases.conf ├── ccss.conf ├── sla.conf ├── phoneprov.conf ├── cdr.conf ├── h323.conf ├── dundi.conf ├── features.conf ├── extensions.ael └── say.conf ├── supervisord.conf └── Dockerfile /asterisk/adsi.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Sample ADSI Configuration file 3 | ; 4 | [intro] 5 | alignment = center 6 | greeting => Welcome to the 7 | greeting => Asterisk 8 | greeting => Open Source PBX 9 | -------------------------------------------------------------------------------- /asterisk/dnsmgr.conf: -------------------------------------------------------------------------------- 1 | [general] 2 | ;enable=yes ; enable creation of managed DNS lookups 3 | ; default is 'no' 4 | ;refreshinterval=1200 ; refresh managed DNS lookups every seconds 5 | ; default is 300 (5 minutes) -------------------------------------------------------------------------------- /asterisk/cli.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Asterisk CLI configuration 3 | ; 4 | 5 | [startup_commands] 6 | ; 7 | ; Any commands listed in this section will get automatically executed 8 | ; when Asterisk starts as a daemon or foreground process (-c). 9 | ; 10 | ;sip set debug on = yes 11 | ;core set verbose 3 = yes 12 | ;core set debug 1 = yes 13 | -------------------------------------------------------------------------------- /asterisk/cdr_manager.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Asterisk Call Management CDR 3 | ; 4 | [general] 5 | enabled = no 6 | 7 | ; The "mappings" category can be used to define additional "key: value" pairs 8 | ; that will be included in the manager event. (after AccountCode, Source, etc). 9 | ; 10 | ; Each line like "varname => label" will include a "label: ${CDR(varname)}" 11 | ; in the generated event where ${CDR(varname)} its replaced with its value 12 | ; 13 | ;[mappings] 14 | ;rate => Rate 15 | ;carrier => Carrier 16 | -------------------------------------------------------------------------------- /supervisord.conf: -------------------------------------------------------------------------------- 1 | [supervisord] 2 | nodaemon=true ; (start in foreground if true;default false) 3 | 4 | [rpcinterface:supervisor] 5 | supervisor.rpcinterface_factory = supervisor.rpcinterface:make_main_rpcinterface 6 | 7 | [inet_http_server] 8 | port = 127.0.0.1:9001 9 | 10 | [supervisorctl] 11 | serverurl=http://127.0.0.1:9001 12 | 13 | [program:sshd] 14 | command = /usr/sbin/sshd -D 15 | 16 | [program:asterisk] 17 | command = /usr/sbin/asterisk -C /etc/asterisk/asterisk.conf 18 | 19 | -------------------------------------------------------------------------------- /asterisk/enum.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; ENUM Configuration for resolving phone numbers over DNS 3 | ; 4 | ; Sample config for Asterisk 5 | ; This file is reloaded at "module reload enum" in the CLI 6 | ; 7 | [general] 8 | ; 9 | ; The search list for domains may be customized. Domains are searched 10 | ; in the order they are listed here. 11 | ; 12 | search => e164.arpa 13 | ; 14 | ; If you'd like to use the E.164.org public ENUM registry in addition 15 | ; to the official e164.arpa one, uncomment the following line 16 | ; 17 | ;search => e164.org 18 | ; 19 | ; As there are more H323 drivers available you have to select to which 20 | ; drive a H323 URI will map. Default is "H323". 21 | ; 22 | h323driver => H323 23 | -------------------------------------------------------------------------------- /asterisk/udptl.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; UDPTL Configuration (UDPTL is one of the transports for T.38) 3 | ; 4 | [general] 5 | ; 6 | ; UDPTL start and UDPTL end configure start and end addresses 7 | ; 8 | udptlstart=4000 9 | udptlend=4999 10 | ; 11 | ; Whether to enable or disable UDP checksums on UDPTL traffic 12 | ; 13 | ;udptlchecksums=no 14 | ; 15 | ; The number of error correction entries in a UDPTL packet 16 | ; 17 | udptlfecentries = 3 18 | ; 19 | ; The span over which parity is calculated for FEC in a UDPTL packet 20 | ; 21 | udptlfecspan = 3 22 | ; 23 | ; Some VoIP providers will only accept an offer with an even-numbered 24 | ; UDPTL port. Set this option so that Asterisk will only attempt to use 25 | ; even-numbered ports when negotiating T.38. Default is no. 26 | use_even_ports = no 27 | -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM centos:6.4 2 | MAINTAINER David Watson 3 | 4 | # 5 | RUN rpm -Uvh http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm 6 | 7 | # install asterisk 8 | RUN yum install -y asterisk 9 | 10 | # install supervisord 11 | RUN yum install -y python-pip && pip install pip --upgrade 12 | RUN pip install supervisor 13 | 14 | # install sshd 15 | RUN yum install -y openssh-server openssh-clients passwd 16 | 17 | RUN ssh-keygen -q -N "" -t dsa -f /etc/ssh/ssh_host_dsa_key && ssh-keygen -q -N "" -t rsa -f /etc/ssh/ssh_host_rsa_key 18 | RUN sed -ri 's/UsePAM yes/UsePAM no/g' /etc/ssh/sshd_config && echo 'root:password' | chpasswd 19 | 20 | 21 | ADD supervisord.conf /etc/ 22 | ADD asterisk /etc/asterisk/ 23 | EXPOSE 22 24 | CMD ["supervisord", "-n", "-c", "/etc/supervisord.conf"] 25 | -------------------------------------------------------------------------------- /asterisk/amd.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Answering Machine Detection Configuration 3 | ; 4 | 5 | [general] 6 | initial_silence = 2500 ; Maximum silence duration before the greeting. 7 | ; If exceeded then MACHINE. 8 | greeting = 1500 ; Maximum length of a greeting. If exceeded then MACHINE. 9 | after_greeting_silence = 800 ; Silence after detecting a greeting. 10 | ; If exceeded then HUMAN 11 | total_analysis_time = 5000 ; Maximum time allowed for the algorithm to decide 12 | ; on a HUMAN or MACHINE 13 | min_word_length = 100 ; Minimum duration of Voice to considered as a word 14 | between_words_silence = 50 ; Minimum duration of silence after a word to consider 15 | ; the audio what follows as a new word 16 | maximum_number_of_words = 3 ; Maximum number of words in the greeting. 17 | ; If exceeded then MACHINE 18 | silence_threshold = 256 19 | -------------------------------------------------------------------------------- /asterisk/res_pktccops.conf: -------------------------------------------------------------------------------- 1 | ;; Sample res_pktccops.conf 2 | ; 3 | ;[general] 4 | ;gateinfoperiod => 60 ; default 60s 5 | ;gatetimeout = 150 ; default 150 6 | ;t1 => 250 ; default 250s 7 | ;t7 => 200 ; default 200s 8 | ;t8 => 300 ; default 300s 9 | ;keepalive => 60 ; default 60s 10 | ; 11 | ;[teszt] 12 | ;host => 192.168.0.24 13 | ;pool => 10.0.1.0 10.0.1.255 14 | ;pool => 10.0.3.0 10.0.3.255 15 | ;pool => 10.0.7.0 10.0.8.255 16 | ;pool => 10.0.10.0 10.0.11.255 17 | ; 18 | ;[general] 19 | ;gateinfoperiod => 60 ; default 60s 20 | ;gatetimeout = 150 ; default 150 21 | ;t1 => 250 ; default 250s 22 | ;t7 => 200 ; default 200s 23 | ;t8 => 300 ; default 300s 24 | ;keepalive => 60 ; default 60s 25 | ; 26 | ;[test] 27 | ;host => 192.168.0.24 28 | ;pool => 10.0.1.0 10.0.1.255 29 | ;pool => 10.0.3.0 10.0.3.255 30 | ;pool => 10.0.7.0 10.0.8.255 31 | ;pool => 10.0.10.0 10.0.11.255 32 | ; 33 | -------------------------------------------------------------------------------- /asterisk/sip_notify.conf: -------------------------------------------------------------------------------- 1 | ; rfc3842 2 | ; put empty "Content=>" at the end to have CRLF after last body line 3 | 4 | [clear-mwi] 5 | Event=>message-summary 6 | Content-type=>application/simple-message-summary 7 | Content=>Messages-Waiting: no 8 | Content=>Message-Account: sip:asterisk@127.0.0.1 9 | Content=>Voice-Message: 0/0 (0/0) 10 | Content=> 11 | 12 | ; Aastra 13 | 14 | [aastra-check-cfg] 15 | Event=>check-sync 16 | 17 | [aastra-xml] 18 | Event=>aastra-xml 19 | 20 | ; Digium 21 | 22 | [digium-check-cfg] 23 | Event=>check-sync 24 | 25 | ; Linksys 26 | 27 | [linksys-cold-restart] 28 | Event=>reboot_now 29 | 30 | [linksys-warm-restart] 31 | Event=>restart_now 32 | 33 | ; Polycom 34 | 35 | [polycom-check-cfg] 36 | Event=>check-sync 37 | 38 | ; Sipura 39 | 40 | [sipura-check-cfg] 41 | Event=>resync 42 | 43 | [sipura-get-report] 44 | Event=>report 45 | 46 | ; snom 47 | 48 | [snom-check-cfg] 49 | Event=>check-sync\;reboot=false 50 | 51 | [snom-reboot] 52 | Event=>check-sync\;reboot=true 53 | 54 | ; Cisco 55 | 56 | [cisco-check-cfg] 57 | Event=>check-sync 58 | -------------------------------------------------------------------------------- /asterisk/rtp.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; RTP Configuration 3 | ; 4 | [general] 5 | ; 6 | ; RTP start and RTP end configure start and end addresses 7 | ; 8 | ; Defaults are rtpstart=5000 and rtpend=31000 9 | ; 10 | rtpstart=10000 11 | rtpend=20000 12 | ; 13 | ; Whether to enable or disable UDP checksums on RTP traffic 14 | ; 15 | ;rtpchecksums=no 16 | ; 17 | ; The amount of time a DTMF digit with no 'end' marker should be 18 | ; allowed to continue (in 'samples', 1/8000 of a second) 19 | ; 20 | ;dtmftimeout=3000 21 | ; rtcpinterval = 5000 ; Milliseconds between rtcp reports 22 | ;(min 500, max 60000, default 5000) 23 | ; 24 | ; Enable strict RTP protection. This will drop RTP packets that 25 | ; do not come from the source of the RTP stream. This option is 26 | ; disabled by default. 27 | ; strictrtp=yes 28 | ; 29 | ; Number of packets containing consecutive sequence values needed 30 | ; to change the RTP source socket address. This option only comes 31 | ; into play while using strictrtp=yes. Consider changing this value 32 | ; if rtp packets are dropped from one or both ends after a call is 33 | ; connected. This option is set to 4 by default. 34 | ; probation=8 35 | -------------------------------------------------------------------------------- /asterisk/muted.conf: -------------------------------------------------------------------------------- 1 | # 2 | # Sample muted configuration file 3 | # 4 | # Copyright (C) 2004 Digium, Inc. 5 | # 6 | # First you have the host, username, and password 7 | # we use to connect to the asterisk system 8 | # 9 | # What is this? Well, haven't you ever wished you could automatically 10 | # turn down the volume on your stereo, CDPlayer, etc, when a call comes in, 11 | # and then return it to normal when the call ends? Well, this is a possible 12 | # mechanism to make this happen! 13 | # You have to fire up the new utils/muted, which runs as a daemon in the 14 | # background. This daemon connects to asterisk via a manager interface, and 15 | # also reads this config file from /etc/muted.conf. when the channels mentioned 16 | # are activated, it tweaks the sound levels on the sound card(s). 17 | # So, depending on the sound card, you may be able to run all your sound 18 | # generating devices thru your sound card, and use this mechanism to quiet 19 | # them down while you are on the phone. If anyone figures out how to make 20 | # this work with kids, please inform!! 21 | # 22 | host localhost 23 | user user 24 | pass pass 25 | # 26 | # List each channel we're supposed to watch 27 | # 28 | channel DAHDI/1 29 | channel DAHDI/2 30 | channel SIP/mark 31 | # 32 | # Mute level is the percentage of the current volume we should 33 | # lower the music to. 34 | # 35 | mutelevel 20 36 | # 37 | # Smooth fade makes the fadein/fadeout nicer sounding 38 | # 39 | smoothfade 40 | -------------------------------------------------------------------------------- /asterisk/res_stun_monitor.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Configuration file for the res_stun_monitor module 3 | ; 4 | ; The res_stun_monitor module sends STUN requests to a configured STUN server 5 | ; periodically. If the monitor detects a change in the external IP address or port 6 | ; provided by the STUN server an event is sent out internally within Asterisk 7 | ; to alert all listeners to that event of the change. 8 | 9 | ; The current default listeners for the network change event include chan_sip 10 | ; and chan_iax. Both of these channel drivers by default react to this event 11 | ; by renewing all outbound registrations. This allows the endpoints Asterisk 12 | ; is registering with to become aware of the address change and know the new 13 | ; location. 14 | ; 15 | [general] 16 | ; 17 | ; ---- STUN Server configuration --- 18 | ; Setting the 'stunaddr' option to a valid address enables the STUN monitor. 19 | ; 20 | ;stunaddr = mystunserver.com ; Address of the STUN server to query. 21 | ; Valid form: 22 | ; [(hostname | IP-address) [':' port]] 23 | ; The port defaults to the standard STUN port (3478). 24 | ; Set to an empty value to disable STUN monitoring. 25 | ; Default is disabled. 26 | ;stunrefresh = 30 ; Number of seconds between STUN refreshes. 27 | ; Default is 30. 28 | -------------------------------------------------------------------------------- /asterisk/queuerules.conf: -------------------------------------------------------------------------------- 1 | ; It is possible to change the value of the QUEUE_MAX_PENALTY and QUEUE_MIN_PENALTY 2 | ; channel variables in mid-call by defining rules in the queue for when to do so. This can allow for 3 | ; a call to be opened to more members or potentially a different set of members. 4 | ; The advantage to changing members this way as opposed to inserting the caller into a 5 | ; different queue with more members or reinserting the caller into the same queue with a different 6 | ; QUEUE_MAX_PENALTY or QUEUE_MIN_PENALTY set is that the caller does not lose his place in the queue. 7 | ; 8 | ; Note: There is a limitation to these rules; a caller will follow the penaltychange rules for 9 | ; the queue that were defined at the time the caller entered the queue. If an update to the rules is 10 | ; made during the caller's stay in the queue, these will not be reflected for that caller. 11 | ; 12 | ; The syntax for these rules is 13 | ; penaltychange => ,[,absolute or relative change to QUEUE_MIN_PENALTY] 14 | ; 15 | ; Example: 16 | ; [myrule] 17 | ; penaltychange => 30,+3 ; 30 seconds into the call increase the QUEUE_MAX_PENALTY by 3, no change to QUEUE_MIN_PENALTY 18 | ; penaltychange => 60,10,5 ; 60 seconds into the call increase the QUEUE_MAX_PENALTY to 10 and increase the QUEUE_MIN_PENALTY to 5 19 | ; penaltychange => 75,,7 ; 75 seconds into the call keep the QUEUE_MAX_PENALTY the same and increase the QUEUE_MIN_PENALTY to 7 20 | 21 | -------------------------------------------------------------------------------- /asterisk/dsp.conf: -------------------------------------------------------------------------------- 1 | [default] 2 | ; 3 | ; Length of sound (in milliseconds) before a period of silence is considered 4 | ; to be a change from talking to silence or a period of noise converts silence 5 | ; to talking. [default=256] 6 | ; 7 | ;silencethreshold=256 8 | 9 | ; DTMF Reverse Twist and Normal Twist is the difference in power between the row and column energies. 10 | ; 11 | ; Normal Twist is where the Column energy is greater than the Row energy 12 | ; Reverse Twist is where the Row energy is greater. 13 | ; 14 | ; Power level difference between frequencies for different Administrations/RPOAs 15 | ; Power Gain equiv 16 | ; normal reverse dB's 17 | ; AT&T(default) 6.31 2.51 8dB(normal), 4dB(reverse) 18 | ; NTT 3.16 3.16 Max. 5dB 19 | ; Danish 3.98 3.98 Max. 6dB 20 | ; Australian 10.0 10.0 Max. 10dB 21 | ; Brazilian 7.94 7.94 Max. 9dB 22 | ; ETSI 3.98 3.98 Max. 6dB 23 | 24 | ;previous version compatible AT&T values 25 | ; RADIO_RELAX disabled, and relaxdtmf=no 26 | ; 6.30 2.50 7.99dB(normal), 3.98dB(reverse) 27 | ; RADIO_RELAX disabled, and relaxdtmf=yes 28 | ; 6.30 4.00 7.99dB(normal), 6.02dB(reverse) 29 | ; RADIO_RELAX enabled, and relaxdtmf=no 30 | ; 6.30 2.50 7.99dB(normal), 3.984dB(reverse) 31 | ; RADIO_RELAX enabled, and relaxdtmf=yes 32 | ; 6.30 6.50 7.99dB(normal), 8.13dB(reverse) 33 | 34 | ;If you don't know what these mean, don't change them. 35 | ;dtmf_normal_twist=6.31 36 | ;dtmf_reverse_twist=2.51 37 | ;relax_dtmf_normal_twist=6.31 38 | ;relax_dtmf_reverse_twist=3.98 39 | 40 | ;successive number hits/misses of 12.75ms before a digit/nodigit is considered valid 41 | ;dtmf_hits_to_begin=2 42 | ;dtmf_misses_to_end=3 43 | 44 | -------------------------------------------------------------------------------- /asterisk/cdr_custom.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Mappings for custom config file 3 | ; 4 | ; To get your CSV output in a format tailored to your liking, uncomment the 5 | ; following lines and look for the output in the cdr-custom directory (usually 6 | ; in /var/log/asterisk). Depending on which mapping you uncomment, you may see 7 | ; Master.csv, Simple.csv, or both. 8 | ; 9 | ;[mappings] 10 | ;Master.csv => ${CSV_QUOTE(${CDR(clid)})},${CSV_QUOTE(${CDR(src)})},${CSV_QUOTE(${CDR(dst)})},${CSV_QUOTE(${CDR(dcontext)})},${CSV_QUOTE(${CDR(channel)})},${CSV_QUOTE(${CDR(dstchannel)})},${CSV_QUOTE(${CDR(lastapp)})},${CSV_QUOTE(${CDR(lastdata)})},${CSV_QUOTE(${CDR(start)})},${CSV_QUOTE(${CDR(answer)})},${CSV_QUOTE(${CDR(end)})},${CSV_QUOTE(${CDR(duration)})},${CSV_QUOTE(${CDR(billsec)})},${CSV_QUOTE(${CDR(disposition)})},${CSV_QUOTE(${CDR(amaflags)})},${CSV_QUOTE(${CDR(accountcode)})},${CSV_QUOTE(${CDR(uniqueid)})},${CSV_QUOTE(${CDR(userfield)})},${CDR(sequence)} 11 | ; 12 | ; High Resolution Time for billsec and duration fields 13 | ;Master.csv => ${CSV_QUOTE(${CDR(clid)})},${CSV_QUOTE(${CDR(src)})},${CSV_QUOTE(${CDR(dst)})},${CSV_QUOTE(${CDR(dcontext)})},${CSV_QUOTE(${CDR(channel)})},${CSV_QUOTE(${CDR(dstchannel)})},${CSV_QUOTE(${CDR(lastapp)})},${CSV_QUOTE(${CDR(lastdata)})},${CSV_QUOTE(${CDR(start)})},${CSV_QUOTE(${CDR(answer)})},${CSV_QUOTE(${CDR(end)})},${CSV_QUOTE(${CDR(duration,f)})},${CSV_QUOTE(${CDR(billsec,f)})},${CSV_QUOTE(${CDR(disposition)})},${CSV_QUOTE(${CDR(amaflags)})},${CSV_QUOTE(${CDR(accountcode)})},${CSV_QUOTE(${CDR(uniqueid)})},${CSV_QUOTE(${CDR(userfield)})},${CDR(sequence)} 14 | ;Simple.csv => ${CSV_QUOTE(${EPOCH})},${CSV_QUOTE(${CDR(src)})},${CSV_QUOTE(${CDR(dst)})} 15 | -------------------------------------------------------------------------------- /asterisk/telcordia-1.adsi: -------------------------------------------------------------------------------- 1 | ; 2 | ; Asterisk default ADSI script 3 | ; 4 | ; 5 | ; Begin with the preamble requirements 6 | ; 7 | DESCRIPTION "Telcordia Demo" ; Name of vendor 8 | VERSION 0x02 ; Version of stuff 9 | ;SECURITY "_AST" ; Security code 10 | SECURITY 0x0000 ; Security code 11 | FDN 0x0000000f ; Descriptor number 12 | 13 | ; 14 | ; Predefined strings 15 | ; 16 | DISPLAY "talkingto" IS "Talking To" "$Call1p" WRAP 17 | DISPLAY "titles" IS "20th Century IQ Svc" 18 | DISPLAY "newcall" IS "New Call From" "$Call1p" WRAP 19 | DISPLAY "ringing" IS "Ringing" 20 | 21 | ; 22 | ; Begin state definitions 23 | ; 24 | STATE "callup" ; Call is currently up 25 | STATE "inactive" ; No active call 26 | 27 | ; 28 | ; Begin soft key definitions 29 | ; 30 | KEY "CB_OH" IS "Block" OR "Call Block" 31 | OFFHOOK 32 | VOICEMODE 33 | WAITDIALTONE 34 | SENDDTMF "*60" 35 | SUBSCRIPT "offHook" 36 | ENDKEY 37 | 38 | KEY "CB" IS "Block" OR "Call Block" 39 | SENDDTMF "*60" 40 | ENDKEY 41 | 42 | ; 43 | ; Begin main subroutine 44 | ; 45 | 46 | SUB "main" IS 47 | IFEVENT NEARANSWER THEN 48 | CLEAR 49 | SHOWDISPLAY "talkingto" AT 1 50 | GOTO "stableCall" 51 | ENDIF 52 | IFEVENT OFFHOOK THEN 53 | CLEAR 54 | SHOWDISPLAY "titles" AT 1 55 | SHOWKEYS "CB" 56 | GOTO "offHook" 57 | ENDIF 58 | IFEVENT IDLE THEN 59 | CLEAR 60 | SHOWDISPLAY "titles" AT 1 61 | SHOWKEYS "CB_OH" 62 | ENDIF 63 | IFEVENT CALLERID THEN 64 | CLEAR 65 | SHOWDISPLAY "newcall" AT 1 66 | ENDIF 67 | ENDSUB 68 | 69 | SUB "offHook" IS 70 | IFEVENT FARRING THEN 71 | CLEAR 72 | SHOWDISPLAY "ringing" AT 1 73 | ENDIF 74 | IFEVENT FARANSWER THEN 75 | CLEAR 76 | SHOWDISPLAY "talkingto" AT 1 77 | GOTO "stableCall" 78 | ENDIF 79 | ENDSUB 80 | 81 | SUB "stableCall" IS 82 | 83 | ENDSUB 84 | -------------------------------------------------------------------------------- /asterisk/phone.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Linux Telephony Interface 3 | ; 4 | ; Configuration file 5 | ; 6 | [interfaces] 7 | ; 8 | ; Select a mode, either the phone jack provides dialtone, reads digits, 9 | ; then starts PBX with the given extension (dialtone mode), or 10 | ; immediately provides the PBX without reading any digits or providing 11 | ; any dialtone (this is the immediate mode, the default). Also, you 12 | ; can set the mode to "fxo" if you have a linejack to make it operate 13 | ; properly. If you are using a Sigma Designs board you may set this to 14 | ; "sig". 15 | ; 16 | mode=immediate 17 | ;mode=dialtone 18 | ;mode=fxo 19 | ;mode=sig 20 | ; 21 | ; You can decide which format to use by default, "g723.1", "g729", or "slinear". 22 | ; Note that g729 is only supported for Sigma Designs boards. 23 | ; XXX Be careful, sometimes the card causes kernel panics when running 24 | ; in signed linear mode for some reason... XXX 25 | ; 26 | format=slinear 27 | ;format=g723.1 28 | ;format=g729 29 | ; 30 | ; And set the echo cancellation to "off", "low", "medium", and "high". 31 | ; This is not supported on all phones. 32 | ; 33 | echocancel=medium 34 | ; 35 | ; You can optionally use VAD/CNG silence suppression 36 | ; 37 | ;silencesupression=yes 38 | ; 39 | ; List all devices we can use. Contexts may also be specified 40 | ; 41 | ;context=local 42 | ; 43 | ; You can set txgain and rxgain for each device in the same way as context. 44 | ; If you want to change default gain value (1.0 =~ 100%) for device, simple 45 | ; add txgain or rxgain line before device line. But remember, if you change 46 | ; volume all cards listed below will be affected by these values. You can 47 | ; use float values (1.0, 0.5, 2.0) or percentage values (100%, 150%, 50%). 48 | ; 49 | ;txgain=100% 50 | ;rxgain=1.0 51 | ;device => /dev/phone0 52 | -------------------------------------------------------------------------------- /asterisk/codecs.conf: -------------------------------------------------------------------------------- 1 | [speex] 2 | ; CBR encoding quality [0..10] 3 | ; used only when vbr = false 4 | quality => 3 5 | 6 | ; codec complexity [0..10] 7 | ; tradeoff between cpu/quality 8 | complexity => 2 9 | 10 | ; perceptual enhancement [true / false] 11 | ; improves clarity of decoded speech 12 | enhancement => true 13 | 14 | ; voice activity detection [true / false] 15 | ; reduces bitrate when no voice detected, used only for CBR 16 | ; (implicit in VBR/ABR) 17 | vad => true 18 | 19 | ; variable bit rate [true / false] 20 | ; uses bit rate proportionate to voice complexity 21 | vbr => true 22 | 23 | ; available bit rate [bps, 0 = off] 24 | ; encoding quality modulated to match this target bit rate 25 | ; not recommended with dtx or pp_vad - may cause bandwidth spikes 26 | abr => 0 27 | 28 | ; VBR encoding quality [0-10] 29 | ; floating-point values allowed 30 | vbr_quality => 4 31 | 32 | ; discontinuous transmission [true / false] 33 | ; stops transmitting completely when silence is detected 34 | ; pp_vad is far more effective but more CPU intensive 35 | dtx => false 36 | 37 | ; preprocessor configuration 38 | ; these options only affect Speex v1.1.8 or newer 39 | 40 | ; enable preprocessor [true / false] 41 | ; allows dsp functionality below but incurs CPU overhead 42 | preprocess => false 43 | 44 | ; preproc voice activity detection [true / false] 45 | ; more advanced equivalent of DTX, based on voice frequencies 46 | pp_vad => false 47 | 48 | ; preproc automatic gain control [true / false] 49 | pp_agc => false 50 | pp_agc_level => 8000 51 | 52 | ; preproc denoiser [true / false] 53 | pp_denoise => false 54 | 55 | ; preproc dereverb [true / false] 56 | pp_dereverb => false 57 | pp_dereverb_decay => 0.4 58 | pp_dereverb_level => 0.3 59 | 60 | 61 | [plc] 62 | ; for all codecs which do not support native PLC 63 | ; this determines whether to perform generic PLC 64 | ; there is a minor performance penalty for this 65 | genericplc => true 66 | -------------------------------------------------------------------------------- /asterisk/cel_custom.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Asterisk Channel Event Logging (CEL) - Custom CSV Backend 3 | ; 4 | 5 | ; This is the configuration file for the customizable CSV backend for CEL 6 | ; logging. 7 | ; 8 | ; In order to create custom CSV logs for CEL, uncomment the template below 9 | ; (Master.csv) and start Asterisk. Once CEL events are generated, a file will 10 | ; appear in the following location: 11 | ; 12 | ; /var/log/asterisk/cel-custom/Master.csv 13 | ; 14 | ; (Note that /var/log/asterisk is the default and may differ on your system) 15 | ; 16 | ; You can also create more than one template if desired. All logs will appear 17 | ; in the cel-custom directory under your Asterisk logs directory. 18 | ; 19 | 20 | ; 21 | ; Within a mapping, use the CALLERID() and CHANNEL() functions to retrieve 22 | ; details from the CEL event. There are also a few variables created by this 23 | ; module that can be used in a mapping: 24 | ; 25 | ; eventtype - The name of the CEL event. 26 | ; eventtime - The timestamp of the CEL event. 27 | ; userdeftype - User defined event type name from CELGenUserEvent(). 28 | ; eventextra - Extra data included with this CEL event, typically along with 29 | ; an event of type USER_DEFINED from CELGenUserEvent(). 30 | ; BRIDGEPEER - Bridged peer channel name at the time of the CEL event. 31 | ; CHANNEL(peer) could also be used. 32 | ; 33 | [mappings] 34 | ;Master.csv => ${CSV_QUOTE(${eventtype})},${CSV_QUOTE(${eventtime})},${CSV_QUOTE(${CALLERID(name)})},${CSV_QUOTE(${CALLERID(num)})},${CSV_QUOTE(${CALLERID(ANI)})},${CSV_QUOTE(${CALLERID(RDNIS)})},${CSV_QUOTE(${CALLERID(DNID)})},${CSV_QUOTE(${CHANNEL(exten)})},${CSV_QUOTE(${CHANNEL(context)})},${CSV_QUOTE(${CHANNEL(channame)})},${CSV_QUOTE(${CHANNEL(appname)})},${CSV_QUOTE(${CHANNEL(appdata)})},${CSV_QUOTE(${CHANNEL(amaflags)})},${CSV_QUOTE(${CHANNEL(accountcode)})},${CSV_QUOTE(${CHANNEL(uniqueid)})},${CSV_QUOTE(${CHANNEL(linkedid)})},${CSV_QUOTE(${BRIDGEPEER})},${CSV_QUOTE(${CHANNEL(userfield)})},${CSV_QUOTE(${userdeftype})},${CSV_QUOTE(${eventextra})} 35 | -------------------------------------------------------------------------------- /asterisk/modules.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Asterisk configuration file 3 | ; 4 | ; Module Loader configuration file 5 | ; 6 | 7 | [modules] 8 | autoload=yes 9 | ; 10 | ; Any modules that need to be loaded before the Asterisk core has been 11 | ; initialized (just after the logger has been initialized) can be loaded 12 | ; using 'preload'. This will frequently be needed if you wish to map all 13 | ; module configuration files into Realtime storage, since the Realtime 14 | ; driver will need to be loaded before the modules using those configuration 15 | ; files are initialized. 16 | ; 17 | ; An example of loading ODBC support would be: 18 | ;preload => res_odbc.so 19 | ;preload => res_config_odbc.so 20 | ; 21 | ; Uncomment the following if you wish to use the Speech Recognition API 22 | ;preload => res_speech.so 23 | ; 24 | ; If you want Asterisk to fail if a module does not load, then use 25 | ; the "require" keyword. Asterisk will exit with a status code of 2 26 | ; if a required module does not load. 27 | ; 28 | ; require = chan_sip.so 29 | ; If you want you can combine with preload 30 | ; preload-require = res_odbc.so 31 | ; 32 | ; If you want, load the GTK console right away. 33 | ; 34 | noload => pbx_gtkconsole.so 35 | ;load => pbx_gtkconsole.so 36 | ; 37 | load => res_musiconhold.so 38 | ; 39 | ; Load one of: chan_oss, alsa, or console (portaudio). 40 | ; By default, load chan_oss only (automatically). 41 | ; 42 | noload => chan_alsa.so 43 | ;noload => chan_oss.so 44 | noload => chan_console.so 45 | ; 46 | 47 | ; 48 | ; Voicemail storage selection 49 | ; 50 | ; Comment out the "noload" lines for the voicemail 51 | ; storage system that you want. Leave the ones that 52 | ; you don't want uncommented. 53 | ; 54 | 55 | ; 56 | ; Voicemail with IMAP storage 57 | ; 58 | noload => app_directory_imap.so 59 | noload => app_voicemail_imap.so 60 | 61 | ; 62 | ; Voicemail with ODBC storage 63 | ; 64 | noload => app_directory_odbc.so 65 | noload => app_voicemail_odbc.so 66 | 67 | ; 68 | ; Voicemail with filesystem storage 69 | ; 70 | ;noload => app_directory_plain.so 71 | ;noload => app_voicemail_plain.so 72 | 73 | ; Don't load chan_mgcp and res_pktccops automatically 74 | noload => chan_mgcp.so 75 | noload => res_pktccops.so 76 | -------------------------------------------------------------------------------- /asterisk/alarmreceiver.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; alarmreceiver.conf 3 | ; 4 | ; Sample configuration file for the Asterisk alarm receiver application. 5 | ; 6 | 7 | 8 | [general] 9 | 10 | ; 11 | ; Specify a timestamp format for the metadata section of the event files 12 | ; Default is %a %b %d, %Y @ %H:%M:%S %Z 13 | 14 | timestampformat = %a %b %d, %Y @ %H:%M:%S %Z 15 | 16 | ; 17 | ; Specify a command to execute when the caller hangs up 18 | ; 19 | ; Default is none 20 | ; 21 | 22 | ;eventcmd = yourprogram -yourargs ... 23 | 24 | ; 25 | ; Specify a spool directory for the event files. This setting is required 26 | ; if you want the app to be useful. Event files written to the spool 27 | ; directory will be of the template event-XXXXXX, where XXXXXX is a random 28 | ; and unique alphanumeric string. 29 | ; 30 | ; Default is none, and the events will be dropped on the floor. 31 | ; 32 | 33 | eventspooldir = /tmp 34 | 35 | ; 36 | ; The alarmreceiver app can either log the events one-at-a-time to individual 37 | ; files in the spool directory, or it can store them until the caller 38 | ; disconnects and write them all to one file. 39 | ; 40 | ; The default setting for logindividualevents is no. 41 | ; 42 | 43 | logindividualevents = no 44 | 45 | ; 46 | ; The timeout for receiving the first DTMF digit is adjustable from 1000 msec. 47 | ; to 10000 msec. The default is 2000 msec. Note: if you wish to test the 48 | ; receiver by entering digits manually, set this to a reasonable time out 49 | ; like 10000 milliseconds. 50 | 51 | fdtimeout = 2000 52 | 53 | ; 54 | ; The timeout for receiving subsequent DTMF digits is adjustable from 55 | ; 110 msec. to 4000 msec. The default is 200 msec. Note: if you wish to test 56 | ; the receiver by entering digits manually, set this to a reasonable time out 57 | ; like 4000 milliseconds. 58 | ; 59 | 60 | sdtimeout = 200 61 | 62 | ; 63 | ; The loudness of the ACK and Kissoff tones is adjustable from 100 to 8192. 64 | ; The default is 8192. This shouldn't need to be messed with, but is included 65 | ; just in case there are problems with signal levels. 66 | ; 67 | 68 | loudness = 8192 69 | 70 | ; 71 | ; The db-family setting allows the user to capture statistics on the number of 72 | ; calls, and the errors the alarm receiver sees. The default is for no 73 | ; db-family name to be defined and the database logging to be turned off. 74 | ; 75 | 76 | ;db-family = yourfamily: 77 | 78 | ; 79 | ; End of alarmreceiver.conf 80 | ; 81 | -------------------------------------------------------------------------------- /asterisk/iaxprov.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; IAX2 Provisioning Information 3 | ; 4 | ; Contains provisioning information for templates and for specific service 5 | ; entries. 6 | ; 7 | ; Templates provide a group of settings from which provisioning takes place. 8 | ; A template may be based upon any template that has been specified before 9 | ; it. If the template that an entry is based on is not specified then it is 10 | ; presumed to be 'default' (unless it is the first of course). 11 | ; 12 | ; Templates which begin with 'si-' are used for provisioning units with 13 | ; specific service identifiers. For example the entry "si-000364000126" 14 | ; would be used when the device with the corresponding service identifier of 15 | ; "000364000126" attempts to register or make a call. 16 | ; 17 | [default] 18 | ; 19 | ; The port number the device should use to bind to. The default is 4569. 20 | ; 21 | ;port=4569 22 | ; 23 | ; server is our PRIMARY server for registration and placing calls 24 | ; 25 | ;server=192.168.69.3 26 | ; 27 | ; altserver is the BACKUP server for registration and placing calls in the 28 | ; event the primary server is unavailable. 29 | ; 30 | ;altserver=192.168.69.4 31 | ; 32 | ; port is the port number to use for IAX2 outbound. The connections to the 33 | ; server and altserver -- default is of course 4569. 34 | ;serverport=4569 35 | ; 36 | ; language is the preferred language for the device 37 | ; 38 | ;language=en 39 | ; 40 | ; codec is the requested codec. The iaxy supports ulaw and adpcm 41 | ; 42 | codec=ulaw 43 | ; 44 | ; flags is a comma separated list of flags which the device should 45 | ; use and may contain any of the following keywords: 46 | ; 47 | ; "register" - Register with server 48 | ; "secure" - Do not accept calls / provisioning not originated by the server 49 | ; "heartbeat" - Generate status packets on port 9999 sent to 255.255.255.255 50 | ; "debug" - Output extra debugging to port 9999 51 | ; 52 | ; Note that use can use += and -= to adjust parameters 53 | ; 54 | flags=register,heartbeat 55 | ; 56 | ; See https://wiki.asterisk.org/wiki/display/AST/IP+Quality+of+Service for a description of this parameter. 57 | ;tos=ef 58 | ; 59 | ; Example iaxy provisioning 60 | ; 61 | ;[si-000364000126] 62 | ;user=iaxy 63 | ;pass=bitsy 64 | ;flags += debug 65 | 66 | ;[si-000364000127] 67 | ;user=iaxy2 68 | ;pass=bitsy2 69 | ;template=si-000364000126 70 | ;flags += debug 71 | 72 | ; 73 | ;[*] 74 | ; 75 | ; If specified, the '*' provisioning is used for all devices which do not 76 | ; have another provisioning entry within the file. If unspecified, no 77 | ; provisioning will take place for devices which have no entry. DO NOT 78 | ; USE A '*' PROVISIONING ENTRY UNLESS YOU KNOW WHAT YOU'RE DOING. 79 | ; 80 | ;template=default 81 | 82 | -------------------------------------------------------------------------------- /asterisk/cli_permissions.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; CLI permissions configuration example for Asterisk 3 | ; 4 | ; All the users that you want to connect with asterisk using 5 | ; rasterisk, should have write/read access to the 6 | ; asterisk socket (asterisk.ctl). You could change the permissions 7 | ; of this file in 'asterisk.conf' config parameter: 'astctlpermissions' (0666) 8 | ; found on the [files] section. 9 | ; 10 | ; general options: 11 | ; 12 | ; default_perm = permit | deny 13 | ; This is the default permissions to apply for a user that 14 | ; does not has a permissions definided. 15 | ; 16 | ; user options: 17 | ; permit = | all ; allow the user to run 'command' | 18 | ; ; allow the user to run 'all' the commands 19 | ; deny = | all ; disallow the user to run 'command' | 20 | ; ; disallow the user to run 'all' commands. 21 | ; 22 | 23 | [general] 24 | 25 | default_perm=permit ; To leave asterisk working as normal 26 | ; we should set this parameter to 'permit' 27 | ; 28 | ; Follows the per-users permissions configs. 29 | ; 30 | ; This list is read in the sequence that is being written, so 31 | ; In this example the user 'eliel' is allow to run only the following 32 | ; commands: 33 | ; sip show peer 34 | ; core set debug 35 | ; core set verbose 36 | ; If the user is not specified, the default_perm option will be apply to 37 | ; every command. 38 | ; 39 | ; Notice that you can also use regular expressions to allow or deny access to a 40 | ; certain command like: 'core show application D*'. In this example the user will be 41 | ; allowed to view the documentation for all the applications starting with 'D'. 42 | ; Another regular expression could be: 'channel originate SIP/[0-9]* extension *' 43 | ; allowing the user to use 'channel originate' on a sip channel and with the 'extension' 44 | ; parameter and avoiding the use of the 'application' parameter. 45 | ; 46 | ; We can also use the templates syntax: 47 | ; [supportTemplate](!) 48 | ; deny=all 49 | ; permit=sip show ; all commands starting with 'sip show' will be allowed 50 | ; permit=core show 51 | ; 52 | ; You can specify permissions for a local group instead of a user, 53 | ; just put a '@' and we will know that is a group. 54 | ; IMPORTANT NOTE: Users permissions overwrite group permissions. 55 | ; 56 | ;[@adm] 57 | ;deny=all 58 | ;permit=sip 59 | ;permit=core 60 | ; 61 | ; 62 | ;[eliel] 63 | ;deny=all 64 | ;permit=sip show peer 65 | ;deny=sip show peers 66 | ;permit=core set 67 | ; 68 | ; 69 | ;User 'tommy' inherits from template 'supportTemplate': 70 | ; deny=all 71 | ; permit=sip show 72 | ; permit=core show 73 | ;[tommy](supportTemplate) 74 | ;permit=core set debug 75 | ;permit=dialplan show 76 | ; 77 | ; 78 | ;[mark] 79 | ;deny=all 80 | ;permit=all 81 | ; 82 | ; 83 | -------------------------------------------------------------------------------- /asterisk/smdi.conf: -------------------------------------------------------------------------------- 1 | ; Asterisk SMDI configuration 2 | 3 | [interfaces] 4 | ; Specify serial ports to listen for SMDI messages on below. These will be 5 | ; referenced later in chan_dahdi.conf. If you do not specify any interfaces 6 | ; then SMDI will be disabled. Interfaces can have several different attributes 7 | ; associated with them. 8 | 9 | ; Set the number of stop bits to use per character here. The default is no, 10 | ; in which case one stop bit will be used. 11 | 12 | ;twostopbits = no 13 | 14 | ; Character size or bit length is the size of each character sent across the 15 | ; link. Character size can be 7 or 8. The default is 7. 16 | 17 | ;charsize = 7 18 | 19 | ; If you need parity checking enabled you can turn it on here. Acceptable 20 | ; values are even, odd, and none. The default is even. 21 | 22 | ;paritybit = even 23 | 24 | ; The baudrate to use for this port. Acceptable values are 1200, 2400, 4800, 25 | ; and 9600. The default is 9600. 26 | 27 | ;baudrate = 1200 28 | 29 | ; Often the numbering scheme for a set of mailboxes or extensions will not be 7 30 | ; or 10 digits (as SMDI requires). Use the msdstrip option to strip unused 31 | ; digits from the start of numbers. 32 | 33 | ;msdstrip = 0 34 | 35 | ; Occasionally Asterisk and the SMDI switch may become out of sync. If this 36 | ; happens, Asterisk will appear one or several calls behind as it processes 37 | ; voicemail requests. To prevent this from happening, adjust the msgexpirytime. 38 | ; This will make Asterisk discard old SMDI messages that have not yet been 39 | ; processed. The default expiry time is 30000 milliseconds. 40 | 41 | ;msgexpirytime = 30000 42 | 43 | ;smdiport => /dev/ttyS0 44 | 45 | 46 | [mailboxes] 47 | ; This section configures parameters related to MWI handling for the SMDI link. 48 | 49 | ; This option configures the polling interval used to check to see if the 50 | ; mailboxes have any new messages. This option is specified in seconds. 51 | ; The default value is 10 seconds. 52 | ; 53 | ;pollinginterval=10 54 | 55 | ; Every other entry in this section of the configuration file is interpreted as 56 | ; a mapping between the mailbox ID on the SMDI link, and the local Asterisk 57 | ; mailbox name. In many cases, they are the same thing, but they still must be 58 | ; listed here so that this module knows which mailboxes it needs to pay 59 | ; attention to. 60 | ; 61 | ; Syntax: 62 | ; =[@Asterisk Voicemail Context] 63 | ; 64 | ; If no Asterisk voicemail context is specified, "default" will be assumed. 65 | ; 66 | ; Before specifying mailboxes, you must specify an SMDI interface. All mailbox 67 | ; definitions that follow will correspond to that SMDI interface. If you specify 68 | ; another interface, then all definitions following that will correspond to the 69 | ; new interface. 70 | ; 71 | ;smdiport=/dev/ttyS0 72 | ;2565551234=1234@vmcontext1 73 | ;2565555678=5678@vmcontext2 74 | ;smdiport=/dev/ttyS1 75 | ;2565559999=9999 76 | -------------------------------------------------------------------------------- /asterisk/users.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; User configuration 3 | ; 4 | ; Creating entries in users.conf is a "shorthand" for creating individual 5 | ; entries in each configuration file. Using users.conf is not intended to 6 | ; provide you with as much flexibility as using the separate configuration 7 | ; files (e.g. sip.conf, iax.conf, etc) but is intended to accelerate the 8 | ; simple task of adding users. Note that creating individual items (e.g. 9 | ; custom SIP peers, IAX friends, etc.) will allow you to override specific 10 | ; parameters within this file. Parameter names here are the same as they 11 | ; appear in the other configuration files. There is no way to change the 12 | ; value of a parameter here for just one subsystem. 13 | ; 14 | 15 | [general] 16 | ; 17 | ; Full name of a user 18 | ; 19 | fullname = New User 20 | ; 21 | ; Starting point of allocation of extensions 22 | ; 23 | userbase = 6000 24 | ; 25 | ; Create voicemail mailbox and use use macro-stdexten 26 | ; 27 | hasvoicemail = yes 28 | ; 29 | ; Set voicemail mailbox 6000 password to 1234 30 | ; 31 | vmsecret = 1234 32 | ; 33 | ; Create SIP Peer 34 | ; 35 | hassip = yes 36 | ; 37 | ; Create IAX friend 38 | ; 39 | hasiax = yes 40 | ; 41 | ; Create H.323 friend 42 | ; 43 | ;hash323 = yes 44 | ; 45 | ; Create manager entry 46 | ; 47 | hasmanager = no 48 | ; 49 | ; Set permissions for manager entry (see manager.conf.sample for documentation) 50 | ; (defaults to *all* permissions) 51 | ;managerread = system,call,log,verbose,command,agent,user,config 52 | ;managerwrite = system,call,log,verbose,command,agent,user,config 53 | ; 54 | ; 55 | ; MAC Address for res_phoneprov 56 | ; 57 | ;macaddress = 112233445566 58 | ; 59 | ; Auto provision the phone with res_phoneprov 60 | ; 61 | ;autoprov = yes 62 | ; 63 | ; Line Keys for hardphone 64 | ; 65 | ;LINEKEYS = 1 66 | ; 67 | ; Line number for hardphone 68 | ; 69 | ;linenumber = 1 70 | ; 71 | ; Local Caller ID number used with res_phoneprov and Asterisk GUI 72 | ; 73 | ;cid_number = 6000 74 | ; 75 | ; Remaining options are not specific to users.conf entries but are general. 76 | ; 77 | callwaiting = yes 78 | threewaycalling = yes 79 | callwaitingcallerid = yes 80 | transfer = yes 81 | canpark = yes 82 | cancallforward = yes 83 | callreturn = yes 84 | callgroup = 1 85 | pickupgroup = 1 86 | ;nat = no 87 | 88 | ;[6000] 89 | ;fullname = Joe User 90 | ;email = joe@foo.bar 91 | ;secret = 1234 92 | ;dahdichan = 1 93 | ;hasvoicemail = yes 94 | ;vmsecret = 1234 95 | ;hassip = yes 96 | ;hasiax = no 97 | ;hash323 = no 98 | ;hasmanager = no 99 | ;callwaiting = no 100 | ;context = international 101 | ; 102 | ; Some administrators choose alphanumeric extensions, but still want their 103 | ; users to be reachable by traditional numeric extensions, specified by the 104 | ; alternateexts entry. 105 | ; 106 | ;alternateexts = 7057,3249 107 | ;macaddress = 112233445566 108 | ;autoprov = yes 109 | ;LINEKEYS = 1 110 | ;linenumber = 1 111 | ;cid_number = 6000 112 | 113 | -------------------------------------------------------------------------------- /asterisk/musiconhold.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Music on Hold -- Sample Configuration 3 | ; 4 | [general] 5 | ;cachertclasses=yes ; use 1 instance of moh class for all users who are using it, 6 | ; decrease consumable cpu cycles and memory 7 | ; disabled by default 8 | 9 | 10 | ; valid mode options: 11 | ; files -- read files from a directory in any Asterisk supported 12 | ; media format 13 | ; quietmp3 -- default 14 | ; mp3 -- loud 15 | ; mp3nb -- unbuffered 16 | ; quietmp3nb -- quiet unbuffered 17 | ; custom -- run a custom application (See examples below) 18 | 19 | ; ========= 20 | ; File-based (native) music on hold 21 | ; ========= 22 | ; 23 | ; This plays files directly from the specified directory, no external 24 | ; processes are required. Files are played in normal sorting order 25 | ; (same as a sorted directory listing), and no volume or other 26 | ; sound adjustments are available. If the file is available in 27 | ; the same format as the channel's codec, then it will be played 28 | ; without transcoding (same as Playback would do in the dialplan). 29 | ; Files can be present in as many formats as you wish, and the 30 | ; 'best' format will be chosen at playback time. 31 | ; 32 | ; The path specified can be either an absolute path (starts with '/'), 33 | ; or a relative path; relative paths are interpreted as being relative 34 | ; to the 'astdatadir' in asterisk.conf, which defaults to 35 | ; /usr/share/asterisk. 36 | ; 37 | ; NOTE: 38 | ; If you are not using "autoload" in modules.conf, then you 39 | ; must ensure that the format modules for any formats you wish 40 | ; to use are loaded _before_ res_musiconhold. If you do not do 41 | ; this, res_musiconhold will skip the files it is not able to 42 | ; understand when it loads. 43 | ; 44 | 45 | [default] 46 | mode=files 47 | directory=moh 48 | ; 49 | ;[native-random] 50 | ;mode=files 51 | ;directory=moh 52 | ;digit=# ; If this option is set for a class, then when callers are 53 | ; ; listening to music on hold, they can press this digit, and 54 | ; ; they will switch to listening to this music class. 55 | ;sort=random ; Sort the files in random order 56 | 57 | ;[native-alphabetical] 58 | ;mode=files 59 | ;directory=moh 60 | ;sort=alpha ; Sort the files in alphabetical order. If this option is 61 | ; ; not specified, the sort order is undefined. 62 | 63 | ; ========= 64 | ; Other (non-native) playback methods 65 | ; ========= 66 | 67 | ;[manual] 68 | ;mode=custom 69 | ; Note that with mode=custom, a directory is not required, such as when reading 70 | ; from a stream. 71 | ;directory=/usr/share/asterisk/mohmp3 72 | ;application=/usr/bin/mpg123 -q -r 8000 -f 8192 -b 2048 --mono -s 73 | 74 | ;[ulawstream] 75 | ;mode=custom 76 | ;application=/usr/bin/streamplayer 192.168.100.52 888 77 | ;format=ulaw 78 | 79 | ; mpg123 on Solaris does not always exit properly; madplay may be a better 80 | ; choice 81 | ;[solaris] 82 | ;mode=custom 83 | ;directory=/usr/share/asterisk/mohmp3 84 | ;application=/site/sw/bin/madplay -Q -o raw:- --mono -R 8000 -a -12 85 | -------------------------------------------------------------------------------- /asterisk/agents.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Agent configuration 3 | ; 4 | 5 | [general] 6 | 7 | [agents] 8 | ; 9 | ; Define maxlogintries to allow agent to try max logins before 10 | ; failed. 11 | ; default to 3 12 | ; 13 | ;maxlogintries=5 14 | ; 15 | ; 16 | ; Define autologoff times if appropriate. This is how long 17 | ; the phone has to ring with no answer before the agent is 18 | ; automatically logged off (in seconds) 19 | ; 20 | ;autologoff=15 21 | ; 22 | ; Define autologoffunavail to have agents automatically logged 23 | ; out when the extension that they are at returns a CHANUNAVAIL 24 | ; status when a call is attempted to be sent there. 25 | ; Default is "no". 26 | ; 27 | ;autologoffunavail=yes 28 | ; 29 | ; Define ackcall to require a DTMF acknowledgement when 30 | ; a logged-in agent receives a call. Default is "no". 31 | ; Use the acceptdtmf option to configure what DTMF key 32 | ; press should be used to acknowledge the call. The 33 | ; default is '#'. 34 | ; 35 | ;ackcall=no 36 | ;acceptdtmf=# 37 | ; 38 | ; Define endcall to allow an agent to hangup a call with a 39 | ; DTMF keypress. Default is "yes". Use the enddtmf option to 40 | ; configure which DTMF key will end a call. The default is 41 | ; '*'. 42 | ; 43 | ;endcall=yes 44 | ;enddtmf=* 45 | ; 46 | ; Define wrapuptime. This is the minimum amount of time when 47 | ; after disconnecting before the caller can receive a new call 48 | ; note this is in milliseconds. 49 | ; 50 | ;wrapuptime=5000 51 | ; 52 | ; Define the default musiconhold for agents 53 | ; musiconhold => music_class 54 | ; 55 | ;musiconhold => default 56 | ; 57 | ; Define the default good bye sound file for agents 58 | ; default to vm-goodbye 59 | ; 60 | ;goodbye => goodbye_file 61 | ; 62 | ; Define updatecdr. This is whether or not to change the source 63 | ; channel in the CDR record for this call to agent/agent_id so 64 | ; that we know which agent generates the call 65 | ; 66 | ;updatecdr=no 67 | ; 68 | ; Group memberships for agents (may change in mid-file) 69 | ; 70 | ;group=3 71 | ;group=1,2 72 | ;group= 73 | ; 74 | ; -------------------------------------------------- 75 | ; This section is devoted to recording agent's calls 76 | ; The keywords are global to the chan_agent channel driver 77 | ; 78 | ; Enable recording calls addressed to agents. It's turned off by default. 79 | ;recordagentcalls=yes 80 | ; 81 | ; The format to be used to record the calls: wav, gsm, wav49. 82 | ; By default its "wav". 83 | ;recordformat=gsm 84 | ; 85 | ; The text to be added to the name of the recording. Allows forming a url link. 86 | ;urlprefix=http://localhost/calls/ 87 | ; 88 | ; The optional directory to save the conversations in. The default is 89 | ; /var/spool/asterisk/monitor 90 | ;savecallsin=/var/calls 91 | ; 92 | ; An optional custom beep sound file to play to always-connected agents. 93 | ;custom_beep=beep 94 | ; 95 | ; -------------------------------------------------- 96 | ; 97 | ; This section contains the agent definitions, in the form: 98 | ; 99 | ; agent => agentid,agentpassword,name 100 | ; 101 | ;agent => 1001,4321,Mark Spencer 102 | ;agent => 1002,4321,Will Meadows 103 | -------------------------------------------------------------------------------- /asterisk/http.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Asterisk Builtin mini-HTTP server 3 | ; 4 | ; 5 | ; Note about Asterisk documentation: 6 | ; If Asterisk was installed from a tarball, then the HTML documentation should 7 | ; be installed in the static-http/docs directory which is 8 | ; (/usr/share/asterisk/static-http/docs) on linux by default. If the Asterisk 9 | ; HTTP server is enabled in this file by setting the "enabled", "bindaddr", 10 | ; and "bindport" options, then you should be able to view the documentation 11 | ; remotely by browsing to: 12 | ; http://:/static/docs/index.html 13 | ; 14 | [general] 15 | ; 16 | ; Whether HTTP/HTTPS interface is enabled or not. Default is no. 17 | ; This also affects manager/rawman/mxml access (see manager.conf) 18 | ; 19 | ;enabled=yes 20 | ; 21 | ; Address to bind to, both for HTTP and HTTPS. Default is 0.0.0.0 22 | ; 23 | bindaddr=127.0.0.1 24 | ; 25 | ; Port to bind to for HTTP sessions (default is 8088) 26 | ; 27 | ;bindport=8088 28 | ; 29 | ; Prefix allows you to specify a prefix for all requests 30 | ; to the server. The default is blank. If uncommented 31 | ; all requests must begin with /asterisk 32 | ; 33 | ;prefix=asterisk 34 | ; 35 | ; sessionlimit specifies the maximum number of httpsessions that will be 36 | ; allowed to exist at any given time. (default: 100) 37 | ; 38 | ;sessionlimit=100 39 | ; 40 | ; Whether Asterisk should serve static content from http-static 41 | ; Default is no. 42 | ; 43 | ;enablestatic=yes 44 | ; 45 | ; Redirect one URI to another. This is how you would set a 46 | ; default page. 47 | ; Syntax: redirect= 48 | ; For example, if you are using the Asterisk-gui, 49 | ; it is convenient to enable the following redirect: 50 | ; 51 | ;redirect = / /static/config/index.html 52 | ; 53 | ; HTTPS support. In addition to enabled=yes, you need to 54 | ; explicitly enable tls, define the port to use, 55 | ; and have a certificate somewhere. 56 | ;tlsenable=yes ; enable tls - default no. 57 | ;tlsbindaddr=0.0.0.0:8089 ; address and port to bind to - default is bindaddr and port 8089. 58 | ; 59 | ;tlscertfile= ; path to the certificate file (*.pem) only. 60 | ;tlsprivatekey= ; path to private key file (*.pem) only. 61 | ; If no path is given for tlscertfile or tlsprivatekey, default is to look in current 62 | ; directory. If no tlsprivatekey is given, default is to search tlscertfile for private key. 63 | ; 64 | ; To produce a certificate you can e.g. use openssl. This places both the cert and 65 | ; private in same .pem file. 66 | ; openssl req -new -x509 -days 365 -nodes -out /tmp/foo.pem -keyout /tmp/foo.pem 67 | ; 68 | ; The post_mappings section maps URLs to real paths on the filesystem. If a 69 | ; POST is done from within an authenticated manager session to one of the 70 | ; configured POST mappings, then any files in the POST will be placed in the 71 | ; configured directory. 72 | ; 73 | ;[post_mappings] 74 | ; 75 | ; In this example, if the prefix option is set to "asterisk", then using the 76 | ; POST URL: /asterisk/uploads will put files in /var/spool/asterisk/uploads/. 77 | ;uploads = /var/spool/asterisk/uploads/ 78 | ; 79 | -------------------------------------------------------------------------------- /asterisk/cdr_syslog.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Asterisk Call Detail Records (CDR) - Syslog Backend 3 | ; 4 | 5 | ; The cdr_syslog module writes CDRs using the facilities provided by syslog. 6 | ; 7 | ; Not only must you configure cdr_syslog from this file (cdr_syslog.conf) but 8 | ; you will also need to make changes to your /etc/syslog.conf before CDRs will 9 | ; be written to syslog. 10 | ; 11 | ; As an example, you can add the following to /etc/syslog.conf: 12 | ; 13 | ; local4.info /var/log/asterisk-cdr.log 14 | ; 15 | ; And then instruct syslogd to re-read the configuration file by sending it a 16 | ; HUP signal. On Linux this can be done like this: 17 | ; 18 | ; kill -HUP `cat /var/run/syslogd.pid` 19 | ; 20 | ; Finally, you will need to uncomment the [cdr-simple] section below, and restart 21 | ; Asterisk. When calls are placed, you should start seeing records appear in 22 | ; /var/log/asterisk-cdr.log. 23 | 24 | [general] 25 | ; Facility 26 | ; 27 | ; The 'facility' keyword specifies the syslog facility to use when writing out 28 | ; CDRs. 29 | ; 30 | ; Accepted values: One of the following: 31 | ; user, local0, local1, local2, local3, local4, local5, local6 32 | ; and local7. 33 | ; 34 | ; Note: Depending on your platform, the following may also be 35 | ; available: 36 | ; auth, authpriv, cron, daemon, ftp, kern, lpr, mail, 37 | ; news, syslog, and uucp. 38 | ; 39 | ; Default value: local4 40 | 41 | ;facility=local0 42 | 43 | ; Priority 44 | ; 45 | ; Use the 'priority' keyword to select which of the syslog priority levels to 46 | ; use when logging CDRs. 47 | ; 48 | ; Accepted values: One of the following: 49 | ; alert, crit, debug, emerg, err, info, notice, warning 50 | ; Default value: info 51 | 52 | ;priority=warn 53 | 54 | ; Note: The settings for 'facility' and 'priority' in the [general] section 55 | ; define the default values for all of the logging locations created 56 | ; below in separate sections. 57 | 58 | ;[cdr-master] 59 | ;facility = local5 60 | ;priority = debug 61 | 62 | ; Template 63 | ; 64 | ; The 'template' value allows you to specify a custom format for messages 65 | ; written to syslog. This is similar to how cdr_custom is configured. 66 | ; 67 | ; Allowed values: A diaplan style string. 68 | ; Default value: None, this is required field. 69 | ; 70 | ; Note: Because of the way substitution is done, the only meaningful values 71 | ; available when the record is logged are those available via the CDR() 72 | ; dialplan function. All other channel variables will be unavailable. 73 | 74 | ;template = "${CDR(clid)}","${CDR(src)}","${CDR(dst)}","${CDR(dcontext)}","${CDR(channel)}","${CDR(dstchannel)}","${CDR(lastapp)}","${CDR(lastdata)}","${CDR(start)}","${CDR(answer)}","${CDR(end)}","${CDR(duration)}","${CDR(billsec)}","${CDR(disposition)}","${CDR(amaflags)}","${CDR(accountcode)}","${CDR(uniqueid)}","${CDR(userfield)}" 75 | 76 | ; High Resolution Time for billsec and duration fields 77 | ;template = "${CDR(clid)}","${CDR(src)}","${CDR(dst)}","${CDR(dcontext)}","${CDR(channel)}","${CDR(dstchannel)}","${CDR(lastapp)}","${CDR(lastdata)}","${CDR(start)}","${CDR(answer)}","${CDR(end)}","${CDR(duration,f)}","${CDR(billsec,f)}","${CDR(disposition)}","${CDR(amaflags)}","${CDR(accountcode)}","${CDR(uniqueid)}","${CDR(userfield)}" 78 | ;[cdr-simple] 79 | 80 | ; Since we don't specify a facility or priority for this logging location, the 81 | ; records will use the defaults specified in the [general] section. 82 | 83 | ;template = "We received a call from ${CDR(src)}" 84 | -------------------------------------------------------------------------------- /asterisk/extconfig.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Static and realtime external configuration 3 | ; engine configuration 4 | ; 5 | ; See https://wiki.asterisk.org/wiki/display/AST/Realtime+Database+Configuration 6 | ; for basic table formatting information. 7 | ; 8 | [settings] 9 | ; 10 | ; Static configuration files: 11 | ; 12 | ; file.conf => driver,database[,table[,priority]] 13 | ; 14 | ; maps a particular configuration file to the given 15 | ; database driver, database and table (or uses the 16 | ; name of the file as the table if not specified) 17 | ; 18 | ;uncomment to load queues.conf via the odbc engine. 19 | ; 20 | ;queues.conf => odbc,asterisk,ast_config 21 | ;extensions.conf => sqlite,asterisk,ast_config 22 | ; 23 | ; The following files CANNOT be loaded from Realtime storage: 24 | ; asterisk.conf 25 | ; extconfig.conf (this file) 26 | ; logger.conf 27 | ; 28 | ; Additionally, the following files cannot be loaded from 29 | ; Realtime storage unless the storage driver is loaded 30 | ; early using 'preload' statements in modules.conf: 31 | ; manager.conf 32 | ; cdr.conf 33 | ; rtp.conf 34 | ; 35 | ; 36 | ; Realtime configuration engine 37 | ; 38 | ; maps a particular family of realtime 39 | ; configuration to a given database driver, 40 | ; database and table (or uses the name of 41 | ; the family if the table is not specified 42 | ; 43 | ;example => odbc,asterisk,alttable,1 44 | ;example => mysql,asterisk,alttable,2 45 | ;example2 => ldap,"dc=oxymium,dc=net",example2 46 | ; 47 | ; Additionally, priorities are now supported for use as failover methods 48 | ; for retrieving realtime data. If one connection fails to retrieve any 49 | ; information, the next sequential priority will be tried next. This 50 | ; especially works well with ODBC connections, since res_odbc now caches 51 | ; when connection failures occur and prevents immediately retrying those 52 | ; connections until after a specified timeout. Note: priorities must 53 | ; start at 1 and be sequential (i.e. if you have only priorities 1, 2, 54 | ; and 4, then 4 will be ignored, because there is no 3). 55 | ; 56 | ; 57 | ; Possible driver backends: 58 | ; 59 | ; "odbc" is shown in the examples below, but is not the only valid realtime 60 | ; engine. Here are several of the possible options: 61 | ; odbc ... res_config_odbc 62 | ; sqlite ... res_config_sqlite 63 | ; pgsql ... res_config_pgsql 64 | ; curl ... res_config_curl 65 | ; ldap ... res_config_ldap 66 | ; mysql ... res_config_mysql (available via add-ons in menuselect) 67 | ; 68 | ; Note: The res_config_pgsql and res_config_sqlite backends configure the 69 | ; database used in their respective configuration files and ignore the 70 | ; database name configured in this file. 71 | ; 72 | ;iaxusers => odbc,asterisk 73 | ;iaxpeers => odbc,asterisk 74 | ;sippeers => odbc,asterisk 75 | ;sipregs => odbc,asterisk ; (avoid sipregs if possible, e.g. by using a view) 76 | ;voicemail => odbc,asterisk 77 | ;extensions => odbc,asterisk 78 | ;meetme => mysql,general 79 | ;queues => odbc,asterisk 80 | ;queue_members => odbc,asterisk 81 | ;musiconhold => mysql,general 82 | ;queue_log => mysql,general 83 | ; 84 | ; 85 | ; While most dynamic realtime engines are automatically used when defined in 86 | ; this file, 'extensions', distinctively, is not. To activate dynamic realtime 87 | ; extensions, you must turn them on in each respective context within 88 | ; extensions.conf with a switch statement. The syntax is: 89 | ; switch => Realtime/[[db_context@]tablename]/ 90 | ; The only option available currently is the 'p' option, which disallows 91 | ; extension pattern queries to the database. If you have no patterns defined 92 | ; in a particular context, this will save quite a bit of CPU time. However, 93 | ; note that using dynamic realtime extensions is not recommended anymore as a 94 | ; best practice; instead, you should consider writing a static dialplan with 95 | ; proper data abstraction via a tool like func_odbc. 96 | 97 | -------------------------------------------------------------------------------- /asterisk/followme.conf: -------------------------------------------------------------------------------- 1 | ; Find-Me / Follow-Me Configuration File 2 | [general] 3 | ; 4 | featuredigittimeout=>5000 5 | ; The number of ms to wait for a digit input for the callee on whether to take the call or 6 | ; not before we consider them "done" entering digits. 7 | ; 8 | takecall=>1 9 | ; The global default keypress for the callee to take taking the current call. This can be 10 | ; a single digit or multiple digits. Default is "1". 11 | ; 12 | declinecall=>2 13 | ; The global default keypress for the callee to decline taking the current call. This can 14 | ; be a single digit or multiple digits. Default is "2". 15 | ; 16 | call_from_prompt=>followme/call-from 17 | ; The global default for the 'Incoming call from' message. 18 | ; 19 | norecording_prompt=>followme/no-recording 20 | ; The global default for the 'You have an incoming call' message when the caller elects 21 | ; not to leave their name or the option isn't set for them to do so. 22 | ; 23 | options_prompt=>followme/options 24 | ; The global default for the 'Press 1 to accept this call or press 2 to decline it' message. 25 | ; 26 | pls_hold_prompt=>followme/pls-hold-while-try 27 | ; The global default for 'Please hold while we try and connect your call' message. 28 | ; 29 | status_prompt=>followme/status 30 | ; The global default for 'The party you're calling isn't at their desk' message. 31 | ; 32 | sorry_prompt=>followme/sorry 33 | ; The global default for 'I'm sorry, but we were unable to locate your party' message. 34 | ; 35 | ; 36 | [default] 37 | musicclass=>default 38 | ; The moh class that should be used for the caller while they are waiting to be connected. 39 | context=>default 40 | ; The context to dial the numbers from 41 | number=>01233456,25 42 | ; The a follow-me number to call. The format is: 43 | ; number=> [, [, ] ] 44 | ; You can specify as many of these numbers as you like. They will be dialed in the 45 | ; order that you specify them in the config file OR as specified with the order field 46 | ; on the number prompt. As you can see from the example, forked dialing of multiple 47 | ; numbers in the same step is supported with this application if you'd like to dial 48 | ; multiple numbers in the same followme step. 49 | ; It's also important to note that the timeout value is not the same 50 | ; as the timeout value you would use in app_dial. This timeout value is the amount of 51 | ; time allowed between the time the dialing step starts and the callee makes a choice 52 | ; on whether to take the call or not. That being the case, you may want to account for 53 | ; this time, and make this timeout longer than a timeout you might specify in app_dial. 54 | takecall=>1 55 | ; The keypress for the callee to take taking the current call. This can be 56 | ; a single digit or multiple digits. Default is the global default. 57 | ; 58 | declinecall=>2 59 | ; The keypress for the callee to decline taking the current call. This can 60 | ; be a single digit or multiple digits. Default is the global default. 61 | ; 62 | call_from_prompt=>followme/call-from 63 | ; The 'Incoming call from' message prompt. Default is the global default. 64 | ; 65 | norecording_prompt=>followme/no-recording 66 | ; The 'You have an incoming call' message prompt when the caller elects 67 | ; not to leave their name or the option isn't set for them to do so. Default 68 | ; is the global default. 69 | ; 70 | options_prompt=>followme/options 71 | ; The 'Press 1 to accept this call or press 2 to decline it' message prompt. 72 | ; Default is the global default. 73 | ; 74 | pls_hold_prompt=>followme/pls-hold-while-try 75 | ; The 'Please hold while we try and connect your call' message prompt. 76 | ; Default is the global default. 77 | ; 78 | status_prompt=>followme/status 79 | ; The 'The party you're calling isn't at their desk' message prompt. 80 | ; Default is the global default. 81 | ; 82 | sorry_prompt=>followme/sorry 83 | ; The 'I'm sorry, but we were unable to locate your party' message prompt. Default 84 | ; is the global default. 85 | 86 | 87 | -------------------------------------------------------------------------------- /asterisk/asterisk.adsi: -------------------------------------------------------------------------------- 1 | ; 2 | ; Asterisk default ADSI script 3 | ; 4 | ; 5 | ; Begin with the preamble requirements 6 | ; 7 | DESCRIPTION "Asterisk PBX" ; Name of vendor 8 | VERSION 0x00 ; Version of stuff 9 | ;SECURITY "_AST" ; Security code 10 | SECURITY 0X9BDBF7AC ; Security code 11 | FDN 0x0000000F ; Descriptor number 12 | 13 | ; 14 | ; Flags 15 | ; 16 | FLAG "nocallwaiting" 17 | 18 | ; 19 | ; Predefined strings 20 | ; 21 | DISPLAY "titles" IS "** Asterisk PBX **" 22 | DISPLAY "talkingto" IS "Call active." JUSTIFY LEFT 23 | DISPLAY "callname" IS "$Call1p" JUSTIFY LEFT 24 | DISPLAY "callnum" IS "$Call1s" JUSTIFY LEFT 25 | DISPLAY "incoming" IS "Incoming call!" JUSTIFY LEFT 26 | DISPLAY "ringing" IS "Calling... " JUSTIFY LEFT 27 | DISPLAY "callended" IS "Call ended." JUSTIFY LEFT 28 | DISPLAY "missedcall" IS "Missed call." JUSTIFY LEFT 29 | DISPLAY "busy" IS "Busy." JUSTIFY LEFT 30 | DISPLAY "reorder" IS "Reorder." JUSTIFY LEFT 31 | DISPLAY "cwdisabled" IS "Callwait disabled" 32 | DISPLAY "empty" IS "asdf" 33 | 34 | ; 35 | ; Begin soft key definitions 36 | ; 37 | KEY "callfwd" IS "CallFwd" OR "Call Forward" 38 | OFFHOOK 39 | VOICEMODE 40 | WAITDIALTONE 41 | SENDDTMF "*60" 42 | GOTO "offHook" 43 | ENDKEY 44 | 45 | KEY "vmail_OH" IS "VMail" OR "Voicemail" 46 | OFFHOOK 47 | VOICEMODE 48 | WAITDIALTONE 49 | SENDDTMF "8500" 50 | ENDKEY 51 | 52 | KEY "vmail" IS "VMail" OR "Voicemail" 53 | SENDDTMF "8500" 54 | ENDKEY 55 | 56 | KEY "backspace" IS "BackSpc" OR "Backspace" 57 | BACKSPACE 58 | ENDKEY 59 | 60 | KEY "cwdisable" IS "CWDsble" OR "Disable Call Wait" 61 | SENDDTMF "*70" 62 | SETFLAG "nocallwaiting" 63 | SHOWDISPLAY "cwdisabled" AT 4 64 | TIMERCLEAR 65 | TIMERSTART 1 66 | ENDKEY 67 | 68 | KEY "cidblock" IS "CIDBlk" OR "Block Callerid" 69 | SENDDTMF "*67" 70 | SETFLAG "nocallwaiting" 71 | ENDKEY 72 | 73 | ; 74 | ; Begin main subroutine 75 | ; 76 | 77 | SUB "main" IS 78 | IFEVENT NEARANSWER THEN 79 | CLEAR 80 | SHOWDISPLAY "titles" AT 1 NOUPDATE 81 | SHOWDISPLAY "talkingto" AT 2 NOUPDATE 82 | SHOWDISPLAY "callname" AT 3 83 | SHOWDISPLAY "callnum" AT 4 84 | GOTO "stableCall" 85 | ENDIF 86 | IFEVENT OFFHOOK THEN 87 | CLEAR 88 | CLEARFLAG "nocallwaiting" 89 | CLEARDISPLAY 90 | SHOWDISPLAY "titles" AT 1 91 | SHOWKEYS "vmail" 92 | SHOWKEYS "cidblock" 93 | SHOWKEYS "cwdisable" UNLESS "nocallwaiting" 94 | GOTO "offHook" 95 | ENDIF 96 | IFEVENT IDLE THEN 97 | CLEAR 98 | SHOWDISPLAY "titles" AT 1 99 | SHOWKEYS "vmail_OH" 100 | ENDIF 101 | IFEVENT CALLERID THEN 102 | CLEAR 103 | ; SHOWDISPLAY "titles" AT 1 NOUPDATE 104 | ; SHOWDISPLAY "incoming" AT 2 NOUPDATE 105 | SHOWDISPLAY "callname" AT 3 NOUPDATE 106 | SHOWDISPLAY "callnum" AT 4 107 | ENDIF 108 | IFEVENT RING THEN 109 | CLEAR 110 | SHOWDISPLAY "titles" AT 1 NOUPDATE 111 | SHOWDISPLAY "incoming" AT 2 112 | ENDIF 113 | IFEVENT ENDOFRING THEN 114 | SHOWDISPLAY "missedcall" AT 2 115 | CLEAR 116 | SHOWDISPLAY "titles" AT 1 117 | SHOWKEYS "vmail_OH" 118 | ENDIF 119 | IFEVENT TIMER THEN 120 | CLEAR 121 | SHOWDISPLAY "empty" AT 4 122 | ENDIF 123 | ENDSUB 124 | 125 | SUB "offHook" IS 126 | IFEVENT FARRING THEN 127 | CLEAR 128 | SHOWDISPLAY "titles" AT 1 NOUPDATE 129 | SHOWDISPLAY "ringing" AT 2 NOUPDATE 130 | SHOWDISPLAY "callname" at 3 NOUPDATE 131 | SHOWDISPLAY "callnum" at 4 132 | ENDIF 133 | IFEVENT FARANSWER THEN 134 | CLEAR 135 | SHOWDISPLAY "talkingto" AT 2 136 | GOTO "stableCall" 137 | ENDIF 138 | IFEVENT BUSY THEN 139 | CLEAR 140 | SHOWDISPLAY "titles" AT 1 NOUPDATE 141 | SHOWDISPLAY "busy" AT 2 NOUPDATE 142 | SHOWDISPLAY "callname" at 3 NOUPDATE 143 | SHOWDISPLAY "callnum" at 4 144 | ENDIF 145 | IFEVENT REORDER THEN 146 | CLEAR 147 | SHOWDISPLAY "titles" AT 1 NOUPDATE 148 | SHOWDISPLAY "reorder" AT 2 NOUPDATE 149 | SHOWDISPLAY "callname" at 3 NOUPDATE 150 | SHOWDISPLAY "callnum" at 4 151 | ENDIF 152 | ENDSUB 153 | 154 | SUB "stableCall" IS 155 | IFEVENT REORDER THEN 156 | SHOWDISPLAY "callended" AT 2 157 | ENDIF 158 | ENDSUB 159 | 160 | -------------------------------------------------------------------------------- /asterisk/asterisk.conf: -------------------------------------------------------------------------------- 1 | [directories](!) 2 | astetcdir => /etc/asterisk 3 | astmoddir => /usr/lib64/asterisk/modules 4 | astvarlibdir => /usr/share/asterisk 5 | astdbdir => /var/spool/asterisk 6 | astkeydir => /var/lib/asterisk 7 | astdatadir => /usr/share/asterisk 8 | astagidir => /usr/share/asterisk/agi-bin 9 | astspooldir => /var/spool/asterisk 10 | astrundir => /var/run/asterisk 11 | astlogdir => /var/log/asterisk 12 | 13 | [options] 14 | ;verbose = 3 15 | ;debug = 3 16 | ;alwaysfork = yes ; Same as -F at startup. 17 | ;nofork = yes ; Same as -f at startup. 18 | ;quiet = yes ; Same as -q at startup. 19 | ;timestamp = yes ; Same as -T at startup. 20 | ;execincludes = yes ; Support #exec in config files. 21 | ;console = yes ; Run as console (same as -c at startup). 22 | ;highpriority = yes ; Run realtime priority (same as -p at 23 | ; startup). 24 | ;initcrypto = yes ; Initialize crypto keys (same as -i at 25 | ; startup). 26 | ;nocolor = yes ; Disable console colors. 27 | ;dontwarn = yes ; Disable some warnings. 28 | ;dumpcore = yes ; Dump core on crash (same as -g at startup). 29 | ;languageprefix = yes ; Use the new sound prefix path syntax. 30 | ;internal_timing = yes 31 | ;systemname = my_system_name ; Prefix uniqueid with a system name for 32 | ; Global uniqueness issues. 33 | ;autosystemname = yes ; Automatically set systemname to hostname, 34 | ; uses 'localhost' on failure, or systemname if 35 | ; set. 36 | ;maxcalls = 10 ; Maximum amount of calls allowed. 37 | ;maxload = 0.9 ; Asterisk stops accepting new calls if the 38 | ; load average exceed this limit. 39 | ;maxfiles = 1000 ; Maximum amount of openfiles. 40 | ;minmemfree = 1 ; In MBs, Asterisk stops accepting new calls if 41 | ; the amount of free memory falls below this 42 | ; watermark. 43 | ;cache_record_files = yes ; Cache recorded sound files to another 44 | ; directory during recording. 45 | ;record_cache_dir = /tmp ; Specify cache directory (used in conjunction 46 | ; with cache_record_files). 47 | ;transmit_silence = yes ; Transmit silence while a channel is in a 48 | ; waiting state, a recording only state, or 49 | ; when DTMF is being generated. Note that the 50 | ; silence internally is generated in raw signed 51 | ; linear format. This means that it must be 52 | ; transcoded into the native format of the 53 | ; channel before it can be sent to the device. 54 | ; It is for this reason that this is optional, 55 | ; as it may result in requiring a temporary 56 | ; codec translation path for a channel that may 57 | ; not otherwise require one. 58 | ;transcode_via_sln = yes ; Build transcode paths via SLINEAR, instead of 59 | ; directly. 60 | ;runuser = asterisk ; The user to run as. 61 | ;rungroup = asterisk ; The group to run as. 62 | ;lightbackground = yes ; If your terminal is set for a light-colored 63 | ; background. 64 | ;forceblackbackground = yes ; Force the background of the terminal to be 65 | ; black, in order for terminal colors to show 66 | ; up properly. 67 | ;defaultlanguage = en ; Default language 68 | documentation_language = en_US ; Set the language you want documentation 69 | ; displayed in. Value is in the same format as 70 | ; locale names. 71 | ;hideconnect = yes ; Hide messages displayed when a remote console 72 | ; connects and disconnects. 73 | ;lockconfdir = no ; Protect the directory containing the 74 | ; configuration files (/etc/asterisk) with a 75 | ; lock. 76 | ;live_dangerously = no ; Enable the execution of 'dangerous' dialplan 77 | ; functions from external sources (AMI, 78 | ; etc.) These functions (such as SHELL) are 79 | ; considered dangerous because they can allow 80 | ; privilege escalation. 81 | ; Default yes, for backward compatability. 82 | 83 | ; Changing the following lines may compromise your security. 84 | ;[files] 85 | ;astctlpermissions = 0660 86 | ;astctlowner = root 87 | ;astctlgroup = apache 88 | ;astctl = asterisk.ctl 89 | 90 | [compat] 91 | pbx_realtime=1.6 92 | res_agi=1.6 93 | app_set=1.6 94 | -------------------------------------------------------------------------------- /asterisk/osp.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Open Settlement Protocol Sample Configuration File 3 | ; 4 | ; This file contains configuration of OSP server providers that are used by the 5 | ; Asterisk OSP module. The section "general" is reserved for global options. 6 | ; All other sections describe specific OSP Providers. The provider "default" 7 | ; is used when no provider is otherwise specified. 8 | ; 9 | ; The "servicepoint" and "source" parameters must be configured. For most 10 | ; implementations the other parameters in this file can be left unchanged. 11 | ; 12 | [general] 13 | ; 14 | ; Enable cryptographic acceleration hardware. 15 | ; The default value is no. 16 | ; 17 | ;accelerate=no 18 | ; 19 | ; Enable security features. 20 | ; If security features are disabled, Asterisk cannot validate signed tokens and 21 | ; all certificate file name parameters are ignored. 22 | ; The default value is no. 23 | ; 24 | ;securityfeatures=no 25 | ; 26 | ; Defines the status of tokens that Asterisk will validate. 27 | ; 0 - signed tokens only 28 | ; 1 - unsigned tokens only 29 | ; 2 - both signed and unsigned 30 | ; The default value is 0, i.e. the Asterisk will only validate signed tokens. 31 | ; If securityfeatures are disabled, Asterisk cannot validate signed tokens. 32 | ; 33 | ;tokenformat=0 34 | ; 35 | ;[default] 36 | ; 37 | ; List all service points (OSP servers) for this provider. 38 | ; Use either domain name or IP address. Most OSP servers use port 5045. 39 | ; 40 | ;servicepoint=http://osptestserver.transnexus.com:5045/osp 41 | ; 42 | ; Define the "source" device for requesting OSP authorization. 43 | ; This value is usually the domain name or IP address of the the Asterisk server. 44 | ; 45 | ;source=domain name or [IP address in brackets] 46 | ; 47 | ; Define path and file name of crypto files. 48 | ; The default path for crypto file is /usr/share/asterisk/keys. If no path is 49 | ; defined, crypto files will in /usr/share/asterisk/keys directory. 50 | ; 51 | ; Specify the private key file name. 52 | ; If this parameter is unspecified or not present, the default name will be the 53 | ; osp.conf section name followed by "-privatekey.pem" (for example: 54 | ; default-privatekey.pem) 55 | ; If securityfeatures are disabled, this parameter is ignored. 56 | ; 57 | ;privatekey=pkey.pem 58 | ; 59 | ; Specify the local certificate file. 60 | ; If this parameter is unspecified or not present, the default name will be the 61 | ; osp.conf section name followed by "- localcert.pem " (for example: 62 | ; default-localcert.pem) 63 | ; If securityfeatures are disabled, this parameter is ignored. 64 | ; 65 | ;localcert=localcert.pem 66 | ; 67 | ; Specify one or more Certificate Authority key file names. If none are listed, 68 | ; a single Certificate Authority key file name is added with the default name of 69 | ; the osp.conf section name followed by "-cacert_0.pem " (for example: 70 | ; default-cacert_0.pem) 71 | ; If securityfeatures are disabled, this parameter is ignored. 72 | ; 73 | ;cacert=cacert_0.pem 74 | ; 75 | ; Configure parameters for OSP communication between Asterisk OSP client and OSP 76 | ; servers. 77 | ; 78 | ; maxconnections: Max number of simultaneous connections to the provider OSP 79 | ; server (default=20) 80 | ; retrydelay: Extra delay between retries (default=0) 81 | ; retrylimit: Max number of retries before giving up (default=2) 82 | ; timeout: Timeout for response in milliseconds (default=500) 83 | ; 84 | ;maxconnections=20 85 | ;retrydelay=0 86 | ;retrylimit=2 87 | ;timeout=500 88 | ; 89 | ; Set the authentication policy. 90 | ; 0 - NO - Accept all calls. 91 | ; 1 - YES - Accept calls with valid token or no token. Block calls with 92 | ; invalid token. 93 | ; 2 - EXCLUSIVE - Accept calls with valid token. Block calls with invalid token 94 | ; or no token. 95 | ; Default is 1, 96 | ; If securityfeatures are disabled, Asterisk cannot validate signed tokens. 97 | ; 98 | ;authpolicy=1 99 | ; 100 | ; Set the default destination protocol. The OSP module supports SIP, H323, and 101 | ; IAX protocols. The default protocol is set to SIP. 102 | ; 103 | ;defaultprotocol=SIP 104 | ; 105 | ; Set the work mode. 106 | ; 0 - Direct 107 | ; 1 - Indirect 108 | ; Default is 0, 109 | ; 110 | ;workmode=0 111 | ; 112 | ; Set the service type. 113 | ; 0 - Normal voice service 114 | ; 1 - Ported number query service 115 | ; Default is 0, 116 | ; 117 | ;servicetype=0 118 | -------------------------------------------------------------------------------- /asterisk/cel.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Asterisk Channel Event Logging (CEL) 3 | ; 4 | 5 | ; Channel Event Logging is a mechanism to provide fine-grained event information 6 | ; that can be used to generate billing information. Such event information can 7 | ; be recorded to various backend modules. 8 | ; 9 | 10 | [general] 11 | 12 | ; CEL Activation 13 | ; 14 | ; Use the 'enable' keyword to turn CEL on or off. 15 | ; 16 | ; Accepted values: yes and no 17 | ; Default value: no 18 | 19 | ;enable=yes 20 | 21 | ; Application Tracking 22 | ; 23 | ; Use the 'apps' keyword to specify the list of applications for which you want 24 | ; to receive CEL events. This is a comma separated list of Asterisk dialplan 25 | ; applications, such as Dial, Queue, and Park. 26 | ; 27 | ; Accepted values: A comma separated list of Asterisk dialplan applications 28 | ; Default value: none 29 | ; 30 | ; Note: You may also use 'all' which will result in CEL events being reported 31 | ; for all Asterisk applications. This may affect Asterisk's performance 32 | ; significantly. 33 | 34 | apps=dial,park 35 | 36 | ; Event Tracking 37 | ; 38 | ; Use the 'events' keyword to specify the list of events which you want to be 39 | ; raised when they occur. This is a comma separated list of the values in the 40 | ; table below. 41 | ; 42 | ; Accepted values: A comma separated list of one or more of the following: 43 | ; ALL -- Generate entries on all events 44 | ; CHAN_START -- The time a channel was created 45 | ; CHAN_END -- The time a channel was terminated 46 | ; ANSWER -- The time a channel was answered (ie, phone taken off-hook) 47 | ; HANGUP -- The time at which a hangup occurred 48 | ; CONF_ENTER -- The time a channel was connected into a conference room 49 | ; CONF_EXIT -- The time a channel was removed from a conference room 50 | ; CONF_START -- The time the first person enters a conference room 51 | ; CONF_END -- The time the last person left a conference room (and 52 | ; turned out the lights?) 53 | ; APP_START -- The time a tracked application was started 54 | ; APP_END -- the time a tracked application ended 55 | ; PARK_START -- The time a call was parked 56 | ; PARK_END -- Unpark event 57 | ; BRIDGE_START -- The time a bridge is started 58 | ; BRIDGE_END -- The time a bridge is ended 59 | ; BRIDGE_UPDATE -- This is a replacement channel (Masquerade) 60 | ; 3WAY_START -- When a 3-way conference starts (usually via attended transfer) 61 | ; 3WAY_END -- When one or all exit a 3-way conference 62 | ; BLINDTRANSFER -- When a blind transfer is initiated 63 | ; ATTENDEDTRANSFER -- When an attended transfer is initiated 64 | ; TRANSFER -- Generic transfer initiated; not used yet...? 65 | ; PICKUP -- This channel picked up the peer channel 66 | ; FORWARD -- This channel is being forwarded somewhere else 67 | ; HOOKFLASH -- So far, when a hookflash event occurs on a DAHDI 68 | ; interface 69 | ; LINKEDID_END -- The last channel with the given linkedid is retired 70 | ; USER_DEFINED -- Triggered from the dialplan, and has a name given by the 71 | ; user 72 | ; 73 | ; Default value: none 74 | ; (Track no events) 75 | 76 | events=APP_START,CHAN_START,CHAN_END,ANSWER,HANGUP,BRIDGE_START,BRIDGE_END 77 | 78 | ; Date Format 79 | ; 80 | ; Use the 'dateformat' keyword to specify the date format used when CEL events 81 | ; are raised. 82 | ; 83 | ; Accepted values: A strftime format string (see man strftime) 84 | ; 85 | ; Example: "%F %T" 86 | ; -> This gives the date and time in the format "2009-06-23 17:02:35" 87 | ; 88 | ; If this option is not specified, the default format is "." 89 | ; since epoch. The microseconds field will always be 6 digits in length, meaning it 90 | ; may have leading zeros. 91 | ; 92 | ;dateformat = %F %T 93 | 94 | ; 95 | ; Asterisk Manager Interface (AMI) CEL Backend 96 | ; 97 | [manager] 98 | 99 | ; AMI Backend Activation 100 | ; 101 | ; Use the 'enable' keyword to turn CEL logging to the Asterisk Manager Interface 102 | ; on or off. 103 | ; 104 | ; Accepted values: yes and no 105 | ; Default value: no 106 | ;enabled=yes 107 | 108 | ; 109 | ; RADIUS CEL Backend 110 | ; 111 | [radius] 112 | ; 113 | ; Log date/time in GMT 114 | ;usegmtime=yes 115 | ; 116 | ; Set this to the location of the radiusclient-ng configuration file 117 | ; The default is /etc/radiusclient-ng/radiusclient.conf 118 | ;radiuscfg => /usr/local/etc/radiusclient-ng/radiusclient.conf 119 | ; 120 | -------------------------------------------------------------------------------- /asterisk/logger.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Logging Configuration 3 | ; 4 | ; In this file, you configure logging to files or to 5 | ; the syslog system. 6 | ; 7 | ; "logger reload" at the CLI will reload configuration 8 | ; of the logging system. 9 | 10 | [general] 11 | ; 12 | ; Customize the display of debug message time stamps 13 | ; this example is the ISO 8601 date format (yyyy-mm-dd HH:MM:SS) 14 | ; 15 | ; see strftime(3) Linux manual for format specifiers. Note that there is also 16 | ; a fractional second parameter which may be used in this field. Use %1q 17 | ; for tenths, %2q for hundredths, etc. 18 | ; 19 | ;dateformat=%F %T ; ISO 8601 date format 20 | ;dateformat=%F %T.%3q ; with milliseconds 21 | ; 22 | ; This appends the hostname to the name of the log files. 23 | ;appendhostname = yes 24 | ; 25 | ; This determines whether or not we log queue events to a file 26 | ; (defaults to yes). 27 | ;queue_log = no 28 | ; 29 | ; Determines whether the queue_log always goes to a file, even 30 | ; when a realtime backend is present (defaults to no). 31 | ;queue_log_to_file = yes 32 | ; 33 | ; Set the queue_log filename 34 | ; (defaults to queue_log) 35 | ;queue_log_name = queue_log 36 | ; 37 | ; Log rotation strategy: 38 | ; sequential: Rename archived logs in order, such that the newest 39 | ; has the highest sequence number [default]. When 40 | ; exec_after_rotate is set, ${filename} will specify 41 | ; the new archived logfile. 42 | ; rotate: Rotate all the old files, such that the oldest has the 43 | ; highest sequence number [this is the expected behavior 44 | ; for Unix administrators]. When exec_after_rotate is 45 | ; set, ${filename} will specify the original root filename. 46 | ; timestamp: Rename the logfiles using a timestamp instead of a 47 | ; sequence number when "logger rotate" is executed. 48 | ; When exec_after_rotate is set, ${filename} will 49 | ; specify the new archived logfile. 50 | ;rotatestrategy = rotate 51 | ; 52 | ; Run a system command after rotating the files. This is mainly 53 | ; useful for rotatestrategy=rotate. The example allows the last 54 | ; two archive files to remain uncompressed, but after that point, 55 | ; they are compressed on disk. 56 | ; 57 | ; exec_after_rotate=gzip -9 ${filename}.2 58 | ; 59 | ; 60 | ; For each file, specify what to log. 61 | ; 62 | ; For console logging, you set options at start of 63 | ; Asterisk with -v for verbose and -d for debug 64 | ; See 'asterisk -h' for more information. 65 | ; 66 | ; Directory for log files is configures in asterisk.conf 67 | ; option astlogdir 68 | ; 69 | [logfiles] 70 | ; 71 | ; Format is "filename" and then "levels" of debugging to be included: 72 | ; debug 73 | ; notice 74 | ; warning 75 | ; error 76 | ; verbose 77 | ; dtmf 78 | ; fax 79 | ; 80 | ; Special filename "console" represents the system console 81 | ; 82 | ; Filenames can either be relative to the standard Asterisk log directory 83 | ; (see 'astlogdir' in asterisk.conf), or absolute paths that begin with 84 | ; '/'. 85 | ; 86 | ; Special level name "*" means all levels, even dynamic levels registered 87 | ; by modules after the logger has been initialized (this means that loading 88 | ; and unloading modules that create/remove dynamic logger levels will result 89 | ; in these levels being included on filenames that have a level name of "*", 90 | ; without any need to perform a 'logger reload' or similar operation). Note 91 | ; that there is no value in specifying both "*" and specific level names for 92 | ; a filename; the "*" level means all levels, and the remaining level names 93 | ; will be ignored. 94 | ; 95 | ; We highly recommend that you DO NOT turn on debug mode if you are simply 96 | ; running a production system. Debug mode turns on a LOT of extra messages, 97 | ; most of which you are unlikely to understand without an understanding of 98 | ; the underlying code. Do NOT report debug messages as code issues, unless 99 | ; you have a specific issue that you are attempting to debug. They are 100 | ; messages for just that -- debugging -- and do not rise to the level of 101 | ; something that merit your attention as an Asterisk administrator. Debug 102 | ; messages are also very verbose and can and do fill up logfiles quickly; 103 | ; this is another reason not to have debug mode on a production system unless 104 | ; you are in the process of debugging a specific issue. 105 | ; 106 | ;debug => debug 107 | console => notice,warning,error 108 | ;console => notice,warning,error,debug 109 | messages => notice,warning,error 110 | ;full => notice,warning,error,debug,verbose,dtmf,fax 111 | 112 | ;syslog keyword : This special keyword logs to syslog facility 113 | ; 114 | ;syslog.local0 => notice,warning,error 115 | ; 116 | -------------------------------------------------------------------------------- /asterisk/mgcp.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; MGCP Configuration for Asterisk 3 | ; 4 | [general] 5 | ;port = 2427 6 | ;bindaddr = 0.0.0.0 7 | 8 | ; See https://wiki.asterisk.org/wiki/display/AST/IP+Quality+of+Service for a description of these parameters. 9 | ;tos=cs3 ; Sets TOS for signaling packets. 10 | ;tos_audio=ef ; Sets TOS for RTP audio packets. 11 | ;cos=3 ; Sets 802.1p priority for signaling packets. 12 | ;cos_audio=5 ; Sets 802.1p priority for RTP audio packets. 13 | 14 | ;---------------------- DIGIT TIMEOUTS ---------------------------- 15 | firstdigittimeout = 30000 ; default 16000 = 16s 16 | gendigittimeout = 10000 ; default 8000 = 8s 17 | matchdigittimeout = 5000 ; defaults 3000 = 3s 18 | 19 | ;------------------------------ JITTER BUFFER CONFIGURATION -------------------------- 20 | ; jbenable = yes ; Enables the use of a jitterbuffer on the receiving side of a 21 | ; MGCP channel. Defaults to "no". An enabled jitterbuffer will 22 | ; be used only if the sending side can create and the receiving 23 | ; side can not accept jitter. The MGCP channel can accept jitter, 24 | ; thus an enabled jitterbuffer on the receive MGCP side will only 25 | ; be used if the sending side can create jitter and jbforce is 26 | ; also set to yes. 27 | 28 | ; jbforce = no ; Forces the use of a jitterbuffer on the receive side of a MGCP 29 | ; channel. Defaults to "no". 30 | 31 | ; jbmaxsize = 200 ; Max length of the jitterbuffer in milliseconds. 32 | 33 | ; jbresyncthreshold = 1000 ; Jump in the frame timestamps over which the jitterbuffer is 34 | ; resynchronized. Useful to improve the quality of the voice, with 35 | ; big jumps in/broken timestamps, usually sent from exotic devices 36 | ; and programs. Defaults to 1000. 37 | 38 | ; jbimpl = fixed ; Jitterbuffer implementation, used on the receiving side of a MGCP 39 | ; channel. Two implementations are currently available - "fixed" 40 | ; (with size always equals to jbmax-size) and "adaptive" (with 41 | ; variable size, actually the new jb of IAX2). Defaults to fixed. 42 | 43 | ; jbtargetextra = 40 ; This option only affects the jb when 'jbimpl = adaptive' is set. 44 | ; The option represents the number of milliseconds by which the new 45 | ; jitter buffer will pad its size. the default is 40, so without 46 | ; modification, the new jitter buffer will set its size to the jitter 47 | ; value plus 40 milliseconds. increasing this value may help if your 48 | ; network normally has low jitter, but occasionally has spikes. 49 | 50 | ; jblog = no ; Enables jitterbuffer frame logging. Defaults to "no". 51 | ;----------------------------------------------------------------------------------- 52 | 53 | ;[dlinkgw] 54 | ;host = 192.168.0.64 55 | ;context = default 56 | ;directmedia = no 57 | ;line => aaln/2 58 | ;line => aaln/1 59 | 60 | ;; The MGCP channel supports the following service codes: 61 | ;; # - Transfer 62 | ;; *67 - Calling Number Delivery Blocking 63 | ;; *70 - Cancel Call Waiting 64 | ;; *72 - Call Forwarding Activation 65 | ;; *73 - Call Forwarding Deactivation 66 | ;; *78 - Do Not Disturb Activation 67 | ;; *79 - Do Not Disturb Deactivation 68 | ;; *8 - Call pick-up 69 | ; 70 | ; known to work with Swissvoice IP10s 71 | ;[192.168.1.20] 72 | ;context=local 73 | ;host=192.168.1.20 74 | ;callerid = "John Doe" <123> 75 | ;callgroup=0 ; in the range from 0 to 63 76 | ;pickupgroup=0 ; in the range from 0 to 63 77 | ;nat=no 78 | ;threewaycalling=yes 79 | ;transfer=yes ; transfer requires threewaycalling=yes. Use FLASH to transfer 80 | ;callwaiting=yes ; this might be a cause of trouble for ip10s 81 | ;cancallforward=yes 82 | ;line => aaln/1 83 | ; 84 | 85 | ;[dph100] 86 | ; 87 | ; Supporting the DPH100M requires defining DLINK_BUGGY_FIRMWARE in 88 | ; chan_mgcp.c in addition to enabling the slowsequence mode due to 89 | ; bugs in the D-Link firmware 90 | ; 91 | ;context=local 92 | ;host=dynamic 93 | ;dtmfmode=none ; DTMF Mode can be 'none', 'rfc2833', or 'inband' or 94 | ; 'hybrid' which starts in none and moves to inband. Default is none. 95 | ;slowsequence=yes ; The DPH100M does not follow MGCP standards for sequencing 96 | ;line => aaln/1 97 | 98 | ; known to work with wave7optics FTTH LMGs 99 | ;[192.168.1.20] 100 | ;accountcode = 1000 ; record this in cdr as account identification for billing 101 | ;amaflags = billing ; record this in cdr as flagged for 'billing', 102 | ; 'documentation', or 'omit' 103 | ;context = local 104 | ;host = 192.168.1.20 105 | ;wcardep = aaln/* ; enables wildcard endpoint and sets it to 'aaln/*' 106 | ; another common format is '*' 107 | ;callerid = "Duane Cox" <123> ; now lets setup line 1 using per endpoint configuration... 108 | ;callwaiting = no 109 | ;callreturn = yes 110 | ;cancallforward = yes 111 | ;directmedia = no 112 | ;transfer = no 113 | ;dtmfmode = inband 114 | ;setvar=one=1 ; Set channel variables associated with this incoming line 115 | ;setvar=two=2 116 | ;line => aaln/1 ; now lets save this config to line1 aka aaln/1 117 | ;clearvars=all ; Reset list of variables back to none 118 | ;callerid = "Duane Cox" <456> ; now lets setup line 2 119 | ;callwaiting = no 120 | ;callreturn = yes 121 | ;cancallforward = yes 122 | ;directmedia = no 123 | ;transfer = no 124 | ;dtmfmode = inband 125 | ;line => aaln/2 ; now lets save this config to line2 aka aaln/2 126 | 127 | ; PacketCable 128 | ;[sbv5121e-mta.test.local] 129 | ;host = 10.0.1.3 130 | ;callwaiting = 1 131 | ;canreinvite = 1 132 | ;dtmfmode = rfc2833 133 | ;amaflags = BILLING 134 | ;ncs = yes ; Use NCS 1.0 signalling 135 | ;pktcgatealloc = yes ; Allocate DQOS gate on CMTS 136 | ;hangupongateremove = yes ; Hangup the channel if the CMTS close the gate 137 | ;callerid = 3622622225 138 | ;accountcode = test-3622622225 139 | ;line = aaln/1 140 | ;callerid = 3622622226 141 | ;accountcode = test-3622622226 142 | ;line = aaln/2 143 | -------------------------------------------------------------------------------- /asterisk/manager.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; AMI - The Asterisk Manager Interface 3 | ; 4 | ; Third party application call management support and PBX event supervision 5 | ; 6 | ; This configuration file is read every time someone logs in 7 | ; 8 | ; Use the "manager show commands" at the CLI to list available manager commands 9 | ; and their authorization levels. 10 | ; 11 | ; "manager show command " will show a help text. 12 | ; 13 | ; ---------------------------- SECURITY NOTE ------------------------------- 14 | ; Note that you should not enable the AMI on a public IP address. If needed, 15 | ; block this TCP port with iptables (or another FW software) and reach it 16 | ; with IPsec, SSH, or SSL vpn tunnel. You can also make the manager 17 | ; interface available over http/https if Asterisk's http server is enabled in 18 | ; http.conf and if both "enabled" and "webenabled" are set to yes in 19 | ; this file. Both default to no. httptimeout provides the maximum 20 | ; timeout in seconds before a web based session is discarded. The 21 | ; default is 60 seconds. 22 | ; 23 | [general] 24 | enabled = yes 25 | ;webenabled = yes 26 | 27 | port = 5038 28 | bindaddr = 0.0.0.0 29 | 30 | ; Parameters that control AMI over TLS. ("enabled" must be set too). 31 | ; You can open a connection to this socket with e.g. 32 | ; 33 | ; openssl s_client -connect my_host:5039 34 | ; 35 | ;tlsenable=no ; set to YES to enable it 36 | ;tlsbindaddr=0.0.0.0:5039 ; address and port to bind to, default to bindaddr and port 5039 37 | ;tlscertfile=/tmp/asterisk.pem ; path to the certificate. 38 | ;tlsprivatekey=/tmp/private.pem ; path to the private key, if no private given, 39 | ; if no tlsprivatekey is given, default is to search 40 | ; tlscertfile for private key. 41 | ;tlscipher= ; string specifying which SSL ciphers to use or not use 42 | ; 43 | ;allowmultiplelogin = yes ; IF set to no, rejects manager logins that are already in use. 44 | ; ; The default is yes. 45 | ; 46 | ;displayconnects = yes 47 | ; 48 | ; Add a Unix epoch timestamp to events (not action responses) 49 | ; 50 | ;timestampevents = yes 51 | 52 | ;brokeneventsaction = yes ; Restore previous behavior that caused the events 53 | ; action to not return a response in certain 54 | ; circumstances. Defaults to 'no'. 55 | 56 | ; 57 | ; Display certain channel variables every time a channel-oriented 58 | ; event is emitted: 59 | ; 60 | ;channelvars = var1,var2,var3 61 | 62 | ; debug = on ; enable some debugging info in AMI messages (default off). 63 | ; Also accessible through the "manager debug" CLI command. 64 | 65 | ; authtimeout specifies the maximum number of seconds a client has to 66 | ; authenticate. If the client does not authenticate beofre this timeout 67 | ; expires, the client will be disconnected. (default: 30 seconds) 68 | 69 | ;authtimeout = 30 70 | 71 | ; authlimit specifies the maximum number of unauthenticated sessions that will 72 | ; be allowed to connect at any given time. 73 | 74 | ;authlimit = 50 75 | 76 | ;httptimeout = 60 77 | ; a) httptimeout sets the Max-Age of the http cookie 78 | ; b) httptimeout is the amount of time the webserver waits 79 | ; on a action=waitevent request (actually its httptimeout-10) 80 | ; c) httptimeout is also the amount of time the webserver keeps 81 | ; a http session alive after completing a successful action 82 | 83 | 84 | ;[mark] 85 | ;secret = mysecret 86 | ;deny=0.0.0.0/0.0.0.0 87 | ;permit=209.16.236.73/255.255.255.0 88 | ; 89 | ;eventfilter=Event: Newchannel 90 | ;eventfilter=!Channel: DAHDI* 91 | ; The eventfilter option is used to whitelist or blacklist events per user to be 92 | ; reported with regular expressions and are allowed if both the regex matches 93 | ; and the user has read access set below. Filters are assumed to be for whitelisting 94 | ; unless preceeded by an exclamation point, which marks it as being black. 95 | ; Evaluation of the filters is as follows: 96 | ; - If no filters are configured all events are reported as normal. 97 | ; - If there are white filters only: implied black all filter processed first, 98 | ; then white filters. 99 | ; - If there are black filters only: implied white all filter processed first, 100 | ; then black filters. 101 | ; - If there are both white and black filters: implied black all filter processed 102 | ; first, then white filters, and lastly black filters. 103 | 104 | ; 105 | ; If the device connected via this user accepts input slowly, 106 | ; the timeout for writes to it can be increased to keep it 107 | ; from being disconnected (value is in milliseconds) 108 | ; 109 | ; writetimeout = 100 110 | ; 111 | ;displayconnects = yes ; Display on CLI user login/logoff 112 | ; 113 | ; Authorization for various classes 114 | ; 115 | ; Read authorization permits you to receive asynchronous events, in general. 116 | ; Write authorization permits you to send commands and get back responses. The 117 | ; following classes exist: 118 | ; 119 | ; all - All event classes below (including any we may have missed). 120 | ; system - General information about the system and ability to run system 121 | ; management commands, such as Shutdown, Restart, and Reload. 122 | ; call - Information about channels and ability to set information in a 123 | ; running channel. 124 | ; log - Logging information. Read-only. (Defined but not yet used.) 125 | ; verbose - Verbose information. Read-only. (Defined but not yet used.) 126 | ; agent - Information about queues and agents and ability to add queue 127 | ; members to a queue. 128 | ; user - Permission to send and receive UserEvent. 129 | ; config - Ability to read and write configuration files. 130 | ; command - Permission to run CLI commands. Write-only. 131 | ; dtmf - Receive DTMF events. Read-only. 132 | ; reporting - Ability to get information about the system. 133 | ; cdr - Output of cdr_manager, if loaded. Read-only. 134 | ; dialplan - Receive NewExten and VarSet events. Read-only. 135 | ; originate - Permission to originate new calls. Write-only. 136 | ; agi - Output AGI commands executed. Input AGI command to execute. 137 | ; cc - Call Completion events. Read-only. 138 | ; aoc - Permission to send Advice Of Charge messages and receive Advice 139 | ; - Of Charge events. 140 | ; test - Ability to read TestEvent notifications sent to the Asterisk Test 141 | ; Suite. Note that this is only enabled when the TEST_FRAMEWORK 142 | ; compiler flag is defined. 143 | ; 144 | ;read = system,call,log,verbose,agent,user,config,dtmf,reporting,cdr,dialplan 145 | ;write = system,call,agent,user,config,command,reporting,originate 146 | 147 | [admin] 148 | secret = secret5 149 | deny = 0.0.0.0/0.0.0.0 150 | permit = 127.0.0.1/255.255.255.255 151 | read = all,system,call,log,verbose,command,agent,user,config 152 | write = all,system,call,log,verbose,command,agent,user,config 153 | -------------------------------------------------------------------------------- /asterisk/vpb.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Voicetronix Voice Processing Board (VPB) telephony interface 3 | ; 4 | ; Configuration file 5 | ; 6 | 7 | [general] 8 | ; 9 | ; Total number of Voicetronix cards in this machine 10 | ; 11 | cards=0 12 | 13 | ; 14 | ; Which indication functions to use 15 | ; 1 = use Asterisk functions 16 | ; 0 = use VPB functions 17 | ; 18 | indication=1 19 | 20 | ; 21 | ; Echo Canceller suppression threshold 22 | ; 0 = no suppression threshold 23 | ; 2048 = -18dB 24 | ; 4096 = -24dB 25 | ; 26 | ;ecsuppthres=0 27 | 28 | ; 29 | ; Inter-digit delay timeout, used when collecting DTMF tones for dialling 30 | ; from a station port. Measured in milliseconds. 31 | ; 32 | dtmfidd=3000 33 | 34 | ; 35 | ; How to play DTMF tones 36 | ; any value = use Asterisk functions 37 | ; commented out = use VPB functions 38 | ; 39 | ;ast-dtmf=1 40 | 41 | ; 42 | ; How to detect DTMF tones 43 | ; any value = use Asterisk functions 44 | ; commented out = use VPB functions 45 | ; 46 | ; NOTE: this setting is currently broken, and uncommenting it will 47 | ; stop dialling from working. Any volunteers to fix it? 48 | ;ast-dtmf-det=1 49 | 50 | ; 51 | ; Use relaxed DTMF detection (ignored unless ast-dtmf-det is set) 52 | ; 53 | relaxdtmf=1 54 | 55 | ; 56 | ; When we do a native bridge between two VPB channels: 57 | ; yes = only break the connection for '#' and '*' 58 | ; no = break the connection for any DTMF 59 | ; 60 | ; NOTE: this is currently broken, and setting to no will segfault 61 | ; Asterisk while dialling. Any volunteers to fix it? 62 | ; 63 | break-for-dtmf=yes 64 | 65 | ; 66 | ; The maximum period between received rings. Measures in milliseconds. 67 | ; 68 | timer_period_ring=4000 69 | 70 | 71 | [interfaces] 72 | ; 73 | ; Default language 74 | ; 75 | language=en 76 | 77 | ; 78 | ; Default context 79 | ; 80 | context=default 81 | 82 | ; 83 | ; Echo cancellation 84 | ; off = no not use echo cancellation 85 | ; on = use echo cancellation 86 | ; 87 | echocancel=off 88 | 89 | ; 90 | ; Caller ID routines/signalling 91 | ; For FXO ports, select one of: 92 | ; on = collect caller ID between 1st/2nd rings using VPB routines 93 | ; off = do not use caller ID 94 | ; bell = bell202 as used in US, using Asterisk's caller ID routines 95 | ; v23 = v23 as used in the UK, using Asterisk's caller ID routines 96 | ; For FXS ports, set the channel's CID in '"name" ' format 97 | ; 98 | ; NOTE that other caller ID standards are supported in Asterisk, but are 99 | ; not yet active in chan_vpb. It should be reasonably trivial to add 100 | ; support for the other standards (see the default chan_dahdi.conf for a 101 | ; list of them) that Asterisk already handles. 102 | ; 103 | callerid=bell 104 | 105 | ; 106 | ; Use a polarity reversal as the trigger for the start of caller ID, 107 | ; rather than triggering after the first ring. 108 | ; 109 | usepolaritycid=0 110 | 111 | ; 112 | ; Use loop drop to detect the end of a call. On by default, but if you 113 | ; experience unexpected hangups, try turning it off. 114 | ; 115 | useloopdrop=1 116 | 117 | ; 118 | ; Use in-kernel bridging. This will generally give lower delay audio if 119 | ; bridging between two VPB channels. It will not affect bridging 120 | ; between VPB channels and other technologies. 121 | ; 122 | usenativebridge=1 123 | 124 | ; 125 | ; Software transmit and receive gain. Adjusting these will change the 126 | ; volume of audio files that are played (tx) and recorded (rx). It will 127 | ; _not_ affect audio between channels in a native bridge. It will, 128 | ; however, affect the volume of audio between VPB channels and channels 129 | ; using other technologies (such as VoIP channels). Usually it's best to 130 | ; leave these as they are. If you're looking to get rid of echo, the 131 | ; first thing to do is match your line impedance with the bal1/bal2/bal3 132 | ; settings. 133 | ; 134 | ;txgain=0.0 135 | ;rxgain=0.0 136 | 137 | ; 138 | ; Hardware transmit and receive gain. Adjusting these will change the 139 | ; volume of all audio on a channel. The allowed range of settings is 140 | ; -12.0 to 12.0 (measured in dB). 141 | ; 142 | ;txhwgain=0.0 143 | ;rxhwgain=0.0 144 | 145 | ; 146 | ; Balance register settings, for matching the impedance of the card to 147 | ; that of the connected equipment. Only relevant for OpenLine and 148 | ; OpenSwitch series cards. Values should be in the range 0 - 255. 149 | ; 150 | ; We (Voicetronix) have determined the best codec balance values for 151 | ; standard interfaces based on their US, Australian and European 152 | ; specifications, shown below. 153 | ; 154 | ; US (600 ohm) 155 | ;bal1=0xf8 156 | ;bal2=0x1a 157 | ;bal3=0x0c 158 | ; 159 | ; Australia (complex impedance) 160 | ;bal1=0xf0 161 | ;bal2=0x5d 162 | ;bal3=0x79 163 | ; 164 | ; Europe (CTR-21) 165 | ;bal1=0xf0 166 | ;bal2=0x6e 167 | ;bal3=0x75 168 | 169 | ; 170 | ; Logical groups can be assigned to allow outgoing rollover. Groups range 171 | ; from 0 to 63, and multiple groups can be specified. 172 | ; 173 | group=1 174 | 175 | ; 176 | ; Ring groups (a.k.a. call groups) and pickup groups. If a phone is 177 | ; ringing and it is a member of a group which is one of your pickup 178 | ; groups, then you can answer it by picking up and dialling *8#. For 179 | ; simple offices, just make these both the same. Groups range from 0 to 180 | ; 63. 181 | ; 182 | callgroup=1 183 | pickupgroup=1 184 | 185 | ; 186 | ; If we haven't had a "grunt" (voice activity detection) for this many 187 | ; seconds, then we hang up the line due to inactivity. Default is one 188 | ; hour. 189 | ; 190 | grunttimeout=3600 191 | 192 | ; 193 | ; Type of line and line handling. This setting will usually be overridden 194 | ; on a per channel basis. Valid settings are: 195 | ; fxo = this is an FXO port 196 | ; immediate = this is an FXS port, with no dialtone or dialling 197 | ; required (ie it is a "hotline") 198 | ; dialtone = this is an FXS port, providing dialtone and dialling 199 | ; 200 | mode=immediate 201 | 202 | ;------------------------------------------------------------------------- 203 | ; Channel definitions 204 | ; 205 | ; Each channel inherits the settings specified above, unless the are 206 | ; overridden. As a minimum, the board number and channel number must be 207 | ; set, starting from 0 for the first board, and for the channels on each 208 | ; board. For example, board 0, channels 0 to 11, then board 1, channels 209 | ; 0 to 11 for two OpenSwitch12 cards. 210 | ; 211 | 212 | ; 213 | ; First board is an OpenSwitch12 card (jumpers at factory defaults) 214 | ; 215 | ;board=0 216 | ; 217 | ;mode=dialtone 218 | ;context=from-handset 219 | ;group=1 220 | ;channel=0 221 | ;channel=1 222 | ;channel=2 223 | ;channel=3 224 | ;channel=4 225 | ;channel=5 226 | ;channel=6 227 | ;channel=7 228 | ; 229 | ;mode=fxo 230 | ;context=from-pstn 231 | ;group=2 232 | ;channel=8 233 | ;channel=9 234 | ;channel=10 235 | ;channel=11 236 | 237 | ; 238 | ; Second board is an OpenLine4 239 | ; 240 | ;board=1 241 | ; 242 | ;mode=fxo 243 | ;group=2 244 | ;context=from-pstn 245 | ;channel=0 246 | ;channel=1 247 | ;channel=2 248 | ;channel=3 249 | -------------------------------------------------------------------------------- /asterisk/cli_aliases.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; CLI Aliases configuration 3 | ; 4 | ; This module also registers a "cli show aliases" CLI command to list 5 | ; configured CLI aliases. 6 | 7 | [general] 8 | ; Here you define what alias templates you want to use. You can also define 9 | ; multiple templates to use as well. If you do, and there is a conflict, then 10 | ; the first alias defined will win. 11 | ; 12 | template = friendly ; By default, include friendly aliases 13 | ;template = asterisk12 ; Asterisk 1.2 style syntax 14 | ;template = asterisk14 ; Asterisk 1.4 style syntax 15 | ;template = individual_custom ; see [individual_custom] example below which 16 | ; includes a list of aliases from an external 17 | ; file 18 | 19 | 20 | ; Because the Asterisk CLI syntax follows a "module verb argument" syntax, 21 | ; sometimes we run into an issue between being consistant with this format 22 | ; in the core system, and maintaining system friendliness. In order to get 23 | ; around this we're providing some useful aliases by default. 24 | ; 25 | [friendly] 26 | hangup request=channel request hangup 27 | originate=channel originate 28 | help=core show help 29 | pri intense debug span=pri set debug 2 span 30 | reload=module reload 31 | 32 | ; CLI Alias Templates 33 | ; ------------------- 34 | ; 35 | ; You can define several alias templates. 36 | ; It works with context templates like all other configuration files 37 | ; 38 | ;[asterisk](!) 39 | ; To create an alias you simply set the variable name as the alias and variable 40 | ; value as the real CLI command you want executed 41 | ; 42 | ;die die die=stop now 43 | 44 | ;[asterisk16](asterisk) 45 | ; Alias for making voicemail reload actually do module reload app_voicemail.so 46 | ;voicemail reload=module reload app_voicemail.so 47 | ; This will make the CLI command "mr" behave as though it is "module reload". 48 | ;mr=module reload 49 | ; 50 | ; 51 | ; In addition, you could also include a flat file of aliases which is loaded by 52 | ; the [individual_custom] template in the [general] section. 53 | ; 54 | ;[individual_custom] 55 | ;#include "/etc/asterisk/aliases" 56 | 57 | ; Implemented CLI Alias Templates 58 | ; ------------------------------- 59 | ; 60 | ; Below here we have provided you with some templates, easily allowing you to 61 | ; utilize previous Asterisk CLI commands with any version of Asterisk. In this 62 | ; way you will be able to use Asterisk 1.2 and 1.4 style CLI syntax with any 63 | ; version Asterisk going forward into the future. 64 | ; 65 | ; We have also separated out the vanilla syntax into a context template which 66 | ; allows you to keep your custom changes separate of the standard templates 67 | ; we have provided you. In this way you can clearly see your custom changes, 68 | ; and also allowing you to combine various templates as you see fit. 69 | ; 70 | ; The naming scheme we have used is recommended, but certainly is not enforced 71 | ; by Asterisk. If you wish to use the provided templates, simply define the 72 | ; context name which does not utilize the '_tpl' at the end. For example, 73 | ; if you would like to use the Asterisk 1.2 style syntax, define in the 74 | ; [general] section 75 | 76 | [asterisk12_tpl](!) 77 | show channeltypes=core show channeltypes 78 | show channeltype=core show channeltype 79 | show manager command=manager show command 80 | show manager commands=manager show commands 81 | show manager connected=manager show connected 82 | show manager eventq=manager show eventq 83 | rtp no debug=rtp set debug off 84 | rtp rtcp debug ip=rtcp debug ip 85 | rtp rtcp debug=rtcp debug 86 | rtp rtcp no debug=rtcp debug off 87 | rtp rtcp stats=rtcp stats 88 | rtp rtcp no stats=rtcp stats off 89 | stun no debug=stun debug off 90 | udptl no debug=udptl debug off 91 | show image formats=core show image formats 92 | show file formats=core show file formats 93 | show applications=core show applications 94 | show functions=core show functions 95 | show switches=core show switches 96 | show hints=core show hints 97 | show globals=core show globals 98 | show function=core show function 99 | show application=core show application 100 | set global=core set global 101 | show dialplan=dialplan show 102 | show codecs=core show codecs 103 | show audio codecs=core show audio codecs 104 | show video codecs=core show video codecs 105 | show image codecs=core show image codecs 106 | show codec=core show codec 107 | moh classes show=moh show classes 108 | moh files show=moh show files 109 | agi no debug=agi debug off 110 | show agi=agi show 111 | dump agihtml=agi dumphtml 112 | show features=feature show 113 | show indications=indication show 114 | answer=console answer 115 | hangup=console hangup 116 | flash=console flash 117 | dial=console dial 118 | mute=console mute 119 | unmute=console unmute 120 | transfer=console transfer 121 | send text=console send text 122 | autoanswer=console autoanswer 123 | oss boost=console boost 124 | console=console active 125 | save dialplan=dialplan save 126 | add extension=dialplan add extension 127 | remove extension=dialplan remove extension 128 | add ignorepat=dialplan add ignorepat 129 | remove ignorepat=dialplan remove ignorepat 130 | include context=dialplan add include 131 | dont include=dialplan remove include 132 | extensions reload=dialplan reload 133 | show translation=core show translation 134 | convert=file convert 135 | show queue=queue show 136 | add queue member=queue add member 137 | remove queue member=queue remove member 138 | ael no debug=ael nodebug 139 | sip debug=sip set debug 140 | sip no debug=sip set debug off 141 | show voicemail users=voicemail show users 142 | show voicemail zones=voicemail show zones 143 | iax2 trunk debug=iax2 set debug trunk 144 | iax2 jb debug=iax2 set debug jb 145 | iax2 no debug=iax2 set debug off 146 | iax2 no trunk debug=iax2 set debug trunk off 147 | iax2 no jb debug=iax2 set debug jb off 148 | show agents=agent show 149 | show agents online=agent show online 150 | show memory allocations=memory show allocations 151 | show memory summary=memory show summary 152 | show version=core show version 153 | show version files=core show file version 154 | show profile=core show profile 155 | clear profile=core clear profile 156 | soft hangup=channel request hangup 157 | 158 | [asterisk12](asterisk12_tpl) 159 | ; add any additional custom commands you want below here, for example: 160 | ;die quickly=stop now 161 | 162 | [asterisk14_tpl](!) 163 | cdr status=cdr show status 164 | rtp debug=rtp set debug on 165 | rtcp debug=rtcp set debug on 166 | rtcp stats=rtcp set stats on 167 | stun debug=stun set debug on 168 | udptl debug=udptl set debug on 169 | core show globals=dialplan show globals 170 | core set global=dialplan set global 171 | core set chanvar=dialplan set chanvar 172 | agi dumphtml=agi dump html 173 | ael debug=ael set debug 174 | funcdevstate list=devstate list 175 | sip history=sip set history on 176 | skinny debug=skinny set debug on 177 | mgcp set debug=mgcp set debug on 178 | abort shutdown=core abort shutdown 179 | stop now=core stop now 180 | stop gracefully=core stop gracefully 181 | stop when convenient=core stop when convenient 182 | restart now=core restart now 183 | restart gracefully=core restart gracefully 184 | restart when convenient=core restart when convenient 185 | soft hangup=channel request hangup 186 | 187 | [asterisk14](asterisk14_tpl) 188 | ; add any additional custom commands you want below here. 189 | -------------------------------------------------------------------------------- /asterisk/ccss.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; --- Call Completion Supplementary Services --- 3 | ; 4 | ; For more information about CCSS, see the CCSS user documentation 5 | ; https://wiki.asterisk.org/wiki/display/AST/Call+Completion+Supplementary+Services+(CCSS) 6 | ; 7 | 8 | [general] 9 | ; There is only a single option that may be defined in this file. 10 | ; The cc_max_requests option is a global limit on the number of 11 | ; CC requests that may be in the Asterisk system at any time. 12 | ; 13 | ;cc_max_requests = 20 14 | ; 15 | ; 16 | ;============================================ 17 | ; PLEASE READ THIS!!! 18 | ; The options described below should NOT be 19 | ; set in this file. Rather, they should be 20 | ; set per-device in a channel driver 21 | ; configuration file. 22 | ; PLEASE READ THIS!!! 23 | ;=========================================== 24 | ; 25 | ;--------------------------------------------------------------------- 26 | ; Timers 27 | ;--------------------------------------------------------------------- 28 | ;There are three configurable timers for all types of CC: the 29 | ;cc_offer_timer, the ccbs_available_timer, and the ccnr_available_timer. 30 | ;In addition, when using a generic agent, there is a fourth timer, 31 | ;the cc_recall_timer. All timers are configured in seconds, and the 32 | ;values shown below are the defaults. 33 | ; 34 | ;When a caller is offered CCBS or CCNR, the cc_offer_timer will 35 | ;be started. If the caller does not request CC before the 36 | ;cc_offer_timer expires, then the caller will be unable to request 37 | ;CC for this call. 38 | ; 39 | ;cc_offer_timer = 20 40 | ; 41 | ;Once a caller has requested CC, then either the ccbs_available_timer 42 | ;or the ccnr_available_timer will run, depending on the service 43 | ;requested. The reason why there are two separate timers for CCBS 44 | ;and CCNR is that it is reasonable to want to have a shorter timeout 45 | ;configured for CCBS than for CCNR. If the available timer expires 46 | ;before the called party becomes available, then the CC attempt 47 | ;will have failed and monitoring of the called party will stop. 48 | ; 49 | ;ccbs_available_timer = 4800 50 | ;ccnr_available_timer = 7200 51 | ; 52 | ; When using a generic agent, the original caller is called back 53 | ; when one of the original called parties becomes available. The 54 | ; cc_recall_timer tells Asterisk how long it should let the original 55 | ; caller's phone ring before giving up. Please note that this parameter 56 | ; only affects operation when using a generic agent. 57 | ; 58 | ;cc_recall_timer = 20 59 | ;--------------------------------------------------------------------- 60 | ; Policies 61 | ;--------------------------------------------------------------------- 62 | ; Policy settings tell Asterisk how to behave and what sort of 63 | ; resources to allocate in order to facilitate CC. There are two 64 | ; settings to control the actions Asterisk will take. 65 | ; 66 | ; The cc_agent_policy describes the behavior that Asterisk will 67 | ; take when communicating with the caller during CC. There are 68 | ; three possible options. 69 | ; 70 | ;never: Never offer CC to the caller. Setting the cc_agent_policy 71 | ; to this value is the way to disable CC for a call. 72 | ; 73 | ;generic: A generic CC agent is one which uses no protocol-specific 74 | ; mechanisms to offer CC to the caller. Instead, the caller 75 | ; requests CC using a dialplan function. Due to internal 76 | ; restrictions, you should only use a generic CC agent on 77 | ; phones (i.e. not "trunks"). If you are using phones which 78 | ; do not support a protocol-specific method of using CC, then 79 | ; generic CC agents are what you should use. 80 | ; 81 | ;native: A native CC agent is one which uses protocol-specific 82 | ; signaling to offer CC to the caller and accept CC requests 83 | ; from the caller. The supported protocols for native CC 84 | ; agents are SIP, ISDN ETSI PTP, ISDN ETSI PTMP, and Q.SIG 85 | ;cc_agent_policy=never 86 | ; 87 | ; The cc_monitor_policy describes the behavior that Asterisk will 88 | ; take when communicating with the called party during CC. There 89 | ; are four possible options. 90 | ; 91 | ;never: Analogous to the cc_agent_policy setting. We will never 92 | ; attempt to request CC services on this interface. 93 | ; 94 | ;generic: Analogous to the cc_agent_policy setting. We will monitor 95 | ; the called party's progress using protocol-agnostic 96 | ; capabilities. Like with generic CC agents, generic CC 97 | ; monitors should only be used for phones. 98 | ; 99 | ;native: Analogous to the cc_agent_policy setting. We will use 100 | ; protocol-specific methods to request CC from this interface 101 | ; and to monitor the interface for availability. 102 | ; 103 | ;always: If an interface is set to "always," then we will accept 104 | ; protocol-specific CC offers from the caller and use 105 | ; a native CC monitor for the remainder of the CC transaction. 106 | ; However, if the interface does not offer protocol-specific 107 | ; CC, then we will fall back to using a generic CC monitor 108 | ; instead. This is a good setting to use for phones for which 109 | ; you do not know if they support protocol-specific CC 110 | ; methodologies. 111 | ;cc_monitor_policy=never 112 | ; 113 | ; 114 | ;--------------------------------------------------------------------- 115 | ; Limits 116 | ;--------------------------------------------------------------------- 117 | ; 118 | ; The use of CC requires Asterisk to potentially use more memory than 119 | ; some administrators would like. As such, it is a good idea to limit 120 | ; the number of CC requests that can be in the system at a given time. 121 | ; The values shown below are the defaults. 122 | ; 123 | ; The cc_max_agents setting limits the number of outstanding CC 124 | ; requests a caller may have at any given time. Please note that due 125 | ; to implementation restrictions, this setting is ignored when using 126 | ; generic CC agents. Generic CC agents may only have one outstanding 127 | ; CC request. 128 | ; 129 | ;cc_max_agents = 5 130 | ; 131 | ; The cc_max_monitors setting limits the number of outstanding CC 132 | ; requests can be made to a specific interface at a given time. 133 | ; 134 | ;cc_max_monitors = 5 135 | ; 136 | ;--------------------------------------------------------------------- 137 | ; Other 138 | ;--------------------------------------------------------------------- 139 | ; 140 | ; When using a generic CC agent, the caller who requested CC will be 141 | ; called back when a called party becomes available. When the caller 142 | ; answers his phone, the administrator may opt to have a macro run. 143 | ; What this macro does is up to the administrator. By default there 144 | ; is no callback macro configured. 145 | ; 146 | ;cc_callback_macro= 147 | ; 148 | ; When using an ISDN phone and a generic CC agent, Asterisk is unable 149 | ; to determine the dialstring that should be used when calling back 150 | ; the original caller. Furthermore, if you desire to use any dialstring- 151 | ; specific options, such as distinctive ring, you must set this 152 | ; configuration option. For non-ISDN phones, it is not necessary to 153 | ; set this, since Asterisk can determine the dialstring to use since 154 | ; it is identical to the name of the calling device. By default, there 155 | ; is no cc_agent_dialstring set. 156 | ; 157 | ;cc_agent_dialstring= 158 | -------------------------------------------------------------------------------- /asterisk/sla.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Configuration for Shared Line Appearances (SLA). 3 | ; 4 | ; See http://wiki.asterisk.org or doc/AST.pdf for more information. 5 | ; 6 | 7 | ; ---- General Options ---------------- 8 | [general] 9 | 10 | ;attemptcallerid=no ; Attempt CallerID handling. The default value for this 11 | ; is "no" because CallerID handling with an SLA setup is 12 | ; known to not work properly in some situations. However, 13 | ; feel free to enable it if you would like. If you do, and 14 | ; you find problems, please do not report them. 15 | ; ------------------------------------- 16 | 17 | 18 | ; ******************************** 19 | ; **** Configuration Ordering **** 20 | ; ******************************** 21 | 22 | ; Note that SLA configuration processing assumes that *all* trunk declarations are 23 | ; listed in the configuration file before any stations. 24 | 25 | ; ******************************** 26 | ; ******************************** 27 | 28 | 29 | ; ---- Trunk Declarations ------------- 30 | ; 31 | ;[line1] ; Provide a name for this trunk. 32 | 33 | ;type=trunk ; This line is what marks this entry as a trunk. 34 | 35 | ;device=DAHDI/3 ; Map this trunk declaration to a specific device. 36 | ; NOTE: You can not just put any type of channel here. 37 | ; DAHDI channels can be directly used. IP trunks 38 | ; require some indirect configuration which is 39 | ; described in 40 | ; https://wiki.asterisk.org/wiki/display/AST/SLA+Trunk+Configuration 41 | 42 | ;autocontext=line1 ; This supports automatic generation of the dialplan entries 43 | ; if the autocontext option is used. Each trunk should have 44 | ; a unique context name. Then, in chan_dahdi.conf, this device 45 | ; should be configured to have incoming calls go to this context. 46 | 47 | ;ringtimeout=30 ; Set how long to allow this trunk to ring on an inbound call before hanging 48 | ; it up as an unanswered call. The value is in seconds. 49 | 50 | ;barge=no ; If this option is set to "no", then no station will be 51 | ; allowed to join a call that is in progress. The default 52 | ; value is "yes". 53 | 54 | ;hold=private ; This option configure hold permissions for this trunk. 55 | ; "open" - This means that any station can put this trunk 56 | ; on hold, and any station can retrieve it from 57 | ; hold. This is the default. 58 | ; "private" - This means that once a station puts the 59 | ; trunk on hold, no other station will be 60 | ; allowed to retrieve the call from hold. 61 | 62 | ;[line2] 63 | ;type=trunk 64 | ;device=DAHDI/4 65 | ;autocontext=line2 66 | 67 | ;[line3] 68 | ;type=trunk 69 | ;device=DAHDI/3 70 | ;autocontext=line3 71 | 72 | ;[line4] 73 | ;type=trunk 74 | ;device=Local/disa@line4_outbound ; A Local channel in combination with the Disa 75 | ; application can be used to support IP trunks. 76 | ; See https://wiki.asterisk.org/wiki/display/AST/SLA+Trunk+Configuration 77 | ;autocontext=line4 78 | ; -------------------------------------- 79 | 80 | 81 | ; ---- Station Declarations ------------ 82 | 83 | ;[station1] ; Define a name for this station. 84 | 85 | ;type=station ; This line indicates that this entry is a station. 86 | 87 | ;device=SIP/station1 ; Each station must be mapped to a device. 88 | 89 | ;autocontext=sla_stations ; This supports automatic generation of the dialplan entries if 90 | ; the autocontext option is used. All stations can use the same 91 | ; context without conflict. The device for this station should 92 | ; have its context configured to the same one listed here. 93 | 94 | ;ringtimeout=10 ; Set a timeout for how long to allow the station to ring for an 95 | ; incoming call, in seconds. 96 | 97 | ;ringdelay=10 ; Set a time for how long to wait before beginning to ring this station 98 | ; once there is an incoming call, in seconds. 99 | 100 | ;hold=private ; This option configure hold permissions for this station. Note 101 | ; that if private hold is set in the trunk entry, that will override 102 | ; anything here. However, if a trunk has open hold access, but this 103 | ; station is set to private hold, then the private hold will be in 104 | ; effect. 105 | ; "open" - This means that once this station puts a call 106 | ; on hold, any other station is allowed to retrieve 107 | ; it. This is the default. 108 | ; "private" - This means that once this station puts a 109 | ; call on hold, no other station will be 110 | ; allowed to retrieve the call from hold. 111 | 112 | 113 | ;trunk=line1 ; Individually list all of the trunks that will appear on this station. This 114 | ; order is significant. It should be the same order as they appear on the 115 | ; phone. The order here defines the order of preference that the trunks will 116 | ; be used. 117 | ;trunk=line2 118 | ;trunk=line3,ringdelay=5 ; A ring delay for the station can also be specified for a specific trunk. 119 | ; If a ring delay is specified both for the whole station and for a specific 120 | ; trunk on a station, the setting for the specific trunk will take priority. 121 | ; This value is in seconds. 122 | 123 | ;trunk=line4,ringtimeout=5 ; A ring timeout for the station can also be specified for a specific trunk. 124 | ; If a ring timeout is specified both for the whole station and for a specific 125 | ; trunk on a station, the setting for the specific trunk will take priority. 126 | ; This value is in seconds. 127 | 128 | 129 | ;[station](!) ; When there are a lot of stations that are configured the same way, 130 | ; it is convenient to use a configuration template like this so that 131 | ; the common settings stay in one place. 132 | ;type=station 133 | ;autocontext=sla_stations 134 | ;trunk=line1 135 | ;trunk=line2 136 | ;trunk=line3 137 | ;trunk=line4 138 | 139 | ;[station2](station) ; Define a station that uses the configuration from the template "station". 140 | ;device=SIP/station2 141 | ; 142 | ;[station3](station) 143 | ;device=SIP/station3 144 | ; 145 | ;[station4](station) 146 | ;device=SIP/station4 147 | ; 148 | ;[station5](station) 149 | ;device=SIP/station5 150 | ; -------------------------------------- 151 | 152 | -------------------------------------------------------------------------------- /asterisk/phoneprov.conf: -------------------------------------------------------------------------------- 1 | [general] 2 | ; The default behavior of res_phoneprov will be to set the SERVER template variable to 3 | ; the IP address that the phone uses to contact the provisioning server and the 4 | ; SERVER_PORT variable to the bindport setting in sip.conf. Unless you have a very 5 | ; unusual setup, you should not need to set serveraddr, serveriface, or serverport. 6 | 7 | ;serveraddr=192.168.1.1 ; Override address to send to the phone to use as server address. 8 | ;serveriface=eth0 ; Same as above, except an ethernet interface. 9 | ; Useful for when the interface uses DHCP and the asterisk http 10 | ; server listens on a different IP than chan_sip. 11 | ;serverport=5060 ; Override port to send to the phone to use as server port. 12 | default_profile=polycom ; The default profile to use if none specified in users.conf 13 | 14 | ; You can define profiles for different phones specifying what files to register 15 | ; with the provisioning server. You can define either static files, or dynamically 16 | ; generated files that can have dynamic names and point to templates that variables 17 | ; can be substituted into. You can also set arbitrary variables for the profiles 18 | ; templates to have access to. Example: 19 | 20 | ;[example] 21 | ;mime_type => application/octet-stream 22 | ;static_file => example/firmware 23 | ;static_file => example/default.cfg,text/xml 24 | ;${TOUPPER(${MAC})}.cfg => templates/example-mac.cfg 25 | ;setvar => DB_CIDNAME=${ODBC_CID_NAME_LOOKUP(${USERNAME})} 26 | 27 | ; Dynamically generated files have a filename registered with variable substitution 28 | ; with variables obtained while reading users.conf. 29 | 30 | ; Built in variables and the options in users.conf that they come from 31 | ; MAC (macaddress) 32 | ; USERNAME (username) 33 | ; DISPLAY_NAME (fullname) 34 | ; SECRET (secret) 35 | ; LABEL (label) 36 | ; CALLERID (cid_number) 37 | ; VOCIEMAIL_EXTEN (vmexten) 38 | ; EXTENSION_LENGTH (localextenlength) 39 | ; LINE 40 | ; LINEKEYS 41 | 42 | ; Built-in variables and the options in phoneprov.conf that they come from 43 | ; SERVER (server) 44 | ; SERVER_PORT (serverport) 45 | 46 | 47 | ; Built-in variables for managing timezones and daylight savings time. 48 | ; TZOFFSET 49 | ; DST_ENABLE 50 | ; DST_START_MONTH 51 | ; DST_START_MDAY 52 | ; DST_START_HOUR 53 | ; DST_END_MONTH 54 | ; DST_END_MDAY 55 | ; DST_END_HOUR 56 | ; TIMEZONE 57 | 58 | [polycom] 59 | staticdir => configs/ ; Sub directory of AST_DATA_DIR/phoneprov that static files reside 60 | ; in. This allows a request to /phoneprov/sip.cfg to pull the file 61 | ; from /phoneprov/configs/sip.cfg 62 | mime_type => text/xml ; Default mime type to use if one isn't specified or the 63 | ; extension isn't recognized 64 | static_file => bootrom.ld,application/octet-stream ; Static files the phone will download 65 | static_file => bootrom.ver,plain/text ; static_file => filename,mime-type 66 | static_file => sip.ld,application/octet-stream 67 | static_file => sip.ver,plain/text 68 | static_file => sip.cfg 69 | static_file => custom.cfg 70 | static_file => 2201-06642-001.bootrom.ld,application/octet-stream 71 | static_file => 2201-06642-001.sip.ld,application/octet-stream 72 | static_file => 2345-11000-001.bootrom.ld,application/octet-stream 73 | static_file => 2345-11300-001.bootrom.ld,application/octet-stream 74 | static_file => 2345-11300-010.bootrom.ld,application/octet-stream 75 | static_file => 2345-11300-010.sip.ld,application/octet-stream 76 | static_file => 2345-11402-001.bootrom.ld,application/octet-stream 77 | static_file => 2345-11402-001.sip.ld,application/octet-stream 78 | static_file => 2345-11500-001.bootrom.ld,application/octet-stream 79 | static_file => 2345-11500-010.bootrom.ld,application/octet-stream 80 | static_file => 2345-11500-020.bootrom.ld,application/octet-stream 81 | static_file => 2345-11500-030.bootrom.ld,application/octet-stream 82 | static_file => 2345-11500-030.sip.ld,application/octet-stream 83 | static_file => 2345-11500-040.bootrom.ld,application/octet-stream 84 | static_file => 2345-11500-040.sip.ld,application/octet-stream 85 | static_file => 2345-11600-001.bootrom.ld,application/octet-stream 86 | static_file => 2345-11600-001.sip.ld,application/octet-stream 87 | static_file => 2345-11605-001.bootrom.ld,application/octet-stream 88 | static_file => 2345-11605-001.sip.ld,application/octet-stream 89 | static_file => 2345-12200-001.bootrom.ld,application/octet-stream 90 | static_file => 2345-12200-001.sip.ld,application/octet-stream 91 | static_file => 2345-12200-002.bootrom.ld,application/octet-stream 92 | static_file => 2345-12200-002.sip.ld,application/octet-stream 93 | static_file => 2345-12200-004.bootrom.ld,application/octet-stream 94 | static_file => 2345-12200-004.sip.ld,application/octet-stream 95 | static_file => 2345-12200-005.bootrom.ld,application/octet-stream 96 | static_file => 2345-12200-005.sip.ld,application/octet-stream 97 | static_file => 2345-12365-001.bootrom.ld,application/octet-stream 98 | static_file => 2345-12365-001.sip.ld,application/octet-stream 99 | static_file => 2345-12500-001.bootrom.ld,application/octet-stream 100 | static_file => 2345-12500-001.sip.ld,application/octet-stream 101 | static_file => 2345-12560-001.bootrom.ld,application/octet-stream 102 | static_file => 2345-12560-001.sip.ld,application/octet-stream 103 | static_file => 2345-12600-001.bootrom.ld,application/octet-stream 104 | static_file => 2345-12600-001.sip.ld,application/octet-stream 105 | static_file => 2345-12670-001.bootrom.ld,application/octet-stream 106 | static_file => 2345-12670-001.sip.ld,application/octet-stream 107 | static_file => 3111-15600-001.bootrom.ld,application/octet-stream 108 | static_file => 3111-15600-001.sip.ld,application/octet-stream 109 | static_file => 3111-40000-001.bootrom.ld,application/octet-stream 110 | static_file => 3111-40000-001.sip.ld,application/octet-stream 111 | static_file => SoundPointIPWelcome.wav,application/octet-stream 112 | static_file => SoundPointIPLocalization/Japanese_Japan/SoundPointIP-dictionary.xml 113 | static_file => SoundPointIPLocalization/Norwegian_Norway/SoundPointIP-dictionary.xml 114 | static_file => SoundPointIPLocalization/Spanish_Spain/SoundPointIP-dictionary.xml 115 | static_file => SoundPointIPLocalization/Portuguese_Portugal/SoundPointIP-dictionary.xml 116 | static_file => SoundPointIPLocalization/English_United_Kingdom/SoundPointIP-dictionary.xml 117 | static_file => SoundPointIPLocalization/English_United_States/SoundPointIP-dictionary.xml 118 | static_file => SoundPointIPLocalization/Russian_Russia/SoundPointIP-dictionary.xml 119 | static_file => SoundPointIPLocalization/Italian_Italy/SoundPointIP-dictionary.xml 120 | static_file => SoundPointIPLocalization/Chinese_China/SoundPointIP-dictionary.xml 121 | static_file => SoundPointIPLocalization/Swedish_Sweden/SoundPointIP-dictionary.xml 122 | static_file => SoundPointIPLocalization/English_Canada/SoundPointIP-dictionary.xml 123 | static_file => SoundPointIPLocalization/German_Germany/SoundPointIP-dictionary.xml 124 | static_file => SoundPointIPLocalization/French_France/SoundPointIP-dictionary.xml 125 | static_file => SoundPointIPLocalization/Danish_Denmark/SoundPointIP-dictionary.xml 126 | static_file => SoundPointIPLocalization/Dutch_Netherlands/SoundPointIP-dictionary.xml 127 | static_file => SoundPointIPLocalization/Korean_Korea/SoundPointIP-dictionary.xml 128 | 129 | ${MAC}.cfg => 000000000000.cfg ; Dynamically generated files. 130 | ${MAC}-phone.cfg => 000000000000-phone.cfg ; (relative to AST_DATA_DIR/phoneprov) 131 | config/${MAC} => polycom.xml ; Dynamic Filename => template file 132 | ${MAC}-directory.xml => 000000000000-directory.xml 133 | setvar => CUSTOM_CONFIG=/usr/share/asterisk/phoneprov/configs/custom.cfg ; Custom variable 134 | 135 | ;snom 300, 320, 360, 370, 820, 821, 870 support 136 | snom-${MAC}.xml => snom-mac.xml 137 | -------------------------------------------------------------------------------- /asterisk/cdr.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Asterisk Call Detail Record engine configuration 3 | ; 4 | ; CDR is Call Detail Record, which provides logging services via a variety of 5 | ; pluggable backend modules. Detailed call information can be recorded to 6 | ; databases, files, etc. Useful for billing, fraud prevention, compliance with 7 | ; Sarbanes-Oxley aka The Enron Act, QOS evaluations, and more. 8 | ; 9 | 10 | [general] 11 | 12 | ; Define whether or not to use CDR logging. Setting this to "no" will override 13 | ; any loading of backend CDR modules. Default is "yes". 14 | ;enable=yes 15 | 16 | ; Define whether or not to log unanswered calls. Setting this to "yes" will 17 | ; report every attempt to ring a phone in dialing attempts, when it was not 18 | ; answered. For example, if you try to dial 3 extensions, and this option is "yes", 19 | ; you will get 3 CDR's, one for each phone that was rung. Default is "no". Some 20 | ; find this information horribly useless. Others find it very valuable. Note, in "yes" 21 | ; mode, you will see one CDR, with one of the call targets on one side, and the originating 22 | ; channel on the other, and then one CDR for each channel attempted. This may seem 23 | ; redundant, but cannot be helped. 24 | ; 25 | ; In brief, this option controls the reporting of unanswered calls which only have an A 26 | ; party. Calls which get offered to an outgoing line, but are unanswered, are still 27 | ; logged, and that is the intended behaviour. (It also results in some B side CDRs being 28 | ; output, as they have the B side channel as their source channel, and no destination 29 | ; channel.) 30 | ;unanswered = no 31 | 32 | ; Normally, CDR's are not closed out until after all extensions are finished 33 | ; executing. By enabling this option, the CDR will be ended before executing 34 | ; the "h" extension so that CDR values such as "end" and "billsec" may be 35 | ; retrieved inside of of this extension. The default value is "no". 36 | ;endbeforehexten=no 37 | 38 | ; Normally, the 'billsec' field logged to the backends (text files or databases) 39 | ; is simply the end time (hangup time) minus the answer time in seconds. Internally, 40 | ; asterisk stores the time in terms of microseconds and seconds. By setting 41 | ; initiatedseconds to 'yes', you can force asterisk to report any seconds 42 | ; that were initiated (a sort of round up method). Technically, this is 43 | ; when the microsecond part of the end time is greater than the microsecond 44 | ; part of the answer time, then the billsec time is incremented one second. 45 | ; The default value is "no". 46 | ;initiatedseconds=no 47 | 48 | ; Define the CDR batch mode, where instead of posting the CDR at the end of 49 | ; every call, the data will be stored in a buffer to help alleviate load on the 50 | ; asterisk server. Default is "no". 51 | ; 52 | ; WARNING WARNING WARNING 53 | ; Use of batch mode may result in data loss after unsafe asterisk termination 54 | ; ie. software crash, power failure, kill -9, etc. 55 | ; WARNING WARNING WARNING 56 | ; 57 | ;batch=no 58 | 59 | ; Define the maximum number of CDRs to accumulate in the buffer before posting 60 | ; them to the backend engines. 'batch' must be set to 'yes'. Default is 100. 61 | ;size=100 62 | 63 | ; Define the maximum time to accumulate CDRs in the buffer before posting them 64 | ; to the backend engines. If this time limit is reached, then it will post the 65 | ; records, regardless of the value defined for 'size'. 'batch' must be set to 66 | ; 'yes'. Note that time is in seconds. Default is 300 (5 minutes). 67 | ;time=300 68 | 69 | ; The CDR engine uses the internal asterisk scheduler to determine when to post 70 | ; records. Posting can either occur inside the scheduler thread, or a new 71 | ; thread can be spawned for the submission of every batch. For small batches, 72 | ; it might be acceptable to just use the scheduler thread, so set this to "yes". 73 | ; For large batches, say anything over size=10, a new thread is recommended, so 74 | ; set this to "no". Default is "no". 75 | ;scheduleronly=no 76 | 77 | ; When shutting down asterisk, you can block until the CDRs are submitted. If 78 | ; you don't, then data will likely be lost. You can always check the size of 79 | ; the CDR batch buffer with the CLI "cdr status" command. To enable blocking on 80 | ; submission of CDR data during asterisk shutdown, set this to "yes". Default 81 | ; is "yes". 82 | ;safeshutdown=yes 83 | 84 | ; 85 | ; 86 | ; CHOOSING A CDR "BACKEND" (what kind of output to generate) 87 | ; 88 | ; To choose a backend, you have to make sure either the right category is 89 | ; defined in this file, or that the appropriate config file exists, and has the 90 | ; proper definitions in it. If there are any problems, usually, the entry will 91 | ; silently ignored, and you get no output. 92 | ; 93 | ; Also, please note that you can generate CDR records in as many formats as you 94 | ; wish. If you configure 5 different CDR formats, then each event will be logged 95 | ; in 5 different places! In the example config files, all formats are commented 96 | ; out except for the cdr-csv format. 97 | ; 98 | ; Here are all the possible back ends: 99 | ; 100 | ; csv, custom, manager, odbc, pgsql, radius, sqlite, tds 101 | ; (also, mysql is available via the asterisk-addons, due to licensing 102 | ; requirements) 103 | ; (please note, also, that other backends can be created, by creating 104 | ; a new backend module in the source cdr/ directory!) 105 | ; 106 | ; Some of the modules required to provide these backends will not build or install 107 | ; unless some dependency requirements are met. Examples of this are pgsql, odbc, 108 | ; etc. If you are not getting output as you would expect, the first thing to do 109 | ; is to run the command "make menuselect", and check what modules are available, 110 | ; by looking in the "2. Call Detail Recording" option in the main menu. If your 111 | ; backend is marked with XXX, you know that the "configure" command could not find 112 | ; the required libraries for that option. 113 | ; 114 | ; To get CDRs to be logged to the plain-jane /var/log/asterisk/cdr-csv/Master.csv 115 | ; file, define the [csv] category in this file. No database necessary. The example 116 | ; config files are set up to provide this kind of output by default. 117 | ; 118 | ; To get custom csv CDR records, make sure the cdr_custom.conf file 119 | ; is present, and contains the proper [mappings] section. The advantage to 120 | ; using this backend, is that you can define which fields to output, and in 121 | ; what order. By default, the example configs are set up to mimic the cdr-csv 122 | ; output. If you don't make any changes to the mappings, you are basically generating 123 | ; the same thing as cdr-csv, but expending more CPU cycles to do so! 124 | ; 125 | ; To get manager events generated, make sure the cdr_manager.conf file exists, 126 | ; and the [general] section is defined, with the single variable 'enabled = yes'. 127 | ; 128 | ; For odbc, make sure all the proper libs are installed, that "make menuselect" 129 | ; shows that the modules are available, and the cdr_odbc.conf file exists, and 130 | ; has a [global] section with the proper variables defined. 131 | ; 132 | ; For pgsql, make sure all the proper libs are installed, that "make menuselect" 133 | ; shows that the modules are available, and the cdr_pgsql.conf file exists, and 134 | ; has a [global] section with the proper variables defined. 135 | ; 136 | ; For logging to radius databases, make sure all the proper libs are installed, that 137 | ; "make menuselect" shows that the modules are available, and the [radius] 138 | ; category is defined in this file, and in that section, make sure the 'radiuscfg' 139 | ; variable is properly pointing to an existing radiusclient.conf file. 140 | ; 141 | ; For logging to sqlite databases, make sure the 'cdr.db' file exists in the log directory, 142 | ; which is usually /var/log/asterisk. Of course, the proper libraries should be available 143 | ; during the 'configure' operation. 144 | ; 145 | ; For tds logging, make sure the proper libraries are available during the 'configure' 146 | ; phase, and that cdr_tds.conf exists and is properly set up with a [global] category. 147 | ; 148 | ; Also, remember, that if you wish to log CDR info to a database, you will have to define 149 | ; a specific table in that databse to make things work! See the doc directory for more details 150 | ; on how to create this table in each database. 151 | ; 152 | 153 | [csv] 154 | usegmtime=yes ; log date/time in GMT. Default is "no" 155 | loguniqueid=yes ; log uniqueid. Default is "no" 156 | loguserfield=yes ; log user field. Default is "no" 157 | accountlogs=yes ; create separate log file for each account code. Default is "yes" 158 | 159 | ;[radius] 160 | ;usegmtime=yes ; log date/time in GMT 161 | ;loguniqueid=yes ; log uniqueid 162 | ;loguserfield=yes ; log user field 163 | ; Set this to the location of the radiusclient-ng configuration file 164 | ; The default is /etc/radiusclient-ng/radiusclient.conf 165 | ;radiuscfg => /usr/local/etc/radiusclient-ng/radiusclient.conf 166 | -------------------------------------------------------------------------------- /asterisk/h323.conf: -------------------------------------------------------------------------------- 1 | ; The NuFone Network's 2 | ; Open H.323 driver configuration 3 | ; 4 | [general] 5 | port = 1720 6 | ;bindaddr = 1.2.3.4 ; this SHALL contain a single, valid IP address for this machine 7 | ; 8 | ; See https://wiki.asterisk.org/wiki/display/AST/IP+Quality+of+Service for a description of these parameters. 9 | ;tos_audio=ef ; Sets TOS for RTP audio packets. 10 | ;cos_audio=5 ; Sets 802.1p priority for RTP audio packets. 11 | ; 12 | ; You may specify a global default AMA flag for iaxtel calls. It must be 13 | ; one of 'default', 'omit', 'billing', or 'documentation'. These flags 14 | ; are used in the generation of call detail records. 15 | ; 16 | ;amaflags = default 17 | ; 18 | ; You may specify a default account for Call Detail Records in addition 19 | ; to specifying on a per-user basis 20 | ; 21 | ;accountcode=lss0101 22 | ; 23 | ; You can fine tune codecs here using "allow" and "disallow" clauses 24 | ; with specific codecs. Use "all" to represent all formats. 25 | ; 26 | ;disallow=all 27 | ;allow=all ; turns on all installed codecs 28 | ;disallow=g723.1 ; Hm... Proprietary, don't use it... 29 | ;allow=gsm ; Always allow GSM, it's cool :) 30 | ;allow=ulaw ; see https://wiki.asterisk.org/wiki/display/AST/RTP+Packetization 31 | ; for framing options 32 | ;autoframing=yes ; Set packetization based on the remote endpoint's (ptime) 33 | ; preferences. Defaults to no. 34 | ; 35 | ; User-Input Mode (DTMF) 36 | ; 37 | ; valid entries are: rfc2833, inband, cisco, h245-signal 38 | ; default is rfc2833 39 | ;dtmfmode=rfc2833 40 | ; 41 | ; Default RTP Payload to send RFC2833 DTMF on. This is used to 42 | ; interoperate with broken gateways which cannot successfully 43 | ; negotiate a RFC2833 payload type in the TerminalCapabilitySet. 44 | ; To specify required payload type, put it after colon in dtmfmode 45 | ; option like 46 | ;dtmfmode=rfc2833:101 47 | ; or 48 | ;dtmfmode=cisco:121 49 | ; 50 | ; Set the gatekeeper 51 | ; DISCOVER - Find the Gk address using multicast 52 | ; DISABLE - Disable the use of a GK 53 | ; or - The acutal IP address or hostname of your GK 54 | ;gatekeeper = DISABLE 55 | ; 56 | ; 57 | ; Tell Asterisk whether or not to accept Gatekeeper 58 | ; routed calls or not. Normally this should always 59 | ; be set to yes, unless you want to have finer control 60 | ; over which users are allowed access to Asterisk. 61 | ; Default: YES 62 | ; 63 | ;AllowGKRouted = yes 64 | ; 65 | ; When the channel works without gatekeeper, there is possible to 66 | ; reject calls from anonymous (not listed in users) callers. 67 | ; Default is to allow anonymous calls. 68 | ; 69 | ;AcceptAnonymous = yes 70 | ; 71 | ; Optionally you can determine a user by Source IP versus its H.323 alias. 72 | ; Default behavour is to determine user by H.323 alias. 73 | ; 74 | ;UserByAlias=no 75 | ; 76 | ; Default context gets used in siutations where you are using 77 | ; the GK routed model or no type=user was found. This gives you 78 | ; the ability to either play an invalid message or to simply not 79 | ; use user authentication at all. 80 | ; 81 | ;context=default 82 | ; 83 | ; Use this option to help Cisco (or other) gateways to setup backward voice 84 | ; path to pass inband tones to calling user (see, for example, 85 | ; http://www.cisco.com/warp/public/788/voip/ringback.html) 86 | ; 87 | ; Add PROGRESS information element to SETUP message sent on outbound calls 88 | ; to notify about required backward voice path. Valid values are: 89 | ; 0 - don't add PROGRESS information element (default); 90 | ; 1 - call is not end-end ISDN, further call progress information can 91 | ; possibly be available in-band; 92 | ; 3 - origination address is non-ISDN (Cisco accepts this value only); 93 | ; 8 - in-band information or an appropriate pattern is now available; 94 | ;progress_setup = 3 95 | ; 96 | ; Add PROGRESS information element (IE) to ALERT message sent on incoming 97 | ; calls to notify about required backwared voice path. Valid values are: 98 | ; 0 - don't add PROGRESS IE (default); 99 | ; 8 - in-band information or an appropriate pattern is now available; 100 | ;progress_alert = 8 101 | ; 102 | ; Generate PROGRESS message when H.323 audio path has established to create 103 | ; backward audio path at other end of a call. 104 | ;progress_audio = yes 105 | ; 106 | ; Specify how to inject non-standard information into H.323 messages. When 107 | ; the channel receives messages with tunneled information, it automatically 108 | ; enables the same option for all further outgoing messages independedly on 109 | ; options has been set by the configuration. This behavior is required, for 110 | ; example, for Cisco CallManager when Q.SIG tunneling is enabled for a 111 | ; gateway where Asterisk lives. 112 | ; The option can be used multiple times, one option per line. 113 | ;tunneling=none ; Totally disable tunneling (default) 114 | ;tunneling=cisco ; Enable Cisco-specific tunneling 115 | ;tunneling=qsig ; Enable tunneling via Q.SIG messages 116 | ; 117 | ; Specify how to pass hold notification to remote party. Default is to 118 | ; use H.450.4 supplementary service message. 119 | ;hold=none ; Do not pass hold/retrieve notifications 120 | ;hold=notify ; Use H.225 NOTIFY message 121 | ;hold=q931only ; Use stripped H.225 NOTIFY message (Q.931 part 122 | ; ; only, usable for Cisco CallManager) 123 | ;hold=h450 ; Pass notification as H.450.4 supplementary 124 | ; ; service 125 | ; 126 | ;------------------------------ JITTER BUFFER CONFIGURATION -------------------------- 127 | ; jbenable = yes ; Enables the use of a jitterbuffer on the receiving side of a 128 | ; H323 channel. Defaults to "no". An enabled jitterbuffer will 129 | ; be used only if the sending side can create and the receiving 130 | ; side can not accept jitter. The H323 channel can accept jitter, 131 | ; thus an enabled jitterbuffer on the receive H323 side will only 132 | ; be used if the sending side can create jitter and jbforce is 133 | ; also set to yes. 134 | 135 | ; jbforce = no ; Forces the use of a jitterbuffer on the receive side of a H323 136 | ; channel. Defaults to "no". 137 | 138 | ; jbmaxsize = 200 ; Max length of the jitterbuffer in milliseconds. 139 | 140 | ; jbresyncthreshold = 1000 ; Jump in the frame timestamps over which the jitterbuffer is 141 | ; resynchronized. Useful to improve the quality of the voice, with 142 | ; big jumps in/broken timestamps, usualy sent from exotic devices 143 | ; and programs. Defaults to 1000. 144 | 145 | ; jbimpl = fixed ; Jitterbuffer implementation, used on the receiving side of a H323 146 | ; channel. Two implementations are currenlty available - "fixed" 147 | ; (with size always equals to jbmax-size) and "adaptive" (with 148 | ; variable size, actually the new jb of IAX2). Defaults to fixed. 149 | 150 | ; jblog = no ; Enables jitterbuffer frame logging. Defaults to "no". 151 | ;----------------------------------------------------------------------------------- 152 | ; 153 | ; H.323 Alias definitions 154 | ; 155 | ; Type 'h323' will register aliases to the endpoint 156 | ; and Gatekeeper, if there is one. 157 | ; 158 | ; Example: if someone calls time@your.asterisk.box.com 159 | ; Asterisk will send the call to the extension 'time' 160 | ; in the context default 161 | ; 162 | ; [default] 163 | ; exten => time,1,Answer 164 | ; exten => time,2,Playback,current-time 165 | ; 166 | ; Keyword's 'prefix' and 'e164' are only make sense when 167 | ; used with a gatekeeper. You can specify either a prefix 168 | ; or E.164 this endpoint is responsible for terminating. 169 | ; 170 | ; Example: The H.323 alias 'det-gw' will tell the gatekeeper 171 | ; to route any call with the prefix 1248 to this alias. Keyword 172 | ; e164 is used when you want to specifiy a full telephone 173 | ; number. So a call to the number 18102341212 would be 174 | ; routed to the H.323 alias 'time'. 175 | ; 176 | ;[time] 177 | ;type=h323 178 | ;e164=18102341212 179 | ;context=default 180 | ; 181 | ;[det-gw] 182 | ;type=h323 183 | ;prefix=1248,1313 184 | ;context=detroit 185 | ; 186 | ; 187 | ; Inbound H.323 calls from BillyBob would land in the incoming 188 | ; context with a maximum of 4 concurrent incoming calls 189 | ; 190 | ; 191 | ; Note: If keyword 'incominglimit' are omitted Asterisk will not 192 | ; enforce any maximum number of concurrent calls. 193 | ; 194 | ;[BillyBob] 195 | ;type=user 196 | ;host=192.168.1.1 197 | ;context=incoming 198 | ;incominglimit=4 199 | ;h245Tunneling=no 200 | ; 201 | ; 202 | ; Outbound H.323 call to Larry using SlowStart 203 | ; 204 | ;[Larry] 205 | ;type=peer 206 | ;host=192.168.2.1 207 | ;fastStart=no 208 | 209 | 210 | 211 | -------------------------------------------------------------------------------- /asterisk/dundi.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; DUNDi configuration file 3 | ; 4 | ; For more information about DUNDi, see http://www.dundi.com 5 | ; 6 | ; 7 | [general] 8 | ; 9 | ; The "general" section contains general parameters relating 10 | ; to the operation of the dundi client and server. 11 | ; 12 | ; The first part should be your complete contact information 13 | ; should someone else in your peer group need to contact you. 14 | ; 15 | ;department=Your Department 16 | ;organization=Your Company, Inc. 17 | ;locality=Your City 18 | ;stateprov=ST 19 | ;country=US 20 | ;email=your@email.com 21 | ;phone=+12565551212 22 | ; 23 | ; 24 | ; Specify bind address and port number. Default is 25 | ; 4520 26 | ; 27 | ;bindaddr=0.0.0.0 28 | ;port=4520 29 | ; 30 | ; See https://wiki.asterisk.org/wiki/display/AST/IP+Quality+of+Service for a description of the tos parameter. 31 | ;tos=ef 32 | ; 33 | ; Our entity identifier (Should generally be the MAC address of the 34 | ; machine it's running on. Defaults to the first eth address, but you 35 | ; can override it here, as long as you set it to the MAC of *something* 36 | ; you own!) The EID can be overridden by a setting in asterisk.conf, 37 | ; or by setting this option. 38 | ; 39 | ;entityid=00:07:E9:3B:76:60 40 | ; 41 | ; Peers shall cache our query responses for the specified time, 42 | ; given in seconds. Default is 3600. 43 | ; 44 | ;cachetime=3600 45 | ; 46 | ; This defines the max depth in which to search the DUNDi system. 47 | ; Note that the maximum time that we will wait for a response is 48 | ; (2000 + 200 * ttl) ms. 49 | ; 50 | ttl=32 51 | ; 52 | ; If we don't get ACK to our DPDISCOVER within 2000ms, and autokill is set 53 | ; to yes, then we cancel the whole thing (that's enough time for one 54 | ; retransmission only). This is used to keep things from stalling for a long 55 | ; time for a host that is not available, but would be ill advised for bad 56 | ; connections. In addition to 'yes' or 'no' you can also specify a number 57 | ; of milliseconds. See 'qualify' for individual peers to turn on for just 58 | ; a specific peer. 59 | ; 60 | autokill=yes 61 | ; 62 | ; pbx_dundi creates a rotating key called "secret", under the family 63 | ; 'secretpath'. The default family is dundi (resulting in 64 | ; the key being held at dundi/secret). 65 | ; 66 | ;secretpath=dundi 67 | ; 68 | ; The 'storehistory' option (also changeable at runtime with 69 | ; 'dundi store history' and 'dundi no store history') will 70 | ; cause the DUNDi engine to keep track of the last several 71 | ; queries and the amount of time each query took to execute 72 | ; for the purpose of tracking slow nodes. This option is 73 | ; off by default due to performance impacts. 74 | ; 75 | ;storehistory=yes 76 | 77 | [mappings] 78 | ; 79 | ; The "mappings" section maps DUNDi contexts 80 | ; to contexts on the local asterisk system. Remember 81 | ; that numbers that are made available under the e164 82 | ; DUNDi context are regulated by the DUNDi General Peering 83 | ; Agreement (GPA) if you are a member of the DUNDi E.164 84 | ; Peering System. 85 | ; 86 | ; dundi_context => local_context,weight,tech,dest[,options]] 87 | ; 88 | ; 'dundi_context' is the name of the context being requested 89 | ; within the DUNDi request 90 | ; 91 | ; 'local_context' is the name of the context on the local system 92 | ; in which numbers can be looked up for which responses shall be given. 93 | ; 94 | ; 'weight' is the weight to use for the responses provided from this 95 | ; mapping. The number must be >= 0 and < 60000. Since it is totally 96 | ; valid to receive multiple responses to a query, responses received 97 | ; with a lower weight are tried first. Note that the weight has a 98 | ; special meaning in the e164 context - see the GPA for more details. 99 | ; 100 | ; 'tech' is the technology to use (IAX, SIP, H323) 101 | ; 102 | ; 'dest' is the destination to supply for reaching that number. The 103 | ; following variables can be used in the destination string and will 104 | ; be automatically substituted: 105 | ; ${NUMBER}: The number being requested 106 | ; ${IPADDR}: The IP address to connect to 107 | ; ${SECRET}: The current rotating secret key to be used 108 | ; 109 | ; Further options may include: 110 | ; 111 | ; nounsolicited: No unsolicited calls of any type permitted via this 112 | ; route 113 | ; nocomunsolicit: No commercial unsolicited calls permitted via 114 | ; this route 115 | ; residential: This number is known to be a residence 116 | ; commercial: This number is known to be a business 117 | ; mobile: This number is known to be a mobile phone 118 | ; nocomunsolicit: No commercial unsolicited calls permitted via 119 | ; this route 120 | ; nopartial: Do not search for partial matches 121 | ; 122 | ; There *must* exist an entry in mappings for DUNDi to respond 123 | ; to any request, although it may be empty. 124 | ; 125 | ;e164 => dundi-e164-canonical,0,IAX2,dundi:${SECRET}@${IPADDR}/${NUMBER},nounsolicited,nocomunsolicit,nopartial 126 | ;e164 => dundi-e164-customers,100,IAX2,dundi:${SECRET}@${IPADDR}/${NUMBER},nounsolicited,nocomunsolicit,nopartial 127 | ;e164 => dundi-e164-via-pstn,400,IAX2,dundi:${SECRET}@${IPADDR}/${NUMBER},nounsolicited,nocomunsolicit,nopartial 128 | 129 | ;digexten => default,0,IAX2,guest@lappy/${NUMBER} 130 | ;asdf => 131 | 132 | ; 133 | ; Weights for mappings can be set a few different ways: 134 | ; 135 | ; 1) It can be set as a static number. 136 | ;testmap1 => context1,222,IAX2,guest@peer1/${NUMBER} 137 | ; 138 | ; 2) It can be an Asterisk global variable. 139 | ;testmap2 => context2,${DUNDITESTVAR},IAX2,guest@peer2${NUMBER} 140 | ; 141 | ; 3) It can be retrieved using a dialplan function. This can be extremely 142 | ; useful if you want to let an external script decide what the weight 143 | ; in a response shouuld be. 144 | ;testmap3 => context3,${SHELL(echo 123)},IAX2,guest@peer3/${NUMBER} 145 | ; 146 | ; Note than when using a global variable or dialplan function to set the 147 | ; weight for a mapping, that response caching should be disabled if you 148 | ; plan for these values to change frequently at all. If the results are 149 | ; cached, then any change in value will not take effect until the cache 150 | ; has expired. 151 | ; 152 | 153 | ; 154 | ; The remaining sections represent the peers 155 | ; that we fundamentally trust. The section name 156 | ; represents the name and optionally at a specific 157 | ; DUNDi context if you want the trust to be established 158 | ; for only a specific DUNDi context. 159 | ; 160 | ; inkey - What key they will be authenticating to us with 161 | ; 162 | ; outkey - What key we use to authenticate to them 163 | ; 164 | ; host - What their host is 165 | ; 166 | ; port - The port where their host is listening (default: 4520) 167 | ; 168 | ; order - What search order to use. May be 'primary', 'secondary', 169 | ; 'tertiary' or 'quartiary'. In large systems, it is beneficial 170 | ; to only query one up-stream host in order to maximize caching 171 | ; value. Adding one with primary and one with secondary gives you 172 | ; redundancy without sacrificing performance. 173 | ; 174 | ; include - Includes this peer when searching a particular context 175 | ; for lookup (set "all" to perform all lookups with that 176 | ; host. This is also the context in which peers are permitted 177 | ; to precache. 178 | ; 179 | ; noinclude - Disincludes this peer when searching a particular context 180 | ; for lookup (set "all" to perform no lookups with that 181 | ; host. 182 | ; 183 | ; permit - Permits this peer to search a given DUNDi context on 184 | ; the local system. Set "all" to permit this host to 185 | ; lookup all contexts. This is also a context for which 186 | ; we will create/forward PRECACHE commands. 187 | ; 188 | ; deny - Denies this peer to search a given DUNDi context on 189 | ; the local system. Set "all" to deny this host to 190 | ; lookup all contexts. 191 | ; 192 | ; model - inbound, outbound, or symmetric for whether we receive 193 | ; requests only, transmit requests only, or do both. 194 | ; 195 | ; precache - Utilize/Permit precaching with this peer (to pre 196 | ; cache means to provide an answer when no request 197 | ; was made and is used so that machines with few 198 | ; routes can push those routes up a to a higher level). 199 | ; outgoing means we send precache routes to this peer, 200 | ; incoming means we permit this peer to send us 201 | ; precache routes. symmetric means we do both. 202 | ; 203 | ; Note: You cannot mix symmetric/outbound model with symmetric/inbound 204 | ; precache, nor can you mix symmetric/inbound model with symmetric/outbound 205 | ; precache. 206 | ; 207 | ; 208 | ; The '*' peer is special and matches an unspecified entity 209 | ; 210 | 211 | ; 212 | ; Sample Primary e164 DUNDi peer 213 | ; 214 | ;[00:50:8B:F3:75:BB] 215 | ;model = symmetric 216 | ;host = 64.215.96.114 217 | ;inkey = digium 218 | ;outkey = misery 219 | ;include = e164 220 | ;permit = e164 221 | ;qualify = yes 222 | 223 | ; 224 | ; Sample Secondary e164 DUNDi peer 225 | ; 226 | ;[00:A0:C9:96:92:84] 227 | ;model = symmetric 228 | ;host = misery.digium.com 229 | ;inkey = misery 230 | ;outkey = ourkey 231 | ;include = e164 232 | ;permit = e164 233 | ;qualify = yes 234 | ;order = secondary 235 | 236 | ; 237 | ; Sample "push mode" downstream host 238 | ; 239 | ;[00:0C:76:96:75:28] 240 | ;model = inbound 241 | ;host = dynamic 242 | ;precache = inbound 243 | ;inkey = littleguy 244 | ;outkey = ourkey 245 | ;include = e164 ; In this case used only for precaching 246 | ;permit = e164 247 | ;qualify = yes 248 | 249 | ; 250 | ; Sample "push mode" upstream host 251 | ; 252 | ;[00:07:E9:3B:76:60] 253 | ;model = outbound 254 | ;precache = outbound 255 | ;host = 216.207.245.34 256 | ;register = yes 257 | ;inkey = dhcp34 258 | ;permit = all ; In this case used only for precaching 259 | ;include = all 260 | ;qualify = yes 261 | ;outkey=foo 262 | 263 | ;[*] 264 | ; 265 | -------------------------------------------------------------------------------- /asterisk/features.conf: -------------------------------------------------------------------------------- 1 | ; 2 | ; Sample Call Features (parking, transfer, etc) configuration 3 | ; 4 | 5 | [general] 6 | parkext => 700 ; What extension to dial to park. Set per parking lot. 7 | ;parkext_exclusive=yes ; Specify that the parkext created for this parking lot 8 | ; will only access this parking lot. (default is no) 9 | parkpos => 701-720 ; What extensions to park calls on. (defafult parking lot) 10 | ; These need to be numeric, as Asterisk starts from the start position 11 | ; and increments with one for the next parked call. 12 | ; Set per parking lot. 13 | context => parkedcalls ; Which context parked calls are in (default parking lot) 14 | ; Set per parking lot. 15 | ;parkinghints = no ; Add hints priorities automatically for parking slots (default is no). 16 | ; Set per parking lot. 17 | ;parkingtime => 45 ; Number of seconds a call can be parked before returning. 18 | ; Set per parking lot. (default is 45 seconds) 19 | 20 | ;comebacktoorigin = yes ; Setting this option configures the behavior of call parking when the 21 | ; parked call times out (See the parkingtime option). The default value is 'yes'. 22 | ; Operates on all parking lots. 23 | ; 24 | ; 'yes' - When the parked call times out, attempt to send the call back to the peer 25 | ; that parked this call. This is done by saving off the name of the channel 26 | ; that parked the call. 27 | ; 28 | ; 'no' - This option is useful for performing custom dialplan functionality prior to 29 | ; sending the call back to the extension that initially parked the call, or to 30 | ; an entirely different destination. 31 | ; 32 | ; When the parked call times out, send it back to the dialplan. The location 33 | ; will be the 'parkedcallstimeout' context. The extension will be built from 34 | ; the saved channel name that parked the call. For example, if a SIP peer named 35 | ; '0004F2040001' parked this call, the extension will be 'SIP_0004F2040001'. 36 | ; (Note that an underscore is used here because the '/' character has a special 37 | ; meaning in extension names for CallerID matching.) If this extension does not 38 | ; exist, the call will be sent to the 's' extension, instead. Finally, if the 's' 39 | ; extension of 'parkedcallstimeout' does not exist, the call will fall back to the 40 | ; 's' extension of the 'default' context. 41 | ; 42 | ; Additionally, in this example an extension of 'SIP_0004F2040001' will be 43 | ; created in the 'park-dial' context. This extension will be set up to do a 44 | ; Dial() to 'SIP/0004F2040001'. 45 | ; 46 | ; During the timeout procedure, the following variable is set 47 | ; PARKINGSLOT - extension that the call was parked in prior to timing out 48 | 49 | ;courtesytone = beep ; Sound file to play to when someone picks up a parked call 50 | ; and also when the Touch Monitor is activated/deactivated. 51 | ; Default is no tone. 52 | ;parkedplay = caller ; Who to play courtesytone to when picking up a parked call. 53 | ; One of: parked, caller, both (default is caller) 54 | ; Operates on all parking lots. 55 | ;parkedcalltransfers = caller ; Enables or disables DTMF based transfers when picking up a parked call. 56 | ; one of: callee, caller, both, no (default is no) 57 | ; Set per parking lot. 58 | ;parkedcallreparking = caller ; Enables or disables DTMF based parking when picking up a parked call. 59 | ; one of: callee, caller, both, no (default is no) 60 | ; Set per parking lot. 61 | ;parkedcallhangup = caller ; Enables or disables DTMF based hangups when picking up a parked call. 62 | ; one of: callee, caller, both, no (default is no) 63 | ; Set per parking lot. 64 | ;parkedcallrecording = caller ; Enables or disables DTMF based one-touch recording when picking up a parked call. 65 | ; one of: callee, caller, both, no (default is no) 66 | ; Set per parking lot. 67 | ;parkeddynamic = yes ; Enables dynamically created parkinglots. (default is no) 68 | ; Operates on all parking lots. 69 | ;adsipark = yes ; if you want ADSI parking announcements 70 | ; Operates on all parking lots. 71 | ;findslot => next ; Continue to the 'next' free parking space. 72 | ; Defaults to 'first' available 73 | ; Set per parking lot. 74 | ;parkedmusicclass=default ; This is the MOH class to use for the parked channel 75 | ; as long as the class is not set on the channel directly 76 | ; using Set(CHANNEL(musicclass)=whatever) in the dialplan 77 | ; Set per parking lot. 78 | 79 | ;transferdigittimeout => 3 ; Number of seconds to wait between digits when transferring a call 80 | ; (default is 3 seconds) 81 | ;xfersound = beep ; to indicate an attended transfer is complete 82 | ;xferfailsound = beeperr ; to indicate a failed transfer 83 | ;pickupexten = *8 ; Configure the pickup extension. (default is *8) 84 | ;pickupsound = beep ; to indicate a successful pickup (default: no sound) 85 | ;pickupfailsound = beeperr ; to indicate that the pickup failed (default: no sound) 86 | ;featuredigittimeout = 1000 ; Max time (ms) between digits for 87 | ; feature activation (default is 1000 ms) 88 | ;atxfernoanswertimeout = 15 ; Timeout for answer on attended transfer default is 15 seconds. 89 | ;atxferdropcall = no ; If someone does an attended transfer, then hangs up before the transferred 90 | ; caller is connected, then by default, the system will try to call back the 91 | ; person that did the transfer. If this is set to "yes", the callback will 92 | ; not be attempted and the transfer will just fail. 93 | ; For atxferdropcall=no to work properly, you also need to 94 | ; define ATXFER_NULL_TECH in main/features.c. The reason the 95 | ; code is not enabled by default is spelled out in the comment 96 | ; block near the top of main/features.c describing ATXFER_NULL_TECH. 97 | ;atxferloopdelay = 10 ; Number of seconds to sleep between retries (if atxferdropcall = no) 98 | ;atxfercallbackretries = 2 ; Number of times to attempt to send the call back to the transferer. 99 | ; By default, this is 2. 100 | 101 | ; 102 | ;*** Define another parking lot 103 | ; 104 | ; You can set parkinglot with the CHANNEL dialplan function 105 | ; or by setting 'parkinglot' directly in the channel configuration file. 106 | ; 107 | ; (Note: Leading '0's and any non-numerical characters on parkpos extensions 108 | ; will be ignored. Parkext on the other hand can be any string.) 109 | ; 110 | ;[parkinglot_edvina] 111 | ;context => edvinapark 112 | ;parkext => 799 113 | ;parkpos => 800-850 114 | ;findslot => next 115 | 116 | ; Note that the DTMF features listed below only work when two channels have answered and are bridged together. 117 | ; They can not be used while the remote party is ringing or in progress. If you require this feature you can use 118 | ; chan_local in combination with Answer to accomplish it. 119 | 120 | 121 | [featuremap] 122 | ;blindxfer => #1 ; Blind transfer (default is #) -- Make sure to set the T and/or t option in the Dial() or Queue() app call! 123 | ;disconnect => *0 ; Disconnect (default is *) -- Make sure to set the H and/or h option in the Dial() or Queue() app call! 124 | ;automon => *1 ; One Touch Record a.k.a. Touch Monitor -- Make sure to set the W and/or w option in the Dial() or Queue() app call! 125 | ;atxfer => *2 ; Attended transfer -- Make sure to set the T and/or t option in the Dial() or Queue() app call! 126 | ;parkcall => #72 ; Park call (one step parking) -- Make sure to set the K and/or k option in the Dial() app call! 127 | ;automixmon => *3 ; One Touch Record a.k.a. Touch MixMonitor -- Make sure to set the X and/or x option in the Dial() or Queue() app call! 128 | 129 | [applicationmap] 130 | ; Note that the DYNAMIC_FEATURES channel variable must be set to use the features 131 | ; defined here. The value of DYNAMIC_FEATURES should be the names of the features 132 | ; to allow the channel to use separated by '#'. For example: 133 | ; 134 | ; Set(__DYNAMIC_FEATURES=myfeature1#myfeature2#myfeature3) 135 | ; 136 | ; (Note: The two leading underscores allow these feature settings to be set on 137 | ; on the outbound channels, as well. Otherwise, only the original channel 138 | ; will have access to these features.) 139 | ; 140 | ; The syntax for declaring a dynamic feature is any of the following: 141 | ; 142 | ; => ,[/],[,[,MOH_Class]] 143 | ; => ,[/],[,""[,MOH_Class]] 144 | ; => ,[/],([])[,MOH_Class] 145 | 146 | ; 147 | ; FeatureName -> This is the name of the feature used when setting the 148 | ; DYNAMIC_FEATURES variable to enable usage of this feature. 149 | ; DTMF_sequence -> This is the key sequence used to activate this feature. 150 | ; ActivateOn -> This is the channel of the call that the application will be executed 151 | ; on. Valid values are "self" and "peer". "self" means run the 152 | ; application on the same channel that activated the feature. "peer" 153 | ; means run the application on the opposite channel from the one that 154 | ; has activated the feature. 155 | ; ActivatedBy -> This is which channel is allowed to activate this feature. Valid 156 | ; values are "caller", "callee", and "both". "both" is the default. 157 | ; The "caller" is the channel that executed the Dial application, while 158 | ; the "callee" is the channel called by the Dial application. 159 | ; Application -> This is the application to execute. 160 | ; AppArguments -> These are the arguments to be passed into the application. If you need 161 | ; commas in your arguments, you should use either the second or third 162 | ; syntax, above. 163 | ; MOH_Class -> This is the music on hold class to play while the idle 164 | ; channel waits for the feature to complete. If left blank, 165 | ; no music will be played. 166 | ; 167 | 168 | ; 169 | ; IMPORTANT NOTE: The applicationmap is not intended to be used for all Asterisk 170 | ; applications. When applications are used in extensions.conf, they are executed 171 | ; by the PBX core. In this case, these applications are executed outside of the 172 | ; PBX core, so it does *not* make sense to use any application which has any 173 | ; concept of dialplan flow. Examples of this would be things like Macro, Goto, 174 | ; Background, WaitExten, and many more. 175 | ; 176 | ; Enabling these features means that the PBX needs to stay in the media flow and 177 | ; media will not be re-directed if DTMF is sent in the media stream. 178 | ; 179 | ; Example Usage: 180 | ; 181 | ;testfeature => #9,peer,Playback,tt-monkeys ;Allow both the caller and callee to play 182 | ; ;tt-monkeys to the opposite channel 183 | ; 184 | ; Set arbitrary channel variables, based upon CALLERID number (Note that the application 185 | ; argument contains commas) 186 | ;retrieveinfo => #8,peer,Set(ARRAY(CDR(mark),CDR(name))=${ODBC_FOO(${CALLERID(num)})}) 187 | ; 188 | ;pauseMonitor => #1,self/callee,Pausemonitor ;Allow the callee to pause monitoring 189 | ; ;on their channel 190 | ;unpauseMonitor => #3,self/callee,UnPauseMonitor ;Allow the callee to unpause monitoring 191 | ; ;on their channel 192 | 193 | ; Dynamic Feature Groups: 194 | ; Dynamic feature groups are groupings of features defined in [applicationmap] 195 | ; that can have their own custom key mappings. To give a channel access to a dynamic 196 | ; feature group, add the group name to the value of the DYNAMIC_FEATURES variable. 197 | ; 198 | ; example: 199 | ; [myGroupName] ; defines the group named myGroupName 200 | ; testfeature => #9 ; associates testfeature with the group and the keycode '#9'. 201 | ; pauseMonitor => ; associates pauseMonitor with the group and uses the keycode specified 202 | ; ; in the [applicationmap]. 203 | -------------------------------------------------------------------------------- /asterisk/extensions.ael: -------------------------------------------------------------------------------- 1 | // 2 | // Example AEL config file 3 | // 4 | // 5 | // Static extension configuration file, used by 6 | // the pbx_ael module. This is where you configure all your 7 | // inbound and outbound calls in Asterisk. 8 | // 9 | // This configuration file is reloaded 10 | // - With the "ael reload" command in the CLI 11 | // - With the "reload" command (that reloads everything) in the CLI 12 | 13 | // The "Globals" category contains global variables that can be referenced 14 | // in the dialplan by using the GLOBAL dialplan function: 15 | // ${GLOBAL(VARIABLE)} 16 | // ${${GLOBAL(VARIABLE)}} or ${text${GLOBAL(VARIABLE)}} or any hybrid 17 | // Unix/Linux environmental variables are reached with the ENV dialplan 18 | // function: ${ENV(VARIABLE)} 19 | // 20 | 21 | // NOTE! NOTE! NOTE! 22 | // Asterisk by default will load both extensions.conf and extensions.ael files. 23 | // Upon loading these files the dialplans generated from both with be merged, 24 | // so you must make sure that you don't have any overlapping contexts or global 25 | // variables. If you do, then unexpected behavior may result when the data is 26 | // merged. 27 | // NOTE! NOTE! NOTE! 28 | 29 | globals { 30 | CONSOLE-AEL="Console/dsp"; // Console interface for demo 31 | //CONSOLE-AEL=Zap/1; 32 | //CONSOLE-AEL=Phone/phone0; 33 | IAXINFO-AEL=guest; // IAXtel username/password 34 | //IAXINFO-AEL="myuser:mypass"; 35 | OUTBOUND-TRUNK="Zap/g2"; // Trunk interface 36 | // 37 | // Note the 'g2' in the OUTBOUND-TRUNK variable above. It specifies which group (defined 38 | // in chan_dahdi.conf) to dial, i.e. group 2, and how to choose a channel to use in 39 | // the specified group. The four possible options are: 40 | // 41 | // g: select the lowest-numbered non-busy DAHDI channel 42 | // (aka. ascending sequential hunt group). 43 | // G: select the highest-numbered non-busy DAHDI channel 44 | // (aka. descending sequential hunt group). 45 | // r: use a round-robin search, starting at the next highest channel than last 46 | // time (aka. ascending rotary hunt group). 47 | // R: use a round-robin search, starting at the next lowest channel than last 48 | // time (aka. descending rotary hunt group). 49 | // 50 | OUTBOUND-TRUNKMSD=1; // MSD digits to strip (usually 1 or 0) 51 | //OUTBOUND-TRUNK2=IAX2/user:pass@provider; 52 | }; 53 | 54 | // 55 | // Any category other than "General" and "Globals" represent 56 | // extension contexts, which are collections of extensions. 57 | // 58 | // Extension names may be numbers, letters, or combinations 59 | // thereof. If an extension name is prefixed by a '_' 60 | // character, it is interpreted as a pattern rather than a 61 | // literal. In patterns, some characters have special meanings: 62 | // 63 | // X - any digit from 0-9 64 | // Z - any digit from 1-9 65 | // N - any digit from 2-9 66 | // [1235-9] - any digit in the brackets (in this example, 1,2,3,5,6,7,8,9) 67 | // . - wildcard, matches anything remaining (e.g. _9011. matches 68 | // anything starting with 9011 excluding 9011 itself) 69 | // ! - wildcard, causes the matching process to complete as soon as 70 | // it can unambiguously determine that no other matches are possible 71 | // 72 | // For example the extension _NXXXXXX would match normal 7 digit dialings, 73 | // while _1NXXNXXXXXX would represent an area code plus phone number 74 | // preceded by a one. 75 | // 76 | // Each step of an extension is ordered by priority, which must 77 | // always start with 1 to be considered a valid extension. The priority 78 | // "next" or "n" means the previous priority plus one, regardless of whether 79 | // the previous priority was associated with the current extension or not. 80 | // The priority "same" or "s" means the same as the previously specified 81 | // priority, again regardless of whether the previous entry was for the 82 | // same extension. Priorities may be immediately followed by a plus sign 83 | // and another integer to add that amount (most useful with 's' or 'n'). 84 | // Priorities may then also have an alias, or label, in 85 | // parenthesis after their name which can be used in goto situations 86 | // 87 | // Contexts contain several lines, one for each step of each 88 | // extension, which can take one of two forms as listed below, 89 | // with the first form being preferred. One may include another 90 | // context in the current one as well, optionally with a 91 | // date and time. Included contexts are included in the order 92 | // they are listed. 93 | // 94 | //context name { 95 | // exten-name => { 96 | // application(arg1,arg2,...); 97 | // 98 | // Timing list for includes is 99 | // 100 | //