iax.conf.sample 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286
  1. ; Inter-Asterisk eXchange driver definition
  2. ;
  3. ; This configuration is re-read at reload
  4. ; or with the CLI command
  5. ; reload chan_iax2.so
  6. ;
  7. ; General settings, like port number to bind to, and
  8. ; an option address (the default is to bind to all
  9. ; local addresses).
  10. ;
  11. [general]
  12. ;bindport=4569
  13. ;bindaddr=192.168.0.1
  14. ;
  15. ; Set iaxcompat to yes if you plan to use layered
  16. ; switches. It incurs a small performance hit to enable it
  17. ;
  18. ;iaxcompat=yes
  19. ;
  20. ; For increased security against brute force password attacks
  21. ; enable "delayreject" which will delay the sending of authentication
  22. ; reject for REGREQ or AUTHREP if there is a password.
  23. ;
  24. ;delayreject=yes
  25. ;
  26. ; You may specify a global default AMA flag for iaxtel calls. It must be
  27. ; one of 'default', 'omit', 'billing', or 'documentation'. These flags
  28. ; are used in the generation of call detail records.
  29. ;
  30. ;amaflags=default
  31. ;
  32. ; You may specify a default account for Call Detail Records in addition
  33. ; to specifying on a per-user basis
  34. ;
  35. ;accountcode=lss0101
  36. ;
  37. ; You may specify a global default language for users.
  38. ; Can be specified also on a per-user basis
  39. ; If omitted, will fallback to english
  40. ;
  41. ;language=en
  42. ;
  43. ; Specify bandwidth of low, medium, or high to control which codecs are used
  44. ; in general.
  45. ;
  46. bandwidth=low
  47. ;
  48. ; You can also fine tune codecs here using "allow" and "disallow" clauses
  49. ; with specific codecs. Use "all" to represent all formats.
  50. ;
  51. ;allow=all ; same as bandwidth=high
  52. ;disallow=g723.1 ; Hm... Proprietary, don't use it...
  53. disallow=lpc10 ; Icky sound quality... Mr. Roboto.
  54. ;allow=gsm ; Always allow GSM, it's cool :)
  55. ;
  56. ; You can adjust several parameters relating to the jitter buffer.
  57. ; The jitter buffer's function is to compensate for varying
  58. ; network delay.
  59. ;
  60. ; All the jitter buffer settings except dropcount are in milliseconds.
  61. ; The jitter buffer works for INCOMING audio - the outbound audio
  62. ; will be dejittered by the jitter buffer at the other end.
  63. ;
  64. ; jitterbuffer=yes|no: global default as to whether you want
  65. ; the jitter buffer at all.
  66. ;
  67. ; dropcount: the jitter buffer is sized such that no more than "dropcount"
  68. ; frames would have been "too late" over the last 2 seconds.
  69. ; Set to a small number. "3" represents 1.5% of frames dropped
  70. ;
  71. ; maxjitterbuffer: a maximum size for the jitter buffer.
  72. ; Setting a reasonable maximum here will prevent the call delay
  73. ; from rising to silly values in extreme situations; you'll hear
  74. ; SOMETHING, even though it will be jittery.
  75. ;
  76. ; maxexcessbuffer: If conditions improve after a period of high jitter,
  77. ; the jitter buffer can end up bigger than necessary. If it ends up
  78. ; more than "maxexcessbuffer" bigger than needed, Asterisk will start
  79. ; gradually decreasing the amount of jitter buffering.
  80. ;
  81. ; minexcessbuffer: Sets a desired mimimum amount of headroom in
  82. ; the jitter buffer. If Asterisk has less headroom than this, then
  83. ; it will start gradually increasing the amount of jitter buffering.
  84. ;
  85. ; jittershrinkrate: when the jitter buffer is being gradually shrunk
  86. ; (or enlarged), how many millisecs shall we take off per 20ms frame
  87. ; received? Use a small number, or you will be able to hear it
  88. ; changing. An example: if you set this to 2, then the jitter buffer
  89. ; size will change by 100 millisecs per second.
  90. jitterbuffer=no
  91. ;dropcount=2
  92. ;maxjitterbuffer=500
  93. ;maxexcessbuffer=80
  94. ;minexcessbuffer=10
  95. ;jittershrinkrate=1
  96. ;trunkfreq=20 ; How frequently to send trunk msgs (in ms)
  97. ;
  98. ;
  99. ; We can register with another IAX server to let him know where we are
  100. ; in case we have a dynamic IP address for example
  101. ;
  102. ; Register with tormenta using username marko and password secretpass
  103. ;
  104. ;register => marko:secretpass@tormenta.linux-support.net
  105. ;
  106. ; Register joe at remote host with no password
  107. ;
  108. ;register => joe@remotehost:5656
  109. ;
  110. ; Register marko at tormenta.linux-support.net using RSA key "torkey"
  111. ;
  112. ;register => marko:[torkey]@tormenta.linux-support.net
  113. ;
  114. ; Sample Registration for iaxtel
  115. ;
  116. ; Visit http://www.iaxtel.com to register with iaxtel. Replace "user"
  117. ; and "pass" with your username and password for iaxtel. Incoming
  118. ; calls arrive at the "s" extension of "default" context.
  119. ;
  120. ;register => user:pass@iaxtel.com
  121. ;
  122. ; Sample Registration for IAX + FWD
  123. ;
  124. ; To register using IAX with FWD, it must be enabled by visiting the URL
  125. ; http://www.fwdnet.net/index.php?section_id=112
  126. ;
  127. ; Note that you need an extension in you default context which matches
  128. ; your free world dialup number. Please replace "FWDNumber" with your
  129. ; FWD number and "passwd" with your password.
  130. ;
  131. ;register => FWDNumber:passwd@iax.fwdnet.net
  132. ;
  133. ;
  134. ; You can disable authentication debugging to reduce the amount of
  135. ; debugging traffic.
  136. ;
  137. ;authdebug=no
  138. ;
  139. ; Finally, you can set values for your TOS bits to help improve
  140. ; performance. Valid values are:
  141. ; lowdelay -- Minimize delay
  142. ; throughput -- Maximize throughput
  143. ; reliability -- Maximize reliability
  144. ; mincost -- Minimize cost
  145. ; none -- No flags
  146. ;
  147. tos=lowdelay
  148. ;
  149. ; If mailboxdetail is set to "yes", the user receives
  150. ; the actual new/old message counts, not just a yes/no
  151. ; as to whether they have messages. this can be set on
  152. ; a per-peer basis as well
  153. ;
  154. ;mailboxdetail=yes
  155. ;
  156. ; If regcontext is specified, Asterisk will dynamically
  157. ; create and destroy a NoOp priority 1 extension for a given
  158. ; peer who registers or unregisters with us. The actual extension
  159. ; is the 'regexten' parameter of the registering peer or its
  160. ; name if 'regexten' is not provided. More than one regexten may be supplied
  161. ; if they are separated by '&'. Patterns may be used in regexten.
  162. ;
  163. ;regcontext=iaxregistrations
  164. ;
  165. ; Guest sections for unauthenticated connection attempts. Just
  166. ; specify an empty secret, or provide no secret section.
  167. ;
  168. [guest]
  169. type=user
  170. context=default
  171. callerid="Guest IAX User"
  172. ;
  173. ; Trust Caller*ID Coming from iaxtel.com
  174. ;
  175. [iaxtel]
  176. type=user
  177. context=default
  178. auth=rsa
  179. inkeys=iaxtel
  180. ;
  181. ; Trust Caller*ID Coming from iax.fwdnet.net
  182. ;
  183. [iaxfwd]
  184. type=user
  185. context=default
  186. auth=rsa
  187. inkeys=freeworlddialup
  188. ;
  189. ; Further user sections may be added, specifying a context and a
  190. ; secret used for connections with that given authentication name.
  191. ; Limited IP based access control is allowed by use of "allow" and
  192. ; "deny" keywords. Multiple rules are permitted. Multiple permitted
  193. ; contexts may be specified, in which case the first will be the default.
  194. ; You can also override caller*ID so that when you receive a call you
  195. ; set the Caller*ID to be what you want instead of trusting what
  196. ; the remote user provides
  197. ;
  198. ; There are three authentication methods that are supported: md5, plaintext,
  199. ; and rsa. The least secure is "plaintext", which sends passwords cleartext
  200. ; across the net. "md5" uses a challenge/response md5 sum arrangement, but
  201. ; still requires both ends have plain text access to the secret. "rsa" allows
  202. ; unidirectional secret knowledge through public/private keys. If "rsa"
  203. ; authentication is used, "inkeys" is a list of acceptable public keys on the
  204. ; local system that can be used to authenticate the remote peer, separated by
  205. ; the ":" character. "outkey" is a single, private key to use to authenticate
  206. ; to the other side. Public keys are named /var/lib/asterisk/keys/<name>.pub
  207. ; while private keys are named /var/lib/asterisk/keys/<name>.key. Private
  208. ; keys should always be 3DES encrypted.
  209. ;
  210. ;
  211. ;[markster]
  212. ;type=user
  213. ;context=default
  214. ;context=local
  215. ;auth=md5,plaintext,rsa
  216. ;secret=markpasswd
  217. ;notransfer=yes ; Disable IAX native transfer
  218. ;jitterbuffer=yes ; Override global setting an enable jitter buffer
  219. ; ; for this user
  220. ;callerid="Mark Spencer" <(256) 428-6275>
  221. ;deny=0.0.0.0/0.0.0.0
  222. ;accountcode=markster0101
  223. ;permit=209.16.236.73/255.255.255.0
  224. ;language=en ; Use english as default language
  225. ;
  226. ; Peers may also be specified, with a secret and
  227. ; a remote hostname.
  228. ;
  229. [demo]
  230. type=peer
  231. username=asterisk
  232. secret=supersecret
  233. host=216.207.245.47
  234. ;sendani=no
  235. ;host=asterisk.linux-support.net
  236. ;port=5036
  237. ;mask=255.255.255.255
  238. ;qualify=yes ; Make sure this peer is alive
  239. ;jitterbuffer=no ; Turn off jitter buffer for this peer
  240. ;
  241. ; Peers can remotely register as well, so that they can be
  242. ; mobile. Default IP's can also optionally be given but
  243. ; are not required. Caller*ID can be suggested to the other
  244. ; side as well if it is for example a phone instead of another
  245. ; PBX.
  246. ;
  247. ;[dynamichost]
  248. ;host=dynamic
  249. ;secret=mysecret
  250. ;mailbox=1234 ; Notify about mailbox 1234
  251. ;inkeys=key1:key2
  252. ;peercontext=local ; Default context to request for calls to peer
  253. ;defaultip=216.207.245.34
  254. ;callerid="Some Host" <(256) 428-6011>
  255. ;
  256. ;
  257. ;[biggateway]
  258. ;type=peer
  259. ;host=192.168.0.1
  260. ;context=*
  261. ;secret=myscret
  262. ;trunk=yes ; Use IAX2 trunking with this host
  263. ;
  264. ;
  265. ; Friends are a short cut for creating a user and
  266. ; a peer with the same values.
  267. ;
  268. ;[marko]
  269. ;type=friend
  270. ;host=dynamic
  271. ;regexten=1234
  272. ;secret=moofoo
  273. ;context=default
  274. ;permit=0.0.0.0/0.0.0.0