pjsip.conf.sample 65 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341
  1. ; PJSIP Configuration Samples and Quick Reference
  2. ;
  3. ; This file has several very basic configuration examples, to serve as a quick
  4. ; reference to jog your memory when you need to write up a new configuration.
  5. ; It is not intended to teach PJSIP configuration or serve as an exhaustive
  6. ; reference of options and potential scenarios.
  7. ;
  8. ; This file has two main sections.
  9. ; First, manually written examples to serve as a handy reference.
  10. ; Second, a list of all possible PJSIP config options by section. This is
  11. ; pulled from the XML config help. It only shows the synopsis for every item.
  12. ; If you want to see more detail please check the documentation sources
  13. ; mentioned at the top of this file.
  14. ; ============================================================================
  15. ; NOTICE NOTICE NOTICE NOTICE NOTICE NOTICE NOTICE NOTICE NOTICE NOTICE
  16. ;
  17. ; This file does not maintain the complete option documentation.
  18. ; ============================================================================
  19. ; Documentation
  20. ;
  21. ; The official documentation is at http://wiki.asterisk.org
  22. ; You can read the XML configuration help via Asterisk command line with
  23. ; "config show help res_pjsip", then you can drill down through the various
  24. ; sections and their options.
  25. ;
  26. ;========!!!!!!!!!!!!!!!!!!! SECURITY NOTICE !!!!!!!!!!!!!!!!!!!!===========
  27. ;
  28. ; At a minimum please read the file "README-SERIOUSLY.bestpractices.txt",
  29. ; located in the Asterisk source directory before starting Asterisk.
  30. ; Otherwise you risk allowing the security of the Asterisk system to be
  31. ; compromised. Beyond that please visit and read the security information on
  32. ; the wiki at: https://wiki.asterisk.org/wiki/x/EwFB
  33. ;
  34. ; A few basics to pay attention to:
  35. ;
  36. ; Anonymous Calls
  37. ;
  38. ; By default anonymous inbound calls via PJSIP are not allowed. If you want to
  39. ; route anonymous calls you'll need to define an endpoint named "anonymous".
  40. ; res_pjsip_endpoint_identifier_anonymous.so handles that functionality so it
  41. ; must be loaded. It is not recommended to accept anonymous calls.
  42. ;
  43. ; Access Control Lists
  44. ;
  45. ; See the example ACL configuration in this file. Read the configuration help
  46. ; for the section and all of its options. Look over the samples in acl.conf
  47. ; and documentation at https://wiki.asterisk.org/wiki/x/uA80AQ
  48. ; If possible, restrict access to only networks and addresses you trust.
  49. ;
  50. ; Dialplan Contexts
  51. ;
  52. ; When defining configuration (such as an endpoint) that links into
  53. ; dialplan configuration, be aware of what that dialplan does. It's easy to
  54. ; accidentally provide access to internal or outbound dialing extensions which
  55. ; could cost you severely. The "context=" line in endpoint configuration
  56. ; determines which dialplan context inbound calls will enter into.
  57. ;
  58. ;=============================================================================
  59. ; Overview of Configuration Section Types Used in the Examples
  60. ;
  61. ; * Transport "transport"
  62. ; * Configures res_pjsip transport layer interaction.
  63. ; * Endpoint "endpoint"
  64. ; * Configures core SIP functionality related to SIP endpoints.
  65. ; * Authentication "auth"
  66. ; * Stores inbound or outbound authentication credentials for use by trunks,
  67. ; endpoints, registrations.
  68. ; * Address of Record "aor"
  69. ; * Stores contact information for use by endpoints.
  70. ; * Endpoint Identification "identify"
  71. ; * Maps a host directly to an endpoint
  72. ; * Access Control List "acl"
  73. ; * Defines a permission list or references one stored in acl.conf
  74. ; * Registration "registration"
  75. ; * Contains information about an outbound SIP registration
  76. ; * Resource Lists
  77. ; * Contains information for configuring resource lists.
  78. ; * Phone Provisioning "phoneprov"
  79. ; * Contains information needed by res_phoneprov for autoprovisioning
  80. ; The following sections show example configurations for various scenarios.
  81. ; Most require a couple or more configuration types configured in concert.
  82. ;=============================================================================
  83. ; Naming of Configuration Sections
  84. ;
  85. ; Configuration section names are denoted with enclosing brackets,
  86. ; e.g. [6001]
  87. ; In most cases, you can name a section whatever makes sense to you. For example
  88. ; you might name a transport [transport-udp-nat] to help you remember how that
  89. ; section is being used. However, in some cases, ("endpoint" and "aor" types)
  90. ; the section name has a relationship to its function.
  91. ;
  92. ; Depending on the modules loaded, Asterisk can match SIP requests to an
  93. ; endpoint or aor in a few ways:
  94. ;
  95. ; 1) Match a section name for endpoint type sections to the username in the
  96. ; "From" header of inbound SIP requests.
  97. ; 2) Match a section name for aor type sections to the username in the "To"
  98. ; header of inbound SIP REGISTER requests.
  99. ; 3) With an identify type section configured, match an inbound SIP request of
  100. ; any type to an endpoint or aor based on the IP source address of the
  101. ; request.
  102. ;
  103. ; Note that sections can have the same name as long as their "type" options are
  104. ; set to different values. In most cases it makes sense to have associated
  105. ; configuration sections use the same name, as you'll see in the examples within
  106. ; this file.
  107. ;===============EXAMPLE TRANSPORTS============================================
  108. ;
  109. ; A few examples for potential transport options.
  110. ;
  111. ; For the NAT transport example, be aware that the options starting with
  112. ; the prefix "external_" will only apply to communication with addresses
  113. ; outside the range set with "local_net=".
  114. ;
  115. ; You can have more than one of any type of transport, as long as it doesn't
  116. ; use the same resources (bind address, port, etc) as the others.
  117. ; Basic UDP transport
  118. ;
  119. ;[transport-udp]
  120. ;type=transport
  121. ;protocol=udp ;udp,tcp,tls,ws,wss
  122. ;bind=0.0.0.0
  123. ; UDP transport behind NAT
  124. ;
  125. ;[transport-udp-nat]
  126. ;type=transport
  127. ;protocol=udp
  128. ;bind=0.0.0.0
  129. ;local_net=192.0.2.0/24
  130. ;external_media_address=203.0.113.1
  131. ;external_signaling_address=203.0.113.1
  132. ; Basic IPv6 UDP transport
  133. ;
  134. ;[transport-udp-ipv6]
  135. ;type=transport
  136. ;protocol=udp
  137. ;bind=::
  138. ; Example IPv4 TLS transport
  139. ;
  140. ;[transport-tls]
  141. ;type=transport
  142. ;protocol=tls
  143. ;bind=0.0.0.0
  144. ;cert_file=/path/mycert.crt
  145. ;priv_key_file=/path/mykey.key
  146. ;cipher=ADH-AES256-SHA,ADH-AES128-SHA
  147. ;method=tlsv1
  148. ;===============OUTBOUND REGISTRATION WITH OUTBOUND AUTHENTICATION============
  149. ;
  150. ; This is a simple registration that works with some SIP trunking providers.
  151. ; You'll need to set up the auth example "mytrunk_auth" below to enable outbound
  152. ; authentication. Note that we "outbound_auth=" use for outbound authentication
  153. ; instead of "auth=", which is for inbound authentication.
  154. ;
  155. ; If you are registering to a server from behind NAT, be sure you assign a transport
  156. ; that is appropriately configured with NAT related settings. See the NAT transport example.
  157. ;
  158. ; "contact_user=" sets the SIP contact header's user portion of the SIP URI
  159. ; this will affect the extension reached in dialplan when the far end calls you at this
  160. ; registration. The default is 's'.
  161. ;
  162. ; If you would like to enable line support and have incoming calls related to this
  163. ; registration go to an endpoint automatically the "line" and "endpoint" options must
  164. ; be set. The "endpoint" option specifies what endpoint the incoming call should be
  165. ; associated with.
  166. ;[mytrunk]
  167. ;type=registration
  168. ;transport=transport-udp
  169. ;outbound_auth=mytrunk_auth
  170. ;server_uri=sip:sip.example.com
  171. ;client_uri=sip:1234567890@sip.example.com
  172. ;contact_user=1234567890
  173. ;retry_interval=60
  174. ;forbidden_retry_interval=600
  175. ;expiration=3600
  176. ;line=yes
  177. ;endpoint=mytrunk
  178. ;[mytrunk_auth]
  179. ;type=auth
  180. ;auth_type=userpass
  181. ;password=1234567890
  182. ;username=1234567890
  183. ;realm=sip.example.com
  184. ;===============ENDPOINT CONFIGURED AS A TRUNK, OUTBOUND AUTHENTICATION=======
  185. ;
  186. ; This is one way to configure an endpoint as a trunk. It is set up with
  187. ; "outbound_auth=" to enable authentication when dialing out through this
  188. ; endpoint. There is no inbound authentication set up since a provider will
  189. ; not normally authenticate when calling you.
  190. ;
  191. ; The identify configuration enables IP address matching against this endpoint.
  192. ; For calls from a trunking provider, the From user may be different every time,
  193. ; so we want to match against IP address instead of From user.
  194. ;
  195. ; If you want the provider of your trunk to know where to send your calls
  196. ; you'll need to use an outbound registration as in the example above this
  197. ; section.
  198. ;
  199. ; NAT
  200. ;
  201. ; At a basic level configure the endpoint with a transport that is set up
  202. ; with the appropriate NAT settings. There may be some additional settings you
  203. ; need here based on your NAT/Firewall scenario. Look to the CLI config help
  204. ; "config show help res_pjsip endpoint" or on the wiki for other NAT related
  205. ; options and configuration. We've included a few below.
  206. ;
  207. ; AOR
  208. ;
  209. ; Endpoints use one or more AOR sections to store their contact details.
  210. ; You can define multiple contact addresses in SIP URI format in multiple
  211. ; "contact=" entries.
  212. ;
  213. ;[mytrunk]
  214. ;type=endpoint
  215. ;transport=transport-udp
  216. ;context=from-external
  217. ;disallow=all
  218. ;allow=ulaw
  219. ;outbound_auth=mytrunk_auth
  220. ;aors=mytrunk
  221. ; ;A few NAT relevant options that may come in handy.
  222. ;force_rport=yes ;It's a good idea to read the configuration help for each
  223. ;direct_media=no ;of these options.
  224. ;ice_support=yes
  225. ;[mytrunk]
  226. ;type=aor
  227. ;contact=sip:198.51.100.1:5060
  228. ;contact=sip:198.51.100.2:5060
  229. ;[mytrunk]
  230. ;type=identify
  231. ;endpoint=mytrunk
  232. ;match=198.51.100.1
  233. ;match=198.51.100.2
  234. ;=============ENDPOINT CONFIGURED AS A TRUNK, INBOUND AUTH AND REGISTRATION===
  235. ;
  236. ; Here we are allowing a remote device to register to Asterisk and requiring
  237. ; that they authenticate for registration and calls.
  238. ; You'll note that this configuration is essentially the same as configuring
  239. ; an endpoint for use with a SIP phone.
  240. ;[7000]
  241. ;type=endpoint
  242. ;context=from-external
  243. ;disallow=all
  244. ;allow=ulaw
  245. ;transport=transport-udp
  246. ;auth=7000
  247. ;aors=7000
  248. ;[7000]
  249. ;type=auth
  250. ;auth_type=userpass
  251. ;password=7000
  252. ;username=7000
  253. ;[7000]
  254. ;type=aor
  255. ;max_contacts=1
  256. ;===============ENDPOINT CONFIGURED FOR USE WITH A SIP PHONE==================
  257. ;
  258. ; This example includes the endpoint, auth and aor configurations. It
  259. ; requires inbound authentication and allows registration, as well as references
  260. ; a transport that you'll need to uncomment from the previous examples.
  261. ;
  262. ; Uncomment one of the transport lines to choose which transport you want. If
  263. ; not specified then the default transport chosen is the first compatible transport
  264. ; in the configuration file for the contact URL.
  265. ;
  266. ; Modify the "max_contacts=" line to change how many unique registrations to allow.
  267. ;
  268. ; Use the "contact=" line instead of max_contacts= if you want to statically
  269. ; define the location of the device.
  270. ;
  271. ; If using the TLS enabled transport, you may want the "media_encryption=sdes"
  272. ; option to additionally enable SRTP, though they are not mutually inclusive.
  273. ;
  274. ; If this endpoint were remote, and it was using a transport configured for NAT
  275. ; then you likely want to use "direct_media=no" to prevent audio issues.
  276. ;[6001]
  277. ;type=endpoint
  278. ;transport=transport-udp
  279. ;context=from-internal
  280. ;disallow=all
  281. ;allow=ulaw
  282. ;allow=gsm
  283. ;auth=6001
  284. ;aors=6001
  285. ;
  286. ; A few more transports to pick from, and some related options below them.
  287. ;
  288. ;transport=transport-tls
  289. ;media_encryption=sdes
  290. ;transport=transport-udp-ipv6
  291. ;transport=transport-udp-nat
  292. ;direct_media=no
  293. ;
  294. ; MWI related options
  295. ;aggregate_mwi=yes
  296. ;mailboxes=6001@default,7001@default
  297. ;mwi_from_user=6001
  298. ;
  299. ; Extension and Device state options
  300. ;
  301. ;device_state_busy_at=1
  302. ;allow_subscribe=yes
  303. ;sub_min_expiry=30
  304. ;[6001]
  305. ;type=auth
  306. ;auth_type=userpass
  307. ;password=6001
  308. ;username=6001
  309. ;[6001]
  310. ;type=aor
  311. ;max_contacts=1
  312. ;contact=sip:6001@192.0.2.1:5060
  313. ;===============ENDPOINT BEHIND NAT OR FIREWALL===============================
  314. ;
  315. ; This example assumes your transport is configured with a public IP and the
  316. ; endpoint itself is behind NAT and maybe a firewall, rather than having
  317. ; Asterisk behind NAT. For the sake of simplicity, we'll assume a typical
  318. ; VOIP phone. The most important settings to configure are:
  319. ;
  320. ; * direct_media, to ensure Asterisk stays in the media path
  321. ; * rtp_symmetric and force_rport options to help the far-end NAT/firewall
  322. ;
  323. ; Depending on the settings of your remote SIP device or NAT/firewall device
  324. ; you may have to experiment with a combination of these settings.
  325. ;
  326. ; If both Asterisk and the remote phones are a behind NAT/firewall then you'll
  327. ; have to make sure to use a transport with appropriate settings (as in the
  328. ; transport-udp-nat example).
  329. ;
  330. ;[6002]
  331. ;type=endpoint
  332. ;transport=transport-udp
  333. ;context=from-internal
  334. ;disallow=all
  335. ;allow=ulaw
  336. ;auth=6002
  337. ;aors=6002
  338. ;direct_media=no
  339. ;rtp_symmetric=yes
  340. ;force_rport=yes
  341. ;rewrite_contact=yes ; necessary if endpoint does not know/register public ip:port
  342. ;ice_support=yes ;This is specific to clients that support NAT traversal
  343. ;for media via ICE,STUN,TURN. See the wiki at:
  344. ;https://wiki.asterisk.org/wiki/x/D4FHAQ
  345. ;for a deeper explanation of this topic.
  346. ;[6002]
  347. ;type=auth
  348. ;auth_type=userpass
  349. ;password=6002
  350. ;username=6002
  351. ;[6002]
  352. ;type=aor
  353. ;max_contacts=2
  354. ;============EXAMPLE ACL CONFIGURATION==========================================
  355. ;
  356. ; The ACL or Access Control List section defines a set of permissions to permit
  357. ; or deny access to various address or addresses. Alternatively it references an
  358. ; ACL configuration already set in acl.conf.
  359. ;
  360. ; The ACL configuration is independent of individual endpoint configuration and
  361. ; operates on all inbound SIP communication using res_pjsip.
  362. ; Reference an ACL defined in acl.conf.
  363. ;
  364. ;[acl]
  365. ;type=acl
  366. ;acl=example_named_acl1
  367. ; Reference a contactacl specifically.
  368. ;
  369. ;[acl]
  370. ;type=acl
  371. ;contact_acl=example_contact_acl1
  372. ; Define your own ACL here in pjsip.conf and
  373. ; permit or deny by IP address or range.
  374. ;
  375. ;[acl]
  376. ;type=acl
  377. ;deny=0.0.0.0/0.0.0.0
  378. ;permit=209.16.236.0/24
  379. ;deny=209.16.236.1
  380. ; Restrict based on Contact Headers rather than IP.
  381. ; Define options multiple times for various addresses or use a comma-delimited string.
  382. ;
  383. ;[acl]
  384. ;type=acl
  385. ;contact_deny=0.0.0.0/0.0.0.0
  386. ;contact_permit=209.16.236.0/24
  387. ;contact_permit=209.16.236.1
  388. ;contact_permit=209.16.236.2,209.16.236.3
  389. ; Restrict based on Contact Headers rather than IP and use
  390. ; advanced syntax. Note the bang symbol used for "NOT", so we can deny
  391. ; 209.16.236.12/32 within the permit= statement.
  392. ;
  393. ;[acl]
  394. ;type=acl
  395. ;contact_deny=0.0.0.0/0.0.0.0
  396. ;contact_permit=209.16.236.0
  397. ;permit=209.16.236.0/24, !209.16.236.12/32
  398. ;============EXAMPLE RLS CONFIGURATION==========================================
  399. ;
  400. ;Asterisk provides support for RFC 4662 Resource List Subscriptions. This allows
  401. ;for an endpoint to, through a single subscription, subscribe to the states of
  402. ;multiple resources. Resource lists are configured in pjsip.conf using the
  403. ;resource_list configuration object. Below is an example of a resource list that
  404. ;allows an endpoint to subscribe to the presence of alice, bob, and carol.
  405. ;[my_list]
  406. ;type=resource_list
  407. ;list_item=alice
  408. ;list_item=bob
  409. ;list_item=carol
  410. ;event=presence
  411. ;The "event" option in the resource list corresponds to the SIP event-package
  412. ;that the subscribed resources belong to. A resource list can only provide states
  413. ;for resources that belong to the same event-package. This means that you cannot
  414. ;create a list that is a combination of presence and message-summary resources,
  415. ;for instance. Any event-package that Asterisk supports can be used in a resource
  416. ;list (presence, dialog, and message-summary). Whenever support for a new event-
  417. ;package is added to Asterisk, support for that event-package in resource lists
  418. ;will automatically be supported.
  419. ;The "list_item" options indicate the names of resources to subscribe to. The
  420. ;way these are interpreted is event-package specific. For instance, with presence
  421. ;list_items, hints in the dialplan are looked up. With message-summary list_items,
  422. ;mailboxes are looked up using your installed voicemail provider (app_voicemail
  423. ;by default). Note that in the above example, the list_item options were given
  424. ;one per line. However, it is also permissible to provide multiple list_item
  425. ;options on a single line (e.g. list_item = alice,bob,carol).
  426. ;In addition to the options presented in the above configuration, there are two
  427. ;more configuration options that can be set.
  428. ; * full_state: dictates whether Asterisk should always send the states of
  429. ; all resources in the list at once. Defaults to "no". You should only set
  430. ; this to "yes" if you are interoperating with an endpoint that does not
  431. ; behave correctly when partial state notifications are sent to it.
  432. ; * notification_batch_interval: By default, Asterisk will send a NOTIFY request
  433. ; immediately when a resource changes state. This option causes Asterisk to
  434. ; start batching resource state changes for the specified number of milliseconds
  435. ; after a resource changes states. This way, if multiple resources change state
  436. ; within a brief interval, Asterisk can send a single NOTIFY request with all
  437. ; of the state changes reflected in it.
  438. ;There is a limitation to the size of resource lists in Asterisk. If a constructed
  439. ;notification from Asterisk will exceed 64000 bytes, then the message is deemed
  440. ;too large to send. If you find that you are seeing error messages about SIP
  441. ;NOTIFY requests being too large to send, consider breaking your lists into
  442. ;sub-lists.
  443. ;============EXAMPLE PHONEPROV CONFIGURATION================================
  444. ; Before configuring provisioning here, see the documentation for res_phoneprov
  445. ; and configure phoneprov.conf appropriately.
  446. ; For each user to be autoprovisioned, a [phoneprov] configuration section
  447. ; must be created. At a minimum, the 'type', 'PROFILE' and 'MAC' variables must
  448. ; be set. All other variables are optional.
  449. ; Example:
  450. ;[1000]
  451. ;type=phoneprov ; must be specified as 'phoneprov'
  452. ;endpoint=1000 ; Required only if automatic setting of
  453. ; USERNAME, SECRET, DISPLAY_NAME and CALLERID
  454. ; are needed.
  455. ;PROFILE=digium ; required
  456. ;MAC=deadbeef4dad ; required
  457. ;SERVER=myserver.example.com ; A standard variable
  458. ;TIMEZONE=America/Denver ; A standard variable
  459. ;MYVAR=somevalue ; A user confdigured variable
  460. ; If the phoneprov sections have common variables, it is best to create a
  461. ; phoneprov template. The example below will produce the same configuration
  462. ; as the one specified above except that MYVAR will be overridden for
  463. ; the specific user.
  464. ; Example:
  465. ;[phoneprov_defaults](!)
  466. ;type=phoneprov ; must be specified as 'phoneprov'
  467. ;PROFILE=digium ; required
  468. ;SERVER=myserver.example.com ; A standard variable
  469. ;TIMEZONE=America/Denver ; A standard variable
  470. ;MYVAR=somevalue ; A user configured variable
  471. ;[1000](phoneprov_defaults)
  472. ;endpoint=1000 ; Required only if automatic setting of
  473. ; USERNAME, SECRET, DISPLAY_NAME and CALLERID
  474. ; are needed.
  475. ;MAC=deadbeef4dad ; required
  476. ;MYVAR=someOTHERvalue ; A user confdigured variable
  477. ; To have USERNAME and SECRET automatically set, the endpoint
  478. ; specified here must in turn have an outbound_auth section defined.
  479. ; Fuller example:
  480. ;[1000]
  481. ;type=endpoint
  482. ;outbound_auth=1000-auth
  483. ;callerid=My Name <8005551212>
  484. ;transport=transport-udp-nat
  485. ;[1000-auth]
  486. ;type=auth
  487. ;auth_type=userpass
  488. ;username=myname
  489. ;password=mysecret
  490. ;[phoneprov_defaults](!)
  491. ;type=phoneprov ; must be specified as 'phoneprov'
  492. ;PROFILE=someprofile ; required
  493. ;SERVER=myserver.example.com ; A standard variable
  494. ;TIMEZONE=America/Denver ; A standard variable
  495. ;MYVAR=somevalue ; A user configured variable
  496. ;[1000](phoneprov_defaults)
  497. ;endpoint=1000 ; Required only if automatic setting of
  498. ; USERNAME, SECRET, DISPLAY_NAME and CALLERID
  499. ; are needed.
  500. ;MAC=deadbeef4dad ; required
  501. ;MYVAR=someUSERvalue ; A user confdigured variable
  502. ;LABEL=1000 ; A standard variable
  503. ; The previous sections would produce a template substitution map as follows:
  504. ;MAC=deadbeef4dad ;added by pp1000
  505. ;USERNAME=myname ;automatically added by 1000-auth username
  506. ;SECRET=mysecret ;automatically added by 1000-auth password
  507. ;PROFILE=someprofile ;added by defaults
  508. ;SERVER=myserver.example.com ;added by defaults
  509. ;SERVER_PORT=5060 ;added by defaults
  510. ;MYVAR=someUSERvalue ;added by defaults but overdidden by user
  511. ;CALLERID=8005551212 ;automatically added by 1000 callerid
  512. ;DISPLAY_NAME=My Name ;automatically added by 1000 callerid
  513. ;TIMEZONE=America/Denver ;added by defaults
  514. ;TZOFFSET=252100 ;automatically calculated by res_phoneprov
  515. ;DST_ENABLE=1 ;automatically calculated by res_phoneprov
  516. ;DST_START_MONTH=3 ;automatically calculated by res_phoneprov
  517. ;DST_START_MDAY=9 ;automatically calculated by res_phoneprov
  518. ;DST_START_HOUR=3 ;automatically calculated by res_phoneprov
  519. ;DST_END_MONTH=11 ;automatically calculated by res_phoneprov
  520. ;DST_END_MDAY=2 ;automatically calculated by res_phoneprov
  521. ;DST_END_HOUR=1 ;automatically calculated by res_phoneprov
  522. ;ENDPOINT_ID=1000 ;automatically added by this module
  523. ;AUTH_ID=1000-auth ;automatically added by this module
  524. ;TRANSPORT_ID=transport-udp-nat ;automatically added by this module
  525. ;LABEL=1000 ;added by user
  526. ; MODULE PROVIDING BELOW SECTION(S): res_pjsip
  527. ;==========================ENDPOINT SECTION OPTIONS=========================
  528. ;[endpoint]
  529. ; SYNOPSIS: Endpoint
  530. ;100rel=yes ; Allow support for RFC3262 provisional ACK tags (default:
  531. ; "yes")
  532. ;aggregate_mwi=yes ; (default: "yes")
  533. ;allow= ; Media Codec s to allow (default: "")
  534. ;allow_overlap=yes ; Enable RFC3578 overlap dialing support. (default: "yes")
  535. ;aors= ; AoR s to be used with the endpoint (default: "")
  536. ;auth= ; Authentication Object s associated with the endpoint (default: "")
  537. ;callerid= ; CallerID information for the endpoint (default: "")
  538. ;callerid_privacy=allowed_not_screened ; Default privacy level (default: "allowed_not_screened")
  539. ;callerid_tag= ; Internal id_tag for the endpoint (default: "")
  540. ;context=default ; Dialplan context for inbound sessions (default:
  541. ; "default")
  542. ;direct_media_glare_mitigation=none ; Mitigation of direct media re INVITE
  543. ; glare (default: "none")
  544. ;direct_media_method=invite ; Direct Media method type (default: "invite")
  545. ;trust_connected_line=yes ; Accept Connected Line updates from this endpoint
  546. ; (default: "yes")
  547. ;send_connected_line=yes ; Send Connected Line updates to this endpoint
  548. ; (default: "yes")
  549. ;connected_line_method=invite ; Connected line method type.
  550. ; When set to "invite", check the remote's
  551. ; Allow header and if UPDATE is allowed, send
  552. ; UPDATE instead of INVITE to avoid SDP
  553. ; renegotiation. If UPDATE is not Allowed,
  554. ; send INVITE.
  555. ; If set to "update", send UPDATE regardless
  556. ; of what the remote Allows.
  557. ; (default: "invite")
  558. ;direct_media=yes ; Determines whether media may flow directly between
  559. ; endpoints (default: "yes")
  560. ;disable_direct_media_on_nat=no ; Disable direct media session refreshes when
  561. ; NAT obstructs the media session (default:
  562. ; "no")
  563. ;disallow= ; Media Codec s to disallow (default: "")
  564. ;dtmf_mode=rfc4733 ; DTMF mode (default: "rfc4733")
  565. ;media_address= ; IP address used in SDP for media handling (default: "")
  566. ;bind_rtp_to_media_address= ; Bind the RTP session to the media_address.
  567. ; This causes all RTP packets to be sent from
  568. ; the specified address. (default: "no")
  569. ;force_rport=yes ; Force use of return port (default: "yes")
  570. ;ice_support=no ; Enable the ICE mechanism to help traverse NAT (default: "no")
  571. ;identify_by=username ; A comma-separated list of ways the Endpoint or AoR can be
  572. ; identified.
  573. ; "username": Identify by the From or To username and domain
  574. ; "auth_username": Identify by the Authorization username and realm
  575. ; "ip": Identify by the source IP address
  576. ; "header": Identify by a configured SIP header value.
  577. ; In the username and auth_username cases, if an exact match
  578. ; on both username and domain/realm fails, the match is
  579. ; retried with just the username.
  580. ; (default: "username,ip")
  581. ;redirect_method=user ; How redirects received from an endpoint are handled
  582. ; (default: "user")
  583. ;mailboxes= ; NOTIFY the endpoint when state changes for any of the specified mailboxes.
  584. ; Asterisk will send unsolicited MWI NOTIFY messages to the endpoint when state
  585. ; changes happen for any of the specified mailboxes. (default: "")
  586. ;voicemail_extension= ; The voicemail extension to send in the NOTIFY Message-Account header
  587. ; (default: global/default_voicemail_extension)
  588. ;mwi_subscribe_replaces_unsolicited=no
  589. ; An MWI subscribe will replace unsoliticed NOTIFYs
  590. ; (default: "no")
  591. ;moh_suggest=default ; Default Music On Hold class (default: "default")
  592. ;outbound_auth= ; Authentication object used for outbound requests (default:
  593. ; "")
  594. ;outbound_proxy= ; Proxy through which to send requests, a full SIP URI
  595. ; must be provided (default: "")
  596. ;rewrite_contact=no ; Allow Contact header to be rewritten with the source
  597. ; IP address port (default: "no")
  598. ;rtp_symmetric=no ; Enforce that RTP must be symmetric (default: "no")
  599. ;send_diversion=yes ; Send the Diversion header conveying the diversion
  600. ; information to the called user agent (default: "yes")
  601. ;send_pai=no ; Send the P Asserted Identity header (default: "no")
  602. ;send_rpid=no ; Send the Remote Party ID header (default: "no")
  603. ;rpid_immediate=no ; Send connected line updates on unanswered incoming calls immediately. (default: "no")
  604. ;timers_min_se=90 ; Minimum session timers expiration period (default:
  605. ; "90")
  606. ;timers=yes ; Session timers for SIP packets (default: "yes")
  607. ;timers_sess_expires=1800 ; Maximum session timer expiration period
  608. ; (default: "1800")
  609. ;transport= ; Explicit transport configuration to use (default: "")
  610. ; This will force the endpoint to use the specified transport
  611. ; configuration to send SIP messages. You need to already know
  612. ; what kind of transport (UDP/TCP/IPv4/etc) the endpoint device
  613. ; will use.
  614. ;trust_id_inbound=no ; Accept identification information received from this
  615. ; endpoint (default: "no")
  616. ;trust_id_outbound=no ; Send private identification details to the endpoint
  617. ; (default: "no")
  618. ;type= ; Must be of type endpoint (default: "")
  619. ;use_ptime=no ; Use Endpoint s requested packetisation interval (default:
  620. ; "no")
  621. ;use_avpf=no ; Determines whether res_pjsip will use and enforce usage of
  622. ; AVPF for this endpoint (default: "no")
  623. ;media_encryption=no ; Determines whether res_pjsip will use and enforce
  624. ; usage of media encryption for this endpoint (default:
  625. ; "no")
  626. ;media_encryption_optimistic=no ; Use encryption if possible but don't fail the call
  627. ; if not possible.
  628. ;g726_non_standard=no ; When set to "yes" and an endpoint negotiates g.726
  629. ; audio then g.726 for AAL2 packing order is used contrary
  630. ; to what is recommended in RFC3551. Note, 'g726aal2' also
  631. ; needs to be specified in the codec allow list
  632. ; (default: "no")
  633. ;inband_progress=no ; Determines whether chan_pjsip will indicate ringing
  634. ; using inband progress (default: "no")
  635. ;call_group= ; The numeric pickup groups for a channel (default: "")
  636. ;pickup_group= ; The numeric pickup groups that a channel can pickup (default:
  637. ; "")
  638. ;named_call_group= ; The named pickup groups for a channel (default: "")
  639. ;named_pickup_group= ; The named pickup groups that a channel can pickup
  640. ; (default: "")
  641. ;device_state_busy_at=0 ; The number of in use channels which will cause busy
  642. ; to be returned as device state (default: "0")
  643. ;t38_udptl=no ; Whether T 38 UDPTL support is enabled or not (default: "no")
  644. ;t38_udptl_ec=none ; T 38 UDPTL error correction method (default: "none")
  645. ;t38_udptl_maxdatagram=0 ; T 38 UDPTL maximum datagram size (default:
  646. ; "0")
  647. ;fax_detect=no ; Whether CNG tone detection is enabled (default: "no")
  648. ;fax_detect_timeout=30 ; How many seconds into a call before fax_detect is
  649. ; disabled for the call.
  650. ; Zero disables the timeout.
  651. ; (default: "0")
  652. ;t38_udptl_nat=no ; Whether NAT support is enabled on UDPTL sessions
  653. ; (default: "no")
  654. ;tone_zone= ; Set which country s indications to use for channels created
  655. ; for this endpoint (default: "")
  656. ;language= ; Set the default language to use for channels created for this
  657. ; endpoint (default: "")
  658. ;one_touch_recording=no ; Determines whether one touch recording is allowed for
  659. ; this endpoint (default: "no")
  660. ;record_on_feature=automixmon ; The feature to enact when one touch recording
  661. ; is turned on (default: "automixmon")
  662. ;record_off_feature=automixmon ; The feature to enact when one touch recording
  663. ; is turned off (default: "automixmon")
  664. ;rtp_engine=asterisk ; Name of the RTP engine to use for channels created
  665. ; for this endpoint (default: "asterisk")
  666. ;allow_transfer=yes ; Determines whether SIP REFER transfers are allowed
  667. ; for this endpoint (default: "yes")
  668. ;sdp_owner=- ; String placed as the username portion of an SDP origin o line
  669. ; (default: "-")
  670. ;sdp_session=Asterisk ; String used for the SDP session s line (default:
  671. ; "Asterisk")
  672. ;tos_audio=0 ; DSCP TOS bits for audio streams (default: "0")
  673. ;tos_video=0 ; DSCP TOS bits for video streams (default: "0")
  674. ;cos_audio=0 ; Priority for audio streams (default: "0")
  675. ;cos_video=0 ; Priority for video streams (default: "0")
  676. ;allow_subscribe=yes ; Determines if endpoint is allowed to initiate
  677. ; subscriptions with Asterisk (default: "yes")
  678. ;sub_min_expiry=0 ; The minimum allowed expiry time for subscriptions
  679. ; initiated by the endpoint (default: "0")
  680. ;from_user= ; Username to use in From header for requests to this endpoint
  681. ; (default: "")
  682. ;mwi_from_user= ; Username to use in From header for unsolicited MWI NOTIFYs to
  683. ; this endpoint (default: "")
  684. ;from_domain= ; Domain to user in From header for requests to this endpoint
  685. ; (default: "")
  686. ;dtls_verify=no ; Verify that the provided peer certificate is valid (default:
  687. ; "no")
  688. ;dtls_rekey=0 ; Interval at which to renegotiate the TLS session and rekey
  689. ; the SRTP session (default: "0")
  690. ;dtls_cert_file= ; Path to certificate file to present to peer (default:
  691. ; "")
  692. ;dtls_private_key= ; Path to private key for certificate file (default:
  693. ; "")
  694. ;dtls_cipher= ; Cipher to use for DTLS negotiation (default: "")
  695. ;dtls_ca_file= ; Path to certificate authority certificate (default: "")
  696. ;dtls_ca_path= ; Path to a directory containing certificate authority
  697. ; certificates (default: "")
  698. ;dtls_setup= ; Whether we are willing to accept connections connect to the
  699. ; other party or both (default: "")
  700. ;dtls_fingerprint= ; Hash to use for the fingerprint placed into SDP
  701. ; (default: "SHA-256")
  702. ;srtp_tag_32=no ; Determines whether 32 byte tags should be used instead of 80
  703. ; byte tags (default: "no")
  704. ;set_var= ; Variable set on a channel involving the endpoint. For multiple
  705. ; channel variables specify multiple 'set_var'(s)
  706. ;rtp_keepalive= ; Interval, in seconds, between comfort noise RTP packets if
  707. ; RTP is not flowing. This setting is useful for ensuring that
  708. ; holes in NATs and firewalls are kept open throughout a call.
  709. ;rtp_timeout= ; Hang up channel if RTP is not received for the specified
  710. ; number of seconds when the channel is off hold (default:
  711. ; "0" or not enabled)
  712. ;rtp_timeout_hold= ; Hang up channel if RTP is not received for the specified
  713. ; number of seconds when the channel is on hold (default:
  714. ; "0" or not enabled)
  715. ;contact_user= ; On outgoing requests, force the user portion of the Contact
  716. ; header to this value (default: "")
  717. ;asymmetric_rtp_codec= ; Allow the sending and receiving codec to differ and
  718. ; not be automatically matched (default: "no")
  719. ;refer_blind_progress= ; Whether to notifies all the progress details on blind
  720. ; transfer (default: "yes"). The value "no" is useful
  721. ; for some SIP phones (Mitel/Aastra, Snom) which expect
  722. ; a sip/frag "200 OK" after REFER has been accepted.
  723. ;notify_early_inuse_ringing = ; Whether to notifies dialog-info 'early'
  724. ; on INUSE && RINGING state (default: "no").
  725. ; The value "yes" is useful for some SIP phones
  726. ; (Cisco SPA) to be able to indicate and pick up
  727. ; ringing devices.
  728. ;incoming_mwi_mailbox = ; Mailbox name to use when incoming MWI NOTIFYs are
  729. ; received.
  730. ; If an MWI NOTIFY is received FROM this endpoint,
  731. ; this mailbox will be used when notifying other modules
  732. ; of MWI status changes. If not set, incoming MWI
  733. ; NOTIFYs are ignored.
  734. ;follow_early_media_fork = ; On outgoing calls, if the UAS responds with
  735. ; different SDP attributes on subsequent 18X or 2XX
  736. ; responses (such as a port update) AND the To tag
  737. ; on the subsequent response is different than that
  738. ; on the previous one, follow it. This usually
  739. ; happens when the INVITE is forked to multiple UASs
  740. ; and more than 1 sends an SDP answer.
  741. ; This option must also be enabled in the system
  742. ; section.
  743. ; (default: yes)
  744. ;accept_multiple_sdp_answers =
  745. ; On outgoing calls, if the UAS responds with
  746. ; different SDP attributes on non-100rel 18X or 2XX
  747. ; responses (such as a port update) AND the To tag on
  748. ; the subsequent response is the same as that on the
  749. ; previous one, process it. This can happen when the
  750. ; UAS needs to change ports for some reason such as
  751. ; using a separate port for custom ringback.
  752. ; This option must also be enabled in the system
  753. ; section.
  754. ; (default: no)
  755. ;suppress_q850_reason_headers =
  756. ; Suppress Q.850 Reason headers for this endpoint.
  757. ; Some devices can't accept multiple Reason headers
  758. ; and get confused when both 'SIP' and 'Q.850' Reason
  759. ; headers are received. This option allows the
  760. ; 'Q.850' Reason header to be suppressed.
  761. ; (default: no)
  762. ;==========================AUTH SECTION OPTIONS=========================
  763. ;[auth]
  764. ; SYNOPSIS: Authentication type
  765. ;
  766. ; Note: Using the same auth section for inbound and outbound
  767. ; authentication is not recommended. There is a difference in
  768. ; meaning for an empty realm setting between inbound and outbound
  769. ; authentication uses. Look to the CLI config help
  770. ; "config show help res_pjsip auth realm" or on the wiki for the
  771. ; difference.
  772. ;
  773. ;auth_type=userpass ; Authentication type (default: "userpass")
  774. ;nonce_lifetime=32 ; Lifetime of a nonce associated with this
  775. ; authentication config (default: "32")
  776. ;md5_cred= ; MD5 Hash used for authentication (default: "")
  777. ;password= ; PlainText password used for authentication (default: "")
  778. ;realm= ; SIP realm for endpoint (default: "")
  779. ;type= ; Must be auth (default: "")
  780. ;username= ; Username to use for account (default: "")
  781. ;==========================DOMAIN_ALIAS SECTION OPTIONS=========================
  782. ;[domain_alias]
  783. ; SYNOPSIS: Domain Alias
  784. ;type= ; Must be of type domain_alias (default: "")
  785. ;domain= ; Domain to be aliased (default: "")
  786. ;==========================TRANSPORT SECTION OPTIONS=========================
  787. ;[transport]
  788. ; SYNOPSIS: SIP Transport
  789. ;
  790. ;async_operations=1 ; Number of simultaneous Asynchronous Operations
  791. ; (default: "1")
  792. ;bind= ; IP Address and optional port to bind to for this transport (default:
  793. ; "")
  794. ; Note that for the Websocket transport the TLS configuration is configured
  795. ; in http.conf and is applied for all HTTPS traffic.
  796. ;ca_list_file= ; File containing a list of certificates to read TLS ONLY
  797. ; (default: "")
  798. ;ca_list_path= ; Path to directory containing certificates to read TLS ONLY.
  799. ; PJProject version 2.4 or higher is required for this option to
  800. ; be used.
  801. ; (default: "")
  802. ;cert_file= ; Certificate file for endpoint TLS ONLY
  803. ; Will read .crt or .pem file but only uses cert,
  804. ; a .key file must be specified via priv_key_file
  805. ; (default: "")
  806. ;cipher= ; Preferred cryptography cipher names TLS ONLY (default: "")
  807. ;method= ; Method of SSL transport TLS ONLY (default: "")
  808. ;priv_key_file= ; Private key file TLS ONLY (default: "")
  809. ;verify_client= ; Require verification of client certificate TLS ONLY (default:
  810. ; "")
  811. ;verify_server= ; Require verification of server certificate TLS ONLY (default:
  812. ; "")
  813. ;require_client_cert= ; Require client certificate TLS ONLY (default: "")
  814. ;domain= ; Domain the transport comes from (default: "")
  815. ;external_media_address= ; External IP address to use in RTP handling
  816. ; (default: "")
  817. ;external_signaling_address= ; External address for SIP signalling (default:
  818. ; "")
  819. ;external_signaling_port=0 ; External port for SIP signalling (default:
  820. ; "0")
  821. ;local_net= ; Network to consider local used for NAT purposes (default: "")
  822. ;password= ; Password required for transport (default: "")
  823. ;protocol=udp ; Protocol to use for SIP traffic (default: "udp")
  824. ;type= ; Must be of type transport (default: "")
  825. ;tos=0 ; Enable TOS for the signalling sent over this transport (default: "0")
  826. ;cos=0 ; Enable COS for the signalling sent over this transport (default: "0")
  827. ;websocket_write_timeout=100 ; Default write timeout to set on websocket
  828. ; transports. This value may need to be adjusted
  829. ; for connections where Asterisk must write a
  830. ; substantial amount of data and the receiving
  831. ; clients are slow to process the received
  832. ; information. Value is in milliseconds; default
  833. ; is 100 ms.
  834. ;allow_reload=no ; Although transports can now be reloaded, that may not be
  835. ; desirable because of the slight possibility of dropped
  836. ; calls. To make sure there are no unintentional drops, if
  837. ; this option is set to 'no' (the default) changes to the
  838. ; particular transport will be ignored. If set to 'yes',
  839. ; changes (if any) will be applied.
  840. ;symmetric_transport=no ; When a request from a dynamic contact comes in on a
  841. ; transport with this option set to 'yes', the transport
  842. ; name will be saved and used for subsequent outgoing
  843. ; requests like OPTIONS, NOTIFY and INVITE. It's saved
  844. ; as a contact uri parameter named 'x-ast-txp' and will
  845. ; display with the contact uri in CLI, AMI, and ARI
  846. ; output. On the outgoing request, if a transport
  847. ; wasn't explicitly set on the endpoint AND the request
  848. ; URI is not a hostname, the saved transport will be
  849. ; used and the 'x-ast-txp' parameter stripped from the
  850. ; outgoing packet.
  851. ;==========================AOR SECTION OPTIONS=========================
  852. ;[aor]
  853. ; SYNOPSIS: The configuration for a location of an endpoint
  854. ;contact= ; Permanent contacts assigned to AoR (default: "")
  855. ;default_expiration=3600 ; Default expiration time in seconds for
  856. ; contacts that are dynamically bound to an AoR
  857. ; (default: "3600")
  858. ;mailboxes= ; Allow subscriptions for the specified mailbox(es)
  859. ; This option applies when an external entity subscribes to an AoR
  860. ; for Message Waiting Indications. (default: "")
  861. ;voicemail_extension= ; The voicemail extension to send in the NOTIFY Message-Account header
  862. ; (default: global/default_voicemail_extension)
  863. ;maximum_expiration=7200 ; Maximum time to keep an AoR (default: "7200")
  864. ;max_contacts=0 ; Maximum number of contacts that can bind to an AoR (default:
  865. ; "0")
  866. ;minimum_expiration=60 ; Minimum keep alive time for an AoR (default: "60")
  867. ;remove_existing=no ; Allow a registration to succeed by displacing any existing
  868. ; contacts that now exceed the max_contacts count. Any
  869. ; removed contacts are the next to expire. The behaviour is
  870. ; beneficial when rewrite_contact is enabled and max_contacts
  871. ; is greater than one. The removed contact is likely the old
  872. ; contact created by rewrite_contact that the device is
  873. ; refreshing.
  874. ; (default: "no")
  875. ;type= ; Must be of type aor (default: "")
  876. ;qualify_frequency=0 ; Interval at which to qualify an AoR (default: "0")
  877. ;qualify_timeout=3.0 ; Qualify timeout in fractional seconds (default: "3.0")
  878. ;authenticate_qualify=no ; Authenticates a qualify request if needed
  879. ; (default: "no")
  880. ;outbound_proxy= ; Proxy through which to send OPTIONS requests, a full SIP URI
  881. ; must be provided (default: "")
  882. ;==========================SYSTEM SECTION OPTIONS=========================
  883. ;[system]
  884. ; SYNOPSIS: Options that apply to the SIP stack as well as other system-wide settings
  885. ;timer_t1=500 ; Set transaction timer T1 value milliseconds (default: "500")
  886. ;timer_b=32000 ; Set transaction timer B value milliseconds (default: "32000")
  887. ;compact_headers=no ; Use the short forms of common SIP header names
  888. ; (default: "no")
  889. ;threadpool_initial_size=0 ; Initial number of threads in the res_pjsip
  890. ; threadpool (default: "0")
  891. ;threadpool_auto_increment=5 ; The amount by which the number of threads is
  892. ; incremented when necessary (default: "5")
  893. ;threadpool_idle_timeout=60 ; Number of seconds before an idle thread
  894. ; should be disposed of (default: "60")
  895. ;threadpool_max_size=0 ; Maximum number of threads in the res_pjsip threadpool
  896. ; A value of 0 indicates no maximum (default: "0")
  897. ;disable_tcp_switch=yes ; Disable automatic switching from UDP to TCP transports
  898. ; if outgoing request is too large.
  899. ; See RFC 3261 section 18.1.1.
  900. ; Disabling this option has been known to cause interoperability
  901. ; issues, so disable at your own risk.
  902. ; (default: "yes")
  903. ;follow_early_media_fork = ; On outgoing calls, if the UAS responds with
  904. ; different SDP attributes on subsequent 18X or 2XX
  905. ; responses (such as a port update) AND the To tag
  906. ; on the subsequent response is different than that
  907. ; on the previous one, follow it. This usually
  908. ; happens when the INVITE is forked to multiple UASs
  909. ; and more than 1 sends an SDP answer.
  910. ; This option must also be enabled on endpoints that
  911. ; require this functionality.
  912. ; (default: yes)
  913. ;accept_multiple_sdp_answers =
  914. ; On outgoing calls, if the UAS responds with
  915. ; different SDP attributes on non-100rel 18X or 2XX
  916. ; responses (such as a port update) AND the To tag on
  917. ; the subsequent response is the same as that on the
  918. ; previous one, process it. This can happen when the
  919. ; UAS needs to change ports for some reason such as
  920. ; using a separate port for custom ringback.
  921. ; This option must also be enabled on endpoints that
  922. ; require this functionality.
  923. ; (default: no)
  924. ;type= ; Must be of type system (default: "")
  925. ;==========================GLOBAL SECTION OPTIONS=========================
  926. ;[global]
  927. ; SYNOPSIS: Options that apply globally to all SIP communications
  928. ;max_forwards=70 ; Value used in Max Forwards header for SIP requests
  929. ; (default: "70")
  930. ;type= ; Must be of type global (default: "")
  931. ;user_agent=Asterisk PBX ; Allows you to change the user agent string
  932. ; The default user agent string also contains
  933. ; the Asterisk version. If you don't want to
  934. ; expose this, change the user_agent string.
  935. ;default_outbound_endpoint=default_outbound_endpoint ; Endpoint to use when
  936. ; sending an outbound
  937. ; request to a URI
  938. ; without a specified
  939. ; endpoint (default: "d
  940. ; efault_outbound_endpo
  941. ; int")
  942. ;debug=no ; Enable/Disable SIP debug logging. Valid options include yes|no
  943. ; or a host address (default: "no")
  944. ;keep_alive_interval=20 ; The interval (in seconds) at which to send keepalive
  945. ; messages on all active connection-oriented transports
  946. ; (default: "0")
  947. ;contact_expiration_check_interval=30
  948. ; The interval (in seconds) to check for expired contacts.
  949. ;disable_multi_domain=no
  950. ; Disable Multi Domain support.
  951. ; If disabled it can improve realtime performace by reducing
  952. ; number of database requsts
  953. ; (default: "no")
  954. ;endpoint_identifier_order=ip,username,anonymous
  955. ; The order by which endpoint identifiers are given priority.
  956. ; Currently, "ip", "header", "username", "auth_username" and "anonymous"
  957. ; are valid identifiers as registered by the res_pjsip_endpoint_identifier_*
  958. ; modules. Some modules like res_pjsip_endpoint_identifier_user register
  959. ; more than one identifier. Use the CLI command "pjsip show identifiers"
  960. ; to see the identifiers currently available.
  961. ; (default: ip,username,anonymous)
  962. ;max_initial_qualify_time=4 ; The maximum amount of time (in seconds) from
  963. ; startup that qualifies should be attempted on all
  964. ; contacts. If greater than the qualify_frequency
  965. ; for an aor, qualify_frequency will be used instead.
  966. ;regcontext=sipregistrations ; If regcontext is specified, Asterisk will dynamically
  967. ; create and destroy a NoOp priority 1 extension for a
  968. ; given endpoint who registers or unregisters with us.
  969. ; The extension added is the name of the endpoint.
  970. ;default_voicemail_extension=asterisk
  971. ; The voicemail extension to send in the NOTIFY Message-Account header
  972. ; if not set on endpoint or aor.
  973. ; (default: "")
  974. ;
  975. ; The following unidentified_request options are only used when "auth_username"
  976. ; matching is enabled in "endpoint_identifier_order".
  977. ;
  978. ;unidentified_request_count=5 ; The number of unidentified requests that can be
  979. ; received from a single IP address in
  980. ; unidentified_request_period seconds before a security
  981. ; event is generated. (default: 5)
  982. ;unidentified_request_period=5 ; See above. (default: 5 seconds)
  983. ;unidentified_request_prune_interval=30
  984. ; The interval at which unidentified requests
  985. ; are check to see if they can be pruned. If they're
  986. ; older than twice the unidentified_request_period,
  987. ; they're pruned.
  988. ;
  989. ;default_from_user=asterisk ; When Asterisk generates an outgoing SIP request, the
  990. ; From header username will be set to this value if
  991. ; there is no better option (such as CallerID or
  992. ; endpoint/from_user) to be used
  993. ;default_realm=asterisk ; When Asterisk generates a challenge, the digest realm
  994. ; will be set to this value if there is no better option
  995. ; (such as auth/realm) to be used.
  996. ; Asterisk Task Processor Queue Size
  997. ; On heavy loaded system with DB storage you may need to increase
  998. ; taskprocessor queue.
  999. ; If the taskprocessor queue size reached high water level,
  1000. ; the alert is triggered.
  1001. ; If the alert is set the pjsip distibutor stops processing incoming
  1002. ; requests until the alert is cleared.
  1003. ; The alert is cleared when taskprocessor queue size drops to the
  1004. ; low water clear level.
  1005. ; The next options set taskprocessor queue levels for MWI.
  1006. ;mwi_tps_queue_high=500 ; Taskprocessor high water alert trigger level.
  1007. ;mwi_tps_queue_low=450 ; Taskprocessor low water clear alert level.
  1008. ; The default is -1 for 90% of high water level.
  1009. ; Unsolicited MWI
  1010. ; If there are endpoints configured with unsolicited MWI
  1011. ; then res_pjsip_mwi module tries to send MWI to all endpoints on startup.
  1012. ;mwi_disable_initial_unsolicited=no ; Disable sending unsolicited mwi to all endpoints on startup.
  1013. ; If disabled then unsolicited mwi will start processing
  1014. ; on the endpoint's next contact update.
  1015. ;ignore_uri_user_options=no ; Enable/Disable ignoring SIP URI user field options.
  1016. ; If you have this option enabled and there are semicolons
  1017. ; in the user field of a SIP URI then the field is truncated
  1018. ; at the first semicolon. This effectively makes the semicolon
  1019. ; a non-usable character for PJSIP endpoint names, extensions,
  1020. ; and AORs. This can be useful for improving compatability with
  1021. ; an ITSP that likes to use user options for whatever reason.
  1022. ; Example:
  1023. ; URI: "sip:1235557890;phone-context=national@x.x.x.x;user=phone"
  1024. ; The user field is "1235557890;phone-context=national"
  1025. ; Which becomes this: "1235557890"
  1026. ;
  1027. ; Note: The caller-id and redirecting number strings obtained
  1028. ; from incoming SIP URI user fields are always truncated at the
  1029. ; first semicolon.
  1030. ;send_contact_status_on_update_registration=yes ; Enable sending AMI ContactStatus
  1031. ; event when a device refreshes its registration
  1032. ; (default: "yes")
  1033. ; MODULE PROVIDING BELOW SECTION(S): res_pjsip_acl
  1034. ;==========================ACL SECTION OPTIONS=========================
  1035. ;[acl]
  1036. ; SYNOPSIS: Access Control List
  1037. ;acl= ; List of IP ACL section names in acl conf (default: "")
  1038. ;contact_acl= ; List of Contact ACL section names in acl conf (default: "")
  1039. ;contact_deny= ; List of Contact header addresses to deny (default: "")
  1040. ;contact_permit= ; List of Contact header addresses to permit (default:
  1041. ; "")
  1042. ;deny= ; List of IP addresses to deny access from (default: "")
  1043. ;permit= ; List of IP addresses to permit access from (default: "")
  1044. ;type= ; Must be of type acl (default: "")
  1045. ; MODULE PROVIDING BELOW SECTION(S): res_pjsip_outbound_registration
  1046. ;==========================REGISTRATION SECTION OPTIONS=========================
  1047. ;[registration]
  1048. ; SYNOPSIS: The configuration for outbound registration
  1049. ;auth_rejection_permanent=yes ; Determines whether failed authentication
  1050. ; challenges are treated as permanent failures
  1051. ; (default: "yes")
  1052. ;client_uri= ; Client SIP URI used when attemping outbound registration
  1053. ; (default: "")
  1054. ;contact_user= ; Contact User to use in request (default: "")
  1055. ;expiration=3600 ; Expiration time for registrations in seconds
  1056. ; (default: "3600")
  1057. ;max_retries=10 ; Maximum number of registration attempts (default: "10")
  1058. ;outbound_auth= ; Authentication object to be used for outbound registrations
  1059. ; (default: "")
  1060. ;outbound_proxy= ; Proxy through which to send registrations, a full SIP URI
  1061. ; must be provided (default: "")
  1062. ;retry_interval=60 ; Interval in seconds between retries if outbound
  1063. ; registration is unsuccessful (default: "60")
  1064. ;forbidden_retry_interval=0 ; Interval used when receiving a 403 Forbidden
  1065. ; response (default: "0")
  1066. ;fatal_retry_interval=0 ; Interval used when receiving a fatal response.
  1067. ; (default: "0") A fatal response is any permanent
  1068. ; failure (non-temporary 4xx, 5xx, 6xx) response
  1069. ; received from the registrar. NOTE - if also set
  1070. ; the 'forbidden_retry_interval' takes precedence
  1071. ; over this one when a 403 is received. Also, if
  1072. ; 'auth_rejection_permanent' equals 'yes' a 401 and
  1073. ; 407 become subject to this retry interval.
  1074. ;server_uri= ; SIP URI of the server to register against (default: "")
  1075. ;transport= ; Transport used for outbound authentication (default: "")
  1076. ;line= ; When enabled this option will cause a 'line' parameter to be
  1077. ; added to the Contact header placed into the outgoing
  1078. ; registration request. If the remote server sends a call
  1079. ; this line parameter will be used to establish a relationship
  1080. ; to the outbound registration, ultimately causing the
  1081. ; configured endpoint to be used (default: "no")
  1082. ;endpoint= ; When line support is enabled this configured endpoint name
  1083. ; is used for incoming calls that are related to the outbound
  1084. ; registration (default: "")
  1085. ;type= ; Must be of type registration (default: "")
  1086. ; MODULE PROVIDING BELOW SECTION(S): res_pjsip_endpoint_identifier_ip
  1087. ;==========================IDENTIFY SECTION OPTIONS=========================
  1088. ;[identify]
  1089. ; SYNOPSIS: Identifies endpoints via some criteria.
  1090. ;
  1091. ; NOTE: If multiple matching criteria are provided then an inbound request will
  1092. ; be matched to the endpoint if it matches ANY of the criteria.
  1093. ;endpoint= ; Name of endpoint identified (default: "")
  1094. ;srv_lookups=yes ; Perform SRV lookups for provided hostnames. (default: yes)
  1095. ;match= ; Comma separated list of IP addresses, networks, or hostnames to match
  1096. ; against (default: "")
  1097. ;match_header= ; SIP header with specified value to match against (default: "")
  1098. ;type= ; Must be of type identify (default: "")
  1099. ;========================PHONEPROV_USER SECTION OPTIONS=======================
  1100. ;[phoneprov]
  1101. ; SYNOPSIS: Contains variables for autoprovisioning each user
  1102. ;endpoint= ; The endpoint from which to gather username, secret, etc. (default: "")
  1103. ;PROFILE= ; The name of a profile configured in phoneprov.conf (default: "")
  1104. ;MAC= ; The mac address for this user (default: "")
  1105. ;OTHERVAR= ; Any other name value pair to be used in templates (default: "")
  1106. ; Common variables include LINE, LINEKEYS, etc.
  1107. ; See phoneprov.conf.sample for others.
  1108. ;type= ; Must be of type phoneprov (default: "")
  1109. ; MODULE PROVIDING BELOW SECTION(S): res_pjsip_outbound_publish
  1110. ;======================OUTBOUND_PUBLISH SECTION OPTIONS=====================
  1111. ; See https://wiki.asterisk.org/wiki/display/AST/Publishing+Extension+State
  1112. ; for more information.
  1113. ;[outbound-publish]
  1114. ;type=outbound-publish ; Must be of type 'outbound-publish'.
  1115. ;expiration=3600 ; Expiration time for publications in seconds
  1116. ;outbound_auth= ; Authentication object(s) to be used for outbound
  1117. ; publishes.
  1118. ; This is a comma-delimited list of auth sections
  1119. ; defined in pjsip.conf used to respond to outbound
  1120. ; authentication challenges.
  1121. ; Using the same auth section for inbound and
  1122. ; outbound authentication is not recommended. There
  1123. ; is a difference in meaning for an empty realm
  1124. ; setting between inbound and outbound authentication
  1125. ; uses. See the auth realm description for details.
  1126. ;outbound_proxy= ; SIP URI of the outbound proxy used to send
  1127. ; publishes
  1128. ;server_uri= ; SIP URI of the server and entity to publish to.
  1129. ; This is the URI at which to find the entity and
  1130. ; server to send the outbound PUBLISH to.
  1131. ; This URI is used as the request URI of the outbound
  1132. ; PUBLISH request from Asterisk.
  1133. ;from_uri= ; SIP URI to use in the From header.
  1134. ; This is the URI that will be placed into the From
  1135. ; header of outgoing PUBLISH messages. If no URI is
  1136. ; specified then the URI provided in server_uri will
  1137. ; be used.
  1138. ;to_uri= ; SIP URI to use in the To header.
  1139. ; This is the URI that will be placed into the To
  1140. ; header of outgoing PUBLISH messages. If no URI is
  1141. ; specified then the URI provided in server_uri will
  1142. ; be used.
  1143. ;event= ; Event type of the PUBLISH.
  1144. ;max_auth_attempts= ; Maximum number of authentication attempts before
  1145. ; stopping the pub.
  1146. ;transport= ; Transport used for outbound publish.
  1147. ; A transport configured in pjsip.conf. As with other
  1148. ; res_pjsip modules, this will use the first
  1149. ; available transport of the appropriate type if
  1150. ; unconfigured.
  1151. ;multi_user=no ; Enable multi-user support (Asterisk 14+ only)
  1152. ; MODULE PROVIDING BELOW SECTION(S): res_pjsip_pubsub
  1153. ;=============================RESOURCE-LIST===================================
  1154. ; See https://wiki.asterisk.org/wiki/pages/viewpage.action?pageId=30278158
  1155. ; for more information.
  1156. ;[resource_list]
  1157. ;type=resource_list ; Must be of type 'resource_list'.
  1158. ;event= ; The SIP event package that the list resource.
  1159. ; belongs to. The SIP event package describes the
  1160. ; types of resources that Asterisk reports the state
  1161. ; of.
  1162. ;list_item= ; The name of a resource to report state on.
  1163. ; In general Asterisk looks up list items in the
  1164. ; following way:
  1165. ; 1. Check if the list item refers to another
  1166. ; configured resource list.
  1167. ; 2. Pass the name of the resource off to
  1168. ; event-package-specific handlers to find the
  1169. ; specified resource.
  1170. ; The second part means that the way the list item
  1171. ; is specified depends on what type of list this is.
  1172. ; For instance, if you have the event set to
  1173. ; presence, then list items should be in the form of
  1174. ; dialplan_extension@dialplan_context. For
  1175. ; message-summary, mailbox names should be listed.
  1176. ;full_state=no ; Indicates if the entire list's state should be
  1177. ; sent out.
  1178. ; If this option is enabled, and a resource changes
  1179. ; state, then Asterisk will construct a notification
  1180. ; that contains the state of all resources in the
  1181. ; list. If the option is disabled, Asterisk will
  1182. ; construct a notification that only contains the
  1183. ; states of resources that have changed.
  1184. ; NOTE: Even with this option disabled, there are
  1185. ; certain situations where Asterisk is forced to send
  1186. ; a notification with the states of all resources in
  1187. ; the list. When a subscriber renews or terminates
  1188. ; its subscription to the list, Asterisk MUST send
  1189. ; a full state notification.
  1190. ;notification_batch_interval=0
  1191. ; Time Asterisk should wait, in milliseconds,
  1192. ; before sending notifications.
  1193. ;==========================INBOUND_PUBLICATION================================
  1194. ; See https://wiki.asterisk.org/wiki/display/AST/Exchanging+Device+and+Mailbox+State+Using+PJSIP
  1195. ; for more information.
  1196. ;[inbound-publication]
  1197. ;type= ; Must be of type 'inbound-publication'.
  1198. ;endpoint= ; Optional name of an endpoint that is only allowed
  1199. ; to publish to this resource.
  1200. ; MODULE PROVIDING BELOW SECTION(S): res_pjsip_publish_asterisk
  1201. ;==========================ASTERISK_PUBLICATION===============================
  1202. ; See https://wiki.asterisk.org/wiki/display/AST/Exchanging+Device+and+Mailbox+State+Using+PJSIP
  1203. ; for more information.
  1204. ;[asterisk-publication]
  1205. ;type=asterisk-publication ; Must be of type 'asterisk-publication'.
  1206. ;devicestate_publish= ; Optional name of a publish item that can be used
  1207. ; to publish a req.
  1208. ;mailboxstate_publish= ; Optional name of a publish item that can be used
  1209. ; to publish a req.
  1210. ;device_state=no ; Whether we should permit incoming device state
  1211. ; events.
  1212. ;device_state_filter= ; Optional regular expression used to filter what
  1213. ; devices we accept events for.
  1214. ;mailbox_state=no ; Whether we should permit incoming mailbox state
  1215. ; events.
  1216. ;mailbox_state_filter= ; Optional regular expression used to filter what
  1217. ; mailboxes we accept events for.