pjsip: Added "reg_server" to contacts.
[asterisk/asterisk.git] / res / res_pjsip.c
1 /*
2  * Asterisk -- An open source telephony toolkit.
3  *
4  * Copyright (C) 2013, Digium, Inc.
5  *
6  * Mark Michelson <mmichelson@digium.com>
7  *
8  * See http://www.asterisk.org for more information about
9  * the Asterisk project. Please do not directly contact
10  * any of the maintainers of this project for assistance;
11  * the project provides a web site, mailing lists and IRC
12  * channels for your use.
13  *
14  * This program is free software, distributed under the terms of
15  * the GNU General Public License Version 2. See the LICENSE file
16  * at the top of the source tree.
17  */
18
19 #include "asterisk.h"
20
21 #include <pjsip.h>
22 /* Needed for SUBSCRIBE, NOTIFY, and PUBLISH method definitions */
23 #include <pjsip_simple.h>
24 #include <pjsip/sip_transaction.h>
25 #include <pj/timer.h>
26 #include <pjlib.h>
27
28 #include "asterisk/res_pjsip.h"
29 #include "res_pjsip/include/res_pjsip_private.h"
30 #include "asterisk/linkedlists.h"
31 #include "asterisk/logger.h"
32 #include "asterisk/lock.h"
33 #include "asterisk/utils.h"
34 #include "asterisk/astobj2.h"
35 #include "asterisk/module.h"
36 #include "asterisk/threadpool.h"
37 #include "asterisk/taskprocessor.h"
38 #include "asterisk/uuid.h"
39 #include "asterisk/sorcery.h"
40 #include "asterisk/file.h"
41 #include "asterisk/cli.h"
42 #include "asterisk/res_pjsip_cli.h"
43 #include "asterisk/test.h"
44 #include "asterisk/res_pjsip_presence_xml.h"
45 #include "asterisk/res_pjproject.h"
46
47 /*** MODULEINFO
48         <depend>pjproject</depend>
49         <depend>res_pjproject</depend>
50         <depend>res_sorcery_config</depend>
51         <depend>res_sorcery_memory</depend>
52         <depend>res_sorcery_astdb</depend>
53         <support_level>core</support_level>
54  ***/
55
56 /*** DOCUMENTATION
57         <configInfo name="res_pjsip" language="en_US">
58                 <synopsis>SIP Resource using PJProject</synopsis>
59                 <configFile name="pjsip.conf">
60                         <configObject name="endpoint">
61                                 <synopsis>Endpoint</synopsis>
62                                 <description><para>
63                                         The <emphasis>Endpoint</emphasis> is the primary configuration object.
64                                         It contains the core SIP related options only, endpoints are <emphasis>NOT</emphasis>
65                                         dialable entries of their own. Communication with another SIP device is
66                                         accomplished via Addresses of Record (AoRs) which have one or more
67                                         contacts assicated with them. Endpoints <emphasis>NOT</emphasis> configured to
68                                         use a <literal>transport</literal> will default to first transport found
69                                         in <filename>pjsip.conf</filename> that matches its type.
70                                         </para>
71                                         <para>Example: An Endpoint has been configured with no transport.
72                                         When it comes time to call an AoR, PJSIP will find the
73                                         first transport that matches the type. A SIP URI of <literal>sip:5000@[11::33]</literal>
74                                         will use the first IPv6 transport and try to send the request.
75                                         </para>
76                                         <para>If the anonymous endpoint identifier is in use an endpoint with the name
77                                         "anonymous@domain" will be searched for as a last resort. If this is not found
78                                         it will fall back to searching for "anonymous". If neither endpoints are found
79                                         the anonymous endpoint identifier will not return an endpoint and anonymous
80                                         calling will not be possible.
81                                         </para>
82                                 </description>
83                                 <configOption name="100rel" default="yes">
84                                         <synopsis>Allow support for RFC3262 provisional ACK tags</synopsis>
85                                         <description>
86                                                 <enumlist>
87                                                         <enum name="no" />
88                                                         <enum name="required" />
89                                                         <enum name="yes" />
90                                                 </enumlist>
91                                         </description>
92                                 </configOption>
93                                 <configOption name="aggregate_mwi" default="yes">
94                                         <synopsis>Condense MWI notifications into a single NOTIFY.</synopsis>
95                                         <description><para>When enabled, <replaceable>aggregate_mwi</replaceable> condenses message
96                                         waiting notifications from multiple mailboxes into a single NOTIFY. If it is disabled,
97                                         individual NOTIFYs are sent for each mailbox.</para></description>
98                                 </configOption>
99                                 <configOption name="allow">
100                                         <synopsis>Media Codec(s) to allow</synopsis>
101                                 </configOption>
102                                 <configOption name="aors">
103                                         <synopsis>AoR(s) to be used with the endpoint</synopsis>
104                                         <description><para>
105                                                 List of comma separated AoRs that the endpoint should be associated with.
106                                         </para></description>
107                                 </configOption>
108                                 <configOption name="auth">
109                                         <synopsis>Authentication Object(s) associated with the endpoint</synopsis>
110                                         <description><para>
111                                                 This is a comma-delimited list of <replaceable>auth</replaceable> sections defined
112                                                 in <filename>pjsip.conf</filename> to be used to verify inbound connection attempts.
113                                                 </para><para>
114                                                 Endpoints without an <literal>authentication</literal> object
115                                                 configured will allow connections without vertification.
116                                         </para></description>
117                                 </configOption>
118                                 <configOption name="callerid">
119                                         <synopsis>CallerID information for the endpoint</synopsis>
120                                         <description><para>
121                                                 Must be in the format <literal>Name &lt;Number&gt;</literal>,
122                                                 or only <literal>&lt;Number&gt;</literal>.
123                                         </para></description>
124                                 </configOption>
125                                 <configOption name="callerid_privacy">
126                                         <synopsis>Default privacy level</synopsis>
127                                         <description>
128                                                 <enumlist>
129                                                         <enum name="allowed_not_screened" />
130                                                         <enum name="allowed_passed_screen" />
131                                                         <enum name="allowed_failed_screen" />
132                                                         <enum name="allowed" />
133                                                         <enum name="prohib_not_screened" />
134                                                         <enum name="prohib_passed_screen" />
135                                                         <enum name="prohib_failed_screen" />
136                                                         <enum name="prohib" />
137                                                         <enum name="unavailable" />
138                                                 </enumlist>
139                                         </description>
140                                 </configOption>
141                                 <configOption name="callerid_tag">
142                                         <synopsis>Internal id_tag for the endpoint</synopsis>
143                                 </configOption>
144                                 <configOption name="context">
145                                         <synopsis>Dialplan context for inbound sessions</synopsis>
146                                 </configOption>
147                                 <configOption name="direct_media_glare_mitigation" default="none">
148                                         <synopsis>Mitigation of direct media (re)INVITE glare</synopsis>
149                                         <description>
150                                                 <para>
151                                                 This setting attempts to avoid creating INVITE glare scenarios
152                                                 by disabling direct media reINVITEs in one direction thereby allowing
153                                                 designated servers (according to this option) to initiate direct
154                                                 media reINVITEs without contention and significantly reducing call
155                                                 setup time.
156                                                 </para>
157                                                 <para>
158                                                 A more detailed description of how this option functions can be found on
159                                                 the Asterisk wiki https://wiki.asterisk.org/wiki/display/AST/SIP+Direct+Media+Reinvite+Glare+Avoidance
160                                                 </para>
161                                                 <enumlist>
162                                                         <enum name="none" />
163                                                         <enum name="outgoing" />
164                                                         <enum name="incoming" />
165                                                 </enumlist>
166                                         </description>
167                                 </configOption>
168                                 <configOption name="direct_media_method" default="invite">
169                                         <synopsis>Direct Media method type</synopsis>
170                                         <description>
171                                                 <para>Method for setting up Direct Media between endpoints.</para>
172                                                 <enumlist>
173                                                         <enum name="invite" />
174                                                         <enum name="reinvite">
175                                                                 <para>Alias for the <literal>invite</literal> value.</para>
176                                                         </enum>
177                                                         <enum name="update" />
178                                                 </enumlist>
179                                         </description>
180                                 </configOption>
181                                 <configOption name="connected_line_method" default="invite">
182                                         <synopsis>Connected line method type</synopsis>
183                                         <description>
184                                                 <para>Method used when updating connected line information.</para>
185                                                 <enumlist>
186                                                         <enum name="invite" />
187                                                         <enum name="reinvite">
188                                                                 <para>Alias for the <literal>invite</literal> value.</para>
189                                                         </enum>
190                                                         <enum name="update" />
191                                                 </enumlist>
192                                         </description>
193                                 </configOption>
194                                 <configOption name="direct_media" default="yes">
195                                         <synopsis>Determines whether media may flow directly between endpoints.</synopsis>
196                                 </configOption>
197                                 <configOption name="disable_direct_media_on_nat" default="no">
198                                         <synopsis>Disable direct media session refreshes when NAT obstructs the media session</synopsis>
199                                 </configOption>
200                                 <configOption name="disallow">
201                                         <synopsis>Media Codec(s) to disallow</synopsis>
202                                 </configOption>
203                                 <configOption name="dtmf_mode" default="rfc4733">
204                                         <synopsis>DTMF mode</synopsis>
205                                         <description>
206                                                 <para>This setting allows to choose the DTMF mode for endpoint communication.</para>
207                                                 <enumlist>
208                                                         <enum name="rfc4733">
209                                                                 <para>DTMF is sent out of band of the main audio stream.  This
210                                                                 supercedes the older <emphasis>RFC-2833</emphasis> used within
211                                                                 the older <literal>chan_sip</literal>.</para>
212                                                         </enum>
213                                                         <enum name="inband">
214                                                                 <para>DTMF is sent as part of audio stream.</para>
215                                                         </enum>
216                                                         <enum name="info">
217                                                                 <para>DTMF is sent as SIP INFO packets.</para>
218                                                         </enum>
219                                                         <enum name="auto">
220                                                                 <para>DTMF is sent as RFC 4733 if the other side supports it or as INBAND if not.</para>
221                                                         </enum>
222
223                                                 </enumlist>
224                                         </description>
225                                 </configOption>
226                                 <configOption name="media_address">
227                                         <synopsis>IP address used in SDP for media handling</synopsis>
228                                         <description><para>
229                                                 At the time of SDP creation, the IP address defined here will be used as
230                                                 the media address for individual streams in the SDP.
231                                         </para>
232                                         <note><para>
233                                                 Be aware that the <literal>external_media_address</literal> option, set in Transport
234                                                 configuration, can also affect the final media address used in the SDP.
235                                         </para></note>
236                                         </description>
237                                 </configOption>
238                                 <configOption name="bind_rtp_to_media_address">
239                                         <synopsis>Bind the RTP instance to the media_address</synopsis>
240                                         <description><para>
241                                                 If media_address is specified, this option causes the RTP instance to be bound to the
242                                                 specified ip address which causes the packets to be sent from that address.
243                                         </para>
244                                         </description>
245                                 </configOption>
246                                 <configOption name="force_rport" default="yes">
247                                         <synopsis>Force use of return port</synopsis>
248                                 </configOption>
249                                 <configOption name="ice_support" default="no">
250                                         <synopsis>Enable the ICE mechanism to help traverse NAT</synopsis>
251                                 </configOption>
252                                 <configOption name="identify_by" default="username,location">
253                                         <synopsis>Way(s) for Endpoint to be identified</synopsis>
254                                         <description><para>
255                                                 Endpoints and aors can be identified in multiple ways. Currently, the supported
256                                                 options are <literal>username</literal>, which matches the endpoint or aor id based on
257                                                 the username and domain in the From header (or To header for aors), and
258                                                 <literal>auth_username</literal>, which matches the endpoint or aor id based on the
259                                                 username and realm in the Authentication header.  In all cases, if an exact match
260                                                 on both username and domain/realm fails, the match will be retried with just the username.
261                                                 </para>
262                                                 <note><para>
263                                                 Identification by auth_username has some security considerations because an
264                                                 Authentication header is not present on the first message of a dialog when
265                                                 digest authentication is used.  The client can't generate it until the server
266                                                 sends the challenge in a 401 response.  Since Asterisk normally sends a security
267                                                 event when an incoming request can't be matched to an endpoint, using auth_username
268                                                 requires that the security event be deferred until a request is received with
269                                                 the Authentication header and only generated if the username doesn't result in a
270                                                 match.  This may result in a delay before an attack is recognized.  You can control
271                                                 how many unmatched requests are received from a single ip address before a security
272                                                 event is generated using the unidentified_request parameters in the "global"
273                                                 configuration object.
274                                                 </para></note>
275                                                 <note><para>Endpoints can also be identified by IP address; however, that method
276                                                 of identification is not handled by this configuration option. See the documentation
277                                                 for the <literal>identify</literal> configuration section for more details on that
278                                                 method of endpoint identification. If this option is set and an <literal>identify</literal>
279                                                 configuration section exists for the endpoint, then the endpoint can be identified in
280                                                 multiple ways.</para></note>
281                                                 <enumlist>
282                                                         <enum name="username" />
283                                                         <enum name="auth_username" />
284                                                 </enumlist>
285                                         </description>
286                                 </configOption>
287                                 <configOption name="redirect_method">
288                                         <synopsis>How redirects received from an endpoint are handled</synopsis>
289                                         <description><para>
290                                                 When a redirect is received from an endpoint there are multiple ways it can be handled.
291                                                 If this option is set to <literal>user</literal> the user portion of the redirect target
292                                                 is treated as an extension within the dialplan and dialed using a Local channel. If this option
293                                                 is set to <literal>uri_core</literal> the target URI is returned to the dialing application
294                                                 which dials it using the PJSIP channel driver and endpoint originally used. If this option is
295                                                 set to <literal>uri_pjsip</literal> the redirect occurs within chan_pjsip itself and is not exposed
296                                                 to the core at all. The <literal>uri_pjsip</literal> option has the benefit of being more efficient
297                                                 and also supporting multiple potential redirect targets. The con is that since redirection occurs
298                                                 within chan_pjsip redirecting information is not forwarded and redirection can not be
299                                                 prevented.
300                                                 </para>
301                                                 <enumlist>
302                                                         <enum name="user" />
303                                                         <enum name="uri_core" />
304                                                         <enum name="uri_pjsip" />
305                                                 </enumlist>
306                                         </description>
307                                 </configOption>
308                                 <configOption name="mailboxes">
309                                         <synopsis>NOTIFY the endpoint when state changes for any of the specified mailboxes</synopsis>
310                                         <description><para>
311                                                 Asterisk will send unsolicited MWI NOTIFY messages to the endpoint when state
312                                                 changes happen for any of the specified mailboxes. More than one mailbox can be
313                                                 specified with a comma-delimited string. app_voicemail mailboxes must be specified
314                                                 as mailbox@context; for example: mailboxes=6001@default. For mailboxes provided by
315                                                 external sources, such as through the res_external_mwi module, you must specify
316                                                 strings supported by the external system.
317                                         </para><para>
318                                                 For endpoints that SUBSCRIBE for MWI, use the <literal>mailboxes</literal> option in your AOR
319                                                 configuration.
320                                         </para></description>
321                                 </configOption>
322                                 <configOption name="mwi_subscribe_replaces_unsolicited">
323                                         <synopsis>An MWI subscribe will replace sending unsolicited NOTIFYs</synopsis>
324                                 </configOption>
325                                 <configOption name="voicemail_extension">
326                                         <synopsis>The voicemail extension to send in the NOTIFY Message-Account header</synopsis>
327                                 </configOption>
328                                 <configOption name="moh_suggest" default="default">
329                                         <synopsis>Default Music On Hold class</synopsis>
330                                 </configOption>
331                                 <configOption name="outbound_auth">
332                                         <synopsis>Authentication object used for outbound requests</synopsis>
333                                 </configOption>
334                                 <configOption name="outbound_proxy">
335                                         <synopsis>Proxy through which to send requests, a full SIP URI must be provided</synopsis>
336                                 </configOption>
337                                 <configOption name="rewrite_contact">
338                                         <synopsis>Allow Contact header to be rewritten with the source IP address-port</synopsis>
339                                         <description><para>
340                                                 On inbound SIP messages from this endpoint, the Contact header or an appropriate Record-Route
341                                                 header will be changed to have the source IP address and port. This option does not affect
342                                                 outbound messages sent to this endpoint.
343                                         </para></description>
344                                 </configOption>
345                                 <configOption name="rtp_ipv6" default="no">
346                                         <synopsis>Allow use of IPv6 for RTP traffic</synopsis>
347                                 </configOption>
348                                 <configOption name="rtp_symmetric" default="no">
349                                         <synopsis>Enforce that RTP must be symmetric</synopsis>
350                                 </configOption>
351                                 <configOption name="send_diversion" default="yes">
352                                         <synopsis>Send the Diversion header, conveying the diversion
353                                         information to the called user agent</synopsis>
354                                 </configOption>
355                                 <configOption name="send_pai" default="no">
356                                         <synopsis>Send the P-Asserted-Identity header</synopsis>
357                                 </configOption>
358                                 <configOption name="send_rpid" default="no">
359                                         <synopsis>Send the Remote-Party-ID header</synopsis>
360                                 </configOption>
361                                 <configOption name="rpid_immediate" default="no">
362                                         <synopsis>Immediately send connected line updates on unanswered incoming calls.</synopsis>
363                                         <description>
364                                                 <para>When enabled, immediately send <emphasis>180 Ringing</emphasis>
365                                                 or <emphasis>183 Progress</emphasis> response messages to the
366                                                 caller if the connected line information is updated before
367                                                 the call is answered.  This can send a <emphasis>180 Ringing</emphasis>
368                                                 response before the call has even reached the far end.  The
369                                                 caller can start hearing ringback before the far end even gets
370                                                 the call.  Many phones tend to grab the first connected line
371                                                 information and refuse to update the display if it changes.  The
372                                                 first information is not likely to be correct if the call
373                                                 goes to an endpoint not under the control of this Asterisk
374                                                 box.</para>
375                                                 <para>When disabled, a connected line update must wait for
376                                                 another reason to send a message with the connected line
377                                                 information to the caller before the call is answered.  You can
378                                                 trigger the sending of the information by using an appropriate
379                                                 dialplan application such as <emphasis>Ringing</emphasis>.</para>
380                                         </description>
381                                 </configOption>
382                                 <configOption name="timers_min_se" default="90">
383                                         <synopsis>Minimum session timers expiration period</synopsis>
384                                         <description><para>
385                                                 Minimium session timer expiration period. Time in seconds.
386                                         </para></description>
387                                 </configOption>
388                                 <configOption name="timers" default="yes">
389                                         <synopsis>Session timers for SIP packets</synopsis>
390                                         <description>
391                                                 <enumlist>
392                                                         <enum name="no" />
393                                                         <enum name="yes" />
394                                                         <enum name="required" />
395                                                         <enum name="always" />
396                                                         <enum name="forced"><para>Alias of always</para></enum>
397                                                 </enumlist>
398                                         </description>
399                                 </configOption>
400                                 <configOption name="timers_sess_expires" default="1800">
401                                         <synopsis>Maximum session timer expiration period</synopsis>
402                                         <description><para>
403                                                 Maximium session timer expiration period. Time in seconds.
404                                         </para></description>
405                                 </configOption>
406                                 <configOption name="transport">
407                                         <synopsis>Desired transport configuration</synopsis>
408                                         <description><para>
409                                                 This will set the desired transport configuration to send SIP data through.
410                                                 </para>
411                                                 <warning><para>Not specifying a transport will <emphasis>DEFAULT</emphasis>
412                                                 to the first configured transport in <filename>pjsip.conf</filename> which is
413                                                 valid for the URI we are trying to contact.
414                                                 </para></warning>
415                                                 <warning><para>Transport configuration is not affected by reloads. In order to
416                                                 change transports, a full Asterisk restart is required</para></warning>
417                                         </description>
418                                 </configOption>
419                                 <configOption name="trust_id_inbound" default="no">
420                                         <synopsis>Accept identification information received from this endpoint</synopsis>
421                                         <description><para>This option determines whether Asterisk will accept
422                                         identification from the endpoint from headers such as P-Asserted-Identity
423                                         or Remote-Party-ID header. This option applies both to calls originating from the
424                                         endpoint and calls originating from Asterisk. If <literal>no</literal>, the
425                                         configured Caller-ID from pjsip.conf will always be used as the identity for
426                                         the endpoint.</para></description>
427                                 </configOption>
428                                 <configOption name="trust_id_outbound" default="no">
429                                         <synopsis>Send private identification details to the endpoint.</synopsis>
430                                         <description><para>This option determines whether res_pjsip will send private
431                                         identification information to the endpoint. If <literal>no</literal>,
432                                         private Caller-ID information will not be forwarded to the endpoint.
433                                         "Private" in this case refers to any method of restricting identification.
434                                         Example: setting <replaceable>callerid_privacy</replaceable> to any
435                                         <literal>prohib</literal> variation.
436                                         Example: If <replaceable>trust_id_inbound</replaceable> is set to
437                                         <literal>yes</literal>, the presence of a <literal>Privacy: id</literal>
438                                         header in a SIP request or response would indicate the identification
439                                         provided in the request is private.</para></description>
440                                 </configOption>
441                                 <configOption name="type">
442                                         <synopsis>Must be of type 'endpoint'.</synopsis>
443                                 </configOption>
444                                 <configOption name="use_ptime" default="no">
445                                         <synopsis>Use Endpoint's requested packetisation interval</synopsis>
446                                 </configOption>
447                                 <configOption name="use_avpf" default="no">
448                                         <synopsis>Determines whether res_pjsip will use and enforce usage of AVPF for this
449                                         endpoint.</synopsis>
450                                         <description><para>
451                                                 If set to <literal>yes</literal>, res_pjsip will use the AVPF or SAVPF RTP
452                                                 profile for all media offers on outbound calls and media updates and will
453                                                 decline media offers not using the AVPF or SAVPF profile.
454                                         </para><para>
455                                                 If set to <literal>no</literal>, res_pjsip will use the AVP or SAVP RTP
456                                                 profile for all media offers on outbound calls and media updates, and will
457                                                 decline media offers not using the AVP or SAVP profile.
458                                         </para></description>
459                                 </configOption>
460                                 <configOption name="force_avp" default="no">
461                                         <synopsis>Determines whether res_pjsip will use and enforce usage of AVP,
462                                         regardless of the RTP profile in use for this endpoint.</synopsis>
463                                         <description><para>
464                                                 If set to <literal>yes</literal>, res_pjsip will use the AVP, AVPF, SAVP, or
465                                                 SAVPF RTP profile for all media offers on outbound calls and media updates including
466                                                 those for DTLS-SRTP streams.
467                                         </para><para>
468                                                 If set to <literal>no</literal>, res_pjsip will use the respective RTP profile
469                                                 depending on configuration.
470                                         </para></description>
471                                 </configOption>
472                                 <configOption name="media_use_received_transport" default="no">
473                                         <synopsis>Determines whether res_pjsip will use the media transport received in the
474                                         offer SDP in the corresponding answer SDP.</synopsis>
475                                         <description><para>
476                                                 If set to <literal>yes</literal>, res_pjsip will use the received media transport.
477                                         </para><para>
478                                                 If set to <literal>no</literal>, res_pjsip will use the respective RTP profile
479                                                 depending on configuration.
480                                         </para></description>
481                                 </configOption>
482                                 <configOption name="media_encryption" default="no">
483                                         <synopsis>Determines whether res_pjsip will use and enforce usage of media encryption
484                                         for this endpoint.</synopsis>
485                                         <description>
486                                                 <enumlist>
487                                                         <enum name="no"><para>
488                                                                 res_pjsip will offer no encryption and allow no encryption to be setup.
489                                                         </para></enum>
490                                                         <enum name="sdes"><para>
491                                                                 res_pjsip will offer standard SRTP setup via in-SDP keys. Encrypted SIP
492                                                                 transport should be used in conjunction with this option to prevent
493                                                                 exposure of media encryption keys.
494                                                         </para></enum>
495                                                         <enum name="dtls"><para>
496                                                                 res_pjsip will offer DTLS-SRTP setup.
497                                                         </para></enum>
498                                                 </enumlist>
499                                         </description>
500                                 </configOption>
501                                 <configOption name="media_encryption_optimistic" default="no">
502                                         <synopsis>Determines whether encryption should be used if possible but does not terminate the
503                                         session if not achieved.</synopsis>
504                                         <description><para>
505                                                 This option only applies if <replaceable>media_encryption</replaceable> is
506                                                 set to <literal>sdes</literal> or <literal>dtls</literal>.
507                                         </para></description>
508                                 </configOption>
509                                 <configOption name="g726_non_standard" default="no">
510                                         <synopsis>Force g.726 to use AAL2 packing order when negotiating g.726 audio</synopsis>
511                                         <description><para>
512                                                 When set to "yes" and an endpoint negotiates g.726 audio then use g.726 for AAL2
513                                                 packing order instead of what is recommended by RFC3551. Since this essentially
514                                                 replaces the underlying 'g726' codec with 'g726aal2' then 'g726aal2' needs to be
515                                                 specified in the endpoint's allowed codec list.
516                                         </para></description>
517                                 </configOption>
518                                 <configOption name="inband_progress" default="no">
519                                         <synopsis>Determines whether chan_pjsip will indicate ringing using inband
520                                             progress.</synopsis>
521                                         <description><para>
522                                                 If set to <literal>yes</literal>, chan_pjsip will send a 183 Session Progress
523                                                 when told to indicate ringing and will immediately start sending ringing
524                                                 as audio.
525                                         </para><para>
526                                                 If set to <literal>no</literal>, chan_pjsip will send a 180 Ringing when told
527                                                 to indicate ringing and will NOT send it as audio.
528                                         </para></description>
529                                 </configOption>
530                                 <configOption name="call_group">
531                                         <synopsis>The numeric pickup groups for a channel.</synopsis>
532                                         <description><para>
533                                                 Can be set to a comma separated list of numbers or ranges between the values
534                                                 of 0-63 (maximum of 64 groups).
535                                         </para></description>
536                                 </configOption>
537                                 <configOption name="pickup_group">
538                                         <synopsis>The numeric pickup groups that a channel can pickup.</synopsis>
539                                         <description><para>
540                                                 Can be set to a comma separated list of numbers or ranges between the values
541                                                 of 0-63 (maximum of 64 groups).
542                                         </para></description>
543                                 </configOption>
544                                 <configOption name="named_call_group">
545                                         <synopsis>The named pickup groups for a channel.</synopsis>
546                                         <description><para>
547                                                 Can be set to a comma separated list of case sensitive strings limited by
548                                                 supported line length.
549                                         </para></description>
550                                 </configOption>
551                                 <configOption name="named_pickup_group">
552                                         <synopsis>The named pickup groups that a channel can pickup.</synopsis>
553                                         <description><para>
554                                                 Can be set to a comma separated list of case sensitive strings limited by
555                                                 supported line length.
556                                         </para></description>
557                                 </configOption>
558                                 <configOption name="device_state_busy_at" default="0">
559                                         <synopsis>The number of in-use channels which will cause busy to be returned as device state</synopsis>
560                                         <description><para>
561                                                 When the number of in-use channels for the endpoint matches the devicestate_busy_at setting the
562                                                 PJSIP channel driver will return busy as the device state instead of in use.
563                                         </para></description>
564                                 </configOption>
565                                 <configOption name="t38_udptl" default="no">
566                                         <synopsis>Whether T.38 UDPTL support is enabled or not</synopsis>
567                                         <description><para>
568                                                 If set to yes T.38 UDPTL support will be enabled, and T.38 negotiation requests will be accepted
569                                                 and relayed.
570                                         </para></description>
571                                 </configOption>
572                                 <configOption name="t38_udptl_ec" default="none">
573                                         <synopsis>T.38 UDPTL error correction method</synopsis>
574                                         <description>
575                                                 <enumlist>
576                                                         <enum name="none"><para>
577                                                                 No error correction should be used.
578                                                         </para></enum>
579                                                         <enum name="fec"><para>
580                                                                 Forward error correction should be used.
581                                                         </para></enum>
582                                                         <enum name="redundancy"><para>
583                                                                 Redundacy error correction should be used.
584                                                         </para></enum>
585                                                 </enumlist>
586                                         </description>
587                                 </configOption>
588                                 <configOption name="t38_udptl_maxdatagram" default="0">
589                                         <synopsis>T.38 UDPTL maximum datagram size</synopsis>
590                                         <description><para>
591                                                 This option can be set to override the maximum datagram of a remote endpoint for broken
592                                                 endpoints.
593                                         </para></description>
594                                 </configOption>
595                                 <configOption name="fax_detect" default="no">
596                                         <synopsis>Whether CNG tone detection is enabled</synopsis>
597                                         <description><para>
598                                                 This option can be set to send the session to the fax extension when a CNG tone is
599                                                 detected.
600                                         </para></description>
601                                 </configOption>
602                                 <configOption name="t38_udptl_nat" default="no">
603                                         <synopsis>Whether NAT support is enabled on UDPTL sessions</synopsis>
604                                         <description><para>
605                                                 When enabled the UDPTL stack will send UDPTL packets to the source address of
606                                                 received packets.
607                                         </para></description>
608                                 </configOption>
609                                 <configOption name="t38_udptl_ipv6" default="no">
610                                         <synopsis>Whether IPv6 is used for UDPTL Sessions</synopsis>
611                                         <description><para>
612                                                 When enabled the UDPTL stack will use IPv6.
613                                         </para></description>
614                                 </configOption>
615                                 <configOption name="tone_zone">
616                                         <synopsis>Set which country's indications to use for channels created for this endpoint.</synopsis>
617                                 </configOption>
618                                 <configOption name="language">
619                                         <synopsis>Set the default language to use for channels created for this endpoint.</synopsis>
620                                 </configOption>
621                                 <configOption name="one_touch_recording" default="no">
622                                         <synopsis>Determines whether one-touch recording is allowed for this endpoint.</synopsis>
623                                         <see-also>
624                                                 <ref type="configOption">record_on_feature</ref>
625                                                 <ref type="configOption">record_off_feature</ref>
626                                         </see-also>
627                                 </configOption>
628                                 <configOption name="record_on_feature" default="automixmon">
629                                         <synopsis>The feature to enact when one-touch recording is turned on.</synopsis>
630                                         <description>
631                                                 <para>When an INFO request for one-touch recording arrives with a Record header set to "on", this
632                                                 feature will be enabled for the channel. The feature designated here can be any built-in
633                                                 or dynamic feature defined in features.conf.</para>
634                                                 <note><para>This setting has no effect if the endpoint's one_touch_recording option is disabled</para></note>
635                                         </description>
636                                         <see-also>
637                                                 <ref type="configOption">one_touch_recording</ref>
638                                                 <ref type="configOption">record_off_feature</ref>
639                                         </see-also>
640                                 </configOption>
641                                 <configOption name="record_off_feature" default="automixmon">
642                                         <synopsis>The feature to enact when one-touch recording is turned off.</synopsis>
643                                         <description>
644                                                 <para>When an INFO request for one-touch recording arrives with a Record header set to "off", this
645                                                 feature will be enabled for the channel. The feature designated here can be any built-in
646                                                 or dynamic feature defined in features.conf.</para>
647                                                 <note><para>This setting has no effect if the endpoint's one_touch_recording option is disabled</para></note>
648                                         </description>
649                                         <see-also>
650                                                 <ref type="configOption">one_touch_recording</ref>
651                                                 <ref type="configOption">record_on_feature</ref>
652                                         </see-also>
653                                 </configOption>
654                                 <configOption name="rtp_engine" default="asterisk">
655                                         <synopsis>Name of the RTP engine to use for channels created for this endpoint</synopsis>
656                                 </configOption>
657                                 <configOption name="allow_transfer" default="yes">
658                                         <synopsis>Determines whether SIP REFER transfers are allowed for this endpoint</synopsis>
659                                 </configOption>
660                                 <configOption name="user_eq_phone" default="no">
661                                         <synopsis>Determines whether a user=phone parameter is placed into the request URI if the user is determined to be a phone number</synopsis>
662                                 </configOption>
663                                 <configOption name="moh_passthrough" default="no">
664                                         <synopsis>Determines whether hold and unhold will be passed through using re-INVITEs with recvonly and sendrecv to the remote side</synopsis>
665                                 </configOption>
666                                 <configOption name="sdp_owner" default="-">
667                                         <synopsis>String placed as the username portion of an SDP origin (o=) line.</synopsis>
668                                 </configOption>
669                                 <configOption name="sdp_session" default="Asterisk">
670                                         <synopsis>String used for the SDP session (s=) line.</synopsis>
671                                 </configOption>
672                                 <configOption name="tos_audio">
673                                         <synopsis>DSCP TOS bits for audio streams</synopsis>
674                                         <description><para>
675                                                 See https://wiki.asterisk.org/wiki/display/AST/IP+Quality+of+Service for more information about QoS settings
676                                         </para></description>
677                                 </configOption>
678                                 <configOption name="tos_video">
679                                         <synopsis>DSCP TOS bits for video streams</synopsis>
680                                         <description><para>
681                                                 See https://wiki.asterisk.org/wiki/display/AST/IP+Quality+of+Service for more information about QoS settings
682                                         </para></description>
683                                 </configOption>
684                                 <configOption name="cos_audio">
685                                         <synopsis>Priority for audio streams</synopsis>
686                                         <description><para>
687                                                 See https://wiki.asterisk.org/wiki/display/AST/IP+Quality+of+Service for more information about QoS settings
688                                         </para></description>
689                                 </configOption>
690                                 <configOption name="cos_video">
691                                         <synopsis>Priority for video streams</synopsis>
692                                         <description><para>
693                                                 See https://wiki.asterisk.org/wiki/display/AST/IP+Quality+of+Service for more information about QoS settings
694                                         </para></description>
695                                 </configOption>
696                                 <configOption name="allow_subscribe" default="yes">
697                                         <synopsis>Determines if endpoint is allowed to initiate subscriptions with Asterisk.</synopsis>
698                                 </configOption>
699                                 <configOption name="sub_min_expiry" default="60">
700                                         <synopsis>The minimum allowed expiry time for subscriptions initiated by the endpoint.</synopsis>
701                                 </configOption>
702                                 <configOption name="from_user">
703                                         <synopsis>Username to use in From header for requests to this endpoint.</synopsis>
704                                 </configOption>
705                                 <configOption name="mwi_from_user">
706                                         <synopsis>Username to use in From header for unsolicited MWI NOTIFYs to this endpoint.</synopsis>
707                                 </configOption>
708                                 <configOption name="from_domain">
709                                         <synopsis>Domain to user in From header for requests to this endpoint.</synopsis>
710                                 </configOption>
711                                 <configOption name="dtls_verify">
712                                         <synopsis>Verify that the provided peer certificate is valid</synopsis>
713                                         <description><para>
714                                                 This option only applies if <replaceable>media_encryption</replaceable> is
715                                                 set to <literal>dtls</literal>.
716                                         </para></description>
717                                 </configOption>
718                                 <configOption name="dtls_rekey">
719                                         <synopsis>Interval at which to renegotiate the TLS session and rekey the SRTP session</synopsis>
720                                         <description><para>
721                                                 This option only applies if <replaceable>media_encryption</replaceable> is
722                                                 set to <literal>dtls</literal>.
723                                         </para><para>
724                                                 If this is not set or the value provided is 0 rekeying will be disabled.
725                                         </para></description>
726                                 </configOption>
727                                 <configOption name="dtls_cert_file">
728                                         <synopsis>Path to certificate file to present to peer</synopsis>
729                                         <description><para>
730                                                 This option only applies if <replaceable>media_encryption</replaceable> is
731                                                 set to <literal>dtls</literal>.
732                                         </para></description>
733                                 </configOption>
734                                 <configOption name="dtls_private_key">
735                                         <synopsis>Path to private key for certificate file</synopsis>
736                                         <description><para>
737                                                 This option only applies if <replaceable>media_encryption</replaceable> is
738                                                 set to <literal>dtls</literal>.
739                                         </para></description>
740                                 </configOption>
741                                 <configOption name="dtls_cipher">
742                                         <synopsis>Cipher to use for DTLS negotiation</synopsis>
743                                         <description><para>
744                                                 This option only applies if <replaceable>media_encryption</replaceable> is
745                                                 set to <literal>dtls</literal>.
746                                         </para>
747                                         <para>Many options for acceptable ciphers. See link for more:</para>
748                                         <para>http://www.openssl.org/docs/apps/ciphers.html#CIPHER_STRINGS
749                                         </para></description>
750                                 </configOption>
751                                 <configOption name="dtls_ca_file">
752                                         <synopsis>Path to certificate authority certificate</synopsis>
753                                         <description><para>
754                                                 This option only applies if <replaceable>media_encryption</replaceable> is
755                                                 set to <literal>dtls</literal>.
756                                         </para></description>
757                                 </configOption>
758                                 <configOption name="dtls_ca_path">
759                                         <synopsis>Path to a directory containing certificate authority certificates</synopsis>
760                                         <description><para>
761                                                 This option only applies if <replaceable>media_encryption</replaceable> is
762                                                 set to <literal>dtls</literal>.
763                                         </para></description>
764                                 </configOption>
765                                 <configOption name="dtls_setup">
766                                         <synopsis>Whether we are willing to accept connections, connect to the other party, or both.</synopsis>
767                                         <description>
768                                                 <para>
769                                                         This option only applies if <replaceable>media_encryption</replaceable> is
770                                                         set to <literal>dtls</literal>.
771                                                 </para>
772                                                 <enumlist>
773                                                         <enum name="active"><para>
774                                                                 res_pjsip will make a connection to the peer.
775                                                         </para></enum>
776                                                         <enum name="passive"><para>
777                                                                 res_pjsip will accept connections from the peer.
778                                                         </para></enum>
779                                                         <enum name="actpass"><para>
780                                                                 res_pjsip will offer and accept connections from the peer.
781                                                         </para></enum>
782                                                 </enumlist>
783                                         </description>
784                                 </configOption>
785                                 <configOption name="dtls_fingerprint">
786                                         <synopsis>Type of hash to use for the DTLS fingerprint in the SDP.</synopsis>
787                                         <description>
788                                                 <para>
789                                                         This option only applies if <replaceable>media_encryption</replaceable> is
790                                                         set to <literal>dtls</literal>.
791                                                 </para>
792                                                 <enumlist>
793                                                         <enum name="SHA-256"></enum>
794                                                         <enum name="SHA-1"></enum>
795                                                 </enumlist>
796                                         </description>
797                                 </configOption>
798                                 <configOption name="srtp_tag_32">
799                                         <synopsis>Determines whether 32 byte tags should be used instead of 80 byte tags.</synopsis>
800                                         <description><para>
801                                                 This option only applies if <replaceable>media_encryption</replaceable> is
802                                                 set to <literal>sdes</literal> or <literal>dtls</literal>.
803                                         </para></description>
804                                 </configOption>
805                                 <configOption name="set_var">
806                                         <synopsis>Variable set on a channel involving the endpoint.</synopsis>
807                                         <description><para>
808                                                 When a new channel is created using the endpoint set the specified
809                                                 variable(s) on that channel. For multiple channel variables specify
810                                                 multiple 'set_var'(s).
811                                         </para></description>
812                                 </configOption>
813                                 <configOption name="message_context">
814                                         <synopsis>Context to route incoming MESSAGE requests to.</synopsis>
815                                         <description><para>
816                                                 If specified, incoming MESSAGE requests will be routed to the indicated
817                                                 dialplan context. If no <replaceable>message_context</replaceable> is
818                                                 specified, then the <replaceable>context</replaceable> setting is used.
819                                         </para></description>
820                                 </configOption>
821                                 <configOption name="accountcode">
822                                         <synopsis>An accountcode to set automatically on any channels created for this endpoint.</synopsis>
823                                         <description><para>
824                                                 If specified, any channel created for this endpoint will automatically
825                                                 have this accountcode set on it.
826                                         </para></description>
827                                 </configOption>
828                                 <configOption name="rtp_keepalive">
829                                         <synopsis>Number of seconds between RTP comfort noise keepalive packets.</synopsis>
830                                         <description><para>
831                                                 At the specified interval, Asterisk will send an RTP comfort noise frame. This may
832                                                 be useful for situations where Asterisk is behind a NAT or firewall and must keep
833                                                 a hole open in order to allow for media to arrive at Asterisk.
834                                         </para></description>
835                                 </configOption>
836                                 <configOption name="rtp_timeout" default="0">
837                                         <synopsis>Maximum number of seconds without receiving RTP (while off hold) before terminating call.</synopsis>
838                                         <description><para>
839                                                 This option configures the number of seconds without RTP (while off hold) before
840                                                 considering a channel as dead. When the number of seconds is reached the underlying
841                                                 channel is hung up. By default this option is set to 0, which means do not check.
842                                         </para></description>
843                                 </configOption>
844                                 <configOption name="rtp_timeout_hold" default="0">
845                                         <synopsis>Maximum number of seconds without receiving RTP (while on hold) before terminating call.</synopsis>
846                                         <description><para>
847                                                 This option configures the number of seconds without RTP (while on hold) before
848                                                 considering a channel as dead. When the number of seconds is reached the underlying
849                                                 channel is hung up. By default this option is set to 0, which means do not check.
850                                         </para></description>
851                                 </configOption>
852                         </configObject>
853                         <configObject name="auth">
854                                 <synopsis>Authentication type</synopsis>
855                                 <description><para>
856                                         Authentication objects hold the authentication information for use
857                                         by other objects such as <literal>endpoints</literal> or <literal>registrations</literal>.
858                                         This also allows for multiple objects to use a single auth object. See
859                                         the <literal>auth_type</literal> config option for password style choices.
860                                 </para></description>
861                                 <configOption name="auth_type" default="userpass">
862                                         <synopsis>Authentication type</synopsis>
863                                         <description><para>
864                                                 This option specifies which of the password style config options should be read
865                                                 when trying to authenticate an endpoint inbound request. If set to <literal>userpass</literal>
866                                                 then we'll read from the 'password' option. For <literal>md5</literal> we'll read
867                                                 from 'md5_cred'.
868                                                 </para>
869                                                 <enumlist>
870                                                         <enum name="md5"/>
871                                                         <enum name="userpass"/>
872                                                 </enumlist>
873                                         </description>
874                                 </configOption>
875                                 <configOption name="nonce_lifetime" default="32">
876                                         <synopsis>Lifetime of a nonce associated with this authentication config.</synopsis>
877                                 </configOption>
878                                 <configOption name="md5_cred">
879                                         <synopsis>MD5 Hash used for authentication.</synopsis>
880                                         <description><para>Only used when auth_type is <literal>md5</literal>.</para></description>
881                                 </configOption>
882                                 <configOption name="password">
883                                         <synopsis>PlainText password used for authentication.</synopsis>
884                                         <description><para>Only used when auth_type is <literal>userpass</literal>.</para></description>
885                                 </configOption>
886                                 <configOption name="realm" default="asterisk">
887                                         <synopsis>SIP realm for endpoint</synopsis>
888                                 </configOption>
889                                 <configOption name="type">
890                                         <synopsis>Must be 'auth'</synopsis>
891                                 </configOption>
892                                 <configOption name="username">
893                                         <synopsis>Username to use for account</synopsis>
894                                 </configOption>
895                         </configObject>
896                         <configObject name="domain_alias">
897                                 <synopsis>Domain Alias</synopsis>
898                                 <description><para>
899                                         Signifies that a domain is an alias. If the domain on a session is
900                                         not found to match an AoR then this object is used to see if we have
901                                         an alias for the AoR to which the endpoint is binding. This objects
902                                         name as defined in configuration should be the domain alias and a
903                                         config option is provided to specify the domain to be aliased.
904                                 </para></description>
905                                 <configOption name="type">
906                                         <synopsis>Must be of type 'domain_alias'.</synopsis>
907                                 </configOption>
908                                 <configOption name="domain">
909                                         <synopsis>Domain to be aliased</synopsis>
910                                 </configOption>
911                         </configObject>
912                         <configObject name="transport">
913                                 <synopsis>SIP Transport</synopsis>
914                                 <description><para>
915                                         <emphasis>Transports</emphasis>
916                                         </para>
917                                         <para>There are different transports and protocol derivatives
918                                                 supported by <literal>res_pjsip</literal>. They are in order of
919                                                 preference: UDP, TCP, and WebSocket (WS).</para>
920                                         <note><para>Changes to transport configuration in pjsip.conf will only be
921                                                 effected on a complete restart of Asterisk. A module reload
922                                                 will not suffice.</para></note>
923                                 </description>
924                                 <configOption name="async_operations" default="1">
925                                         <synopsis>Number of simultaneous Asynchronous Operations</synopsis>
926                                 </configOption>
927                                 <configOption name="bind">
928                                         <synopsis>IP Address and optional port to bind to for this transport</synopsis>
929                                 </configOption>
930                                 <configOption name="ca_list_file">
931                                         <synopsis>File containing a list of certificates to read (TLS ONLY)</synopsis>
932                                 </configOption>
933                                 <configOption name="ca_list_path">
934                                         <synopsis>Path to directory containing a list of certificates to read (TLS ONLY)</synopsis>
935                                 </configOption>
936                                 <configOption name="cert_file">
937                                         <synopsis>Certificate file for endpoint (TLS ONLY)</synopsis>
938                                         <description><para>
939                                                 A path to a .crt or .pem file can be provided.  However, only
940                                                 the certificate is read from the file, not the private key.
941                                                 The <literal>priv_key_file</literal> option must supply a
942                                                 matching key file.
943                                         </para></description>
944                                 </configOption>
945                                 <configOption name="cipher">
946                                         <synopsis>Preferred cryptography cipher names (TLS ONLY)</synopsis>
947                                         <description>
948                                         <para>Comma separated list of cipher names or numeric equivalents.
949                                                 Numeric equivalents can be either decimal or hexadecimal (0xX).
950                                         </para>
951                                         <para>There are many cipher names.  Use the CLI command
952                                                 <literal>pjsip list ciphers</literal> to see a list of cipher
953                                                 names available for your installation.  See link for more:</para>
954                                         <para>http://www.openssl.org/docs/apps/ciphers.html#CIPHER_SUITE_NAMES
955                                         </para>
956                                         </description>
957                                 </configOption>
958                                 <configOption name="domain">
959                                         <synopsis>Domain the transport comes from</synopsis>
960                                 </configOption>
961                                 <configOption name="external_media_address">
962                                         <synopsis>External IP address to use in RTP handling</synopsis>
963                                         <description><para>
964                                                 When a request or response is sent out, if the destination of the
965                                                 message is outside the IP network defined in the option <literal>localnet</literal>,
966                                                 and the media address in the SDP is within the localnet network, then the
967                                                 media address in the SDP will be rewritten to the value defined for
968                                                 <literal>external_media_address</literal>.
969                                         </para></description>
970                                 </configOption>
971                                 <configOption name="external_signaling_address">
972                                         <synopsis>External address for SIP signalling</synopsis>
973                                 </configOption>
974                                 <configOption name="external_signaling_port" default="0">
975                                         <synopsis>External port for SIP signalling</synopsis>
976                                 </configOption>
977                                 <configOption name="method">
978                                         <synopsis>Method of SSL transport (TLS ONLY)</synopsis>
979                                         <description>
980                                                 <enumlist>
981                                                         <enum name="default">
982                                                                 <para>The default as defined by PJSIP. This is currently TLSv1, but may change with future releases.</para>
983                                                         </enum>
984                                                         <enum name="unspecified">
985                                                                 <para>This option is equivalent to setting 'default'</para>
986                                                         </enum>
987                                                         <enum name="tlsv1" />
988                                                         <enum name="sslv2" />
989                                                         <enum name="sslv3" />
990                                                         <enum name="sslv23" />
991                                                 </enumlist>
992                                         </description>
993                                 </configOption>
994                                 <configOption name="local_net">
995                                         <synopsis>Network to consider local (used for NAT purposes).</synopsis>
996                                         <description><para>This must be in CIDR or dotted decimal format with the IP
997                                         and mask separated with a slash ('/').</para></description>
998                                 </configOption>
999                                 <configOption name="password">
1000                                         <synopsis>Password required for transport</synopsis>
1001                                 </configOption>
1002                                 <configOption name="priv_key_file">
1003                                         <synopsis>Private key file (TLS ONLY)</synopsis>
1004                                 </configOption>
1005                                 <configOption name="protocol" default="udp">
1006                                         <synopsis>Protocol to use for SIP traffic</synopsis>
1007                                         <description>
1008                                                 <enumlist>
1009                                                         <enum name="udp" />
1010                                                         <enum name="tcp" />
1011                                                         <enum name="tls" />
1012                                                         <enum name="ws" />
1013                                                         <enum name="wss" />
1014                                                 </enumlist>
1015                                         </description>
1016                                 </configOption>
1017                                 <configOption name="require_client_cert" default="false">
1018                                         <synopsis>Require client certificate (TLS ONLY)</synopsis>
1019                                 </configOption>
1020                                 <configOption name="type">
1021                                         <synopsis>Must be of type 'transport'.</synopsis>
1022                                 </configOption>
1023                                 <configOption name="verify_client" default="false">
1024                                         <synopsis>Require verification of client certificate (TLS ONLY)</synopsis>
1025                                 </configOption>
1026                                 <configOption name="verify_server" default="false">
1027                                         <synopsis>Require verification of server certificate (TLS ONLY)</synopsis>
1028                                 </configOption>
1029                                 <configOption name="tos" default="false">
1030                                         <synopsis>Enable TOS for the signalling sent over this transport</synopsis>
1031                                         <description>
1032                                         <para>See <literal>https://wiki.asterisk.org/wiki/display/AST/IP+Quality+of+Service</literal>
1033                                         for more information on this parameter.</para>
1034                                         <note><para>This option does not apply to the <replaceable>ws</replaceable>
1035                                         or the <replaceable>wss</replaceable> protocols.</para></note>
1036                                         </description>
1037                                 </configOption>
1038                                 <configOption name="cos" default="false">
1039                                         <synopsis>Enable COS for the signalling sent over this transport</synopsis>
1040                                         <description>
1041                                         <para>See <literal>https://wiki.asterisk.org/wiki/display/AST/IP+Quality+of+Service</literal>
1042                                         for more information on this parameter.</para>
1043                                         <note><para>This option does not apply to the <replaceable>ws</replaceable>
1044                                         or the <replaceable>wss</replaceable> protocols.</para></note>
1045                                         </description>
1046                                 </configOption>
1047                                 <configOption name="websocket_write_timeout">
1048                                         <synopsis>The timeout (in milliseconds) to set on WebSocket connections.</synopsis>
1049                                         <description>
1050                                                 <para>If a websocket connection accepts input slowly, the timeout
1051                                                 for writes to it can be increased to keep it from being disconnected.
1052                                                 Value is in milliseconds; default is 100 ms.</para>
1053                                         </description>
1054                                 </configOption>
1055                                 <configOption name="allow_reload" default="no">
1056                                         <synopsis>Allow this transport to be reloaded.</synopsis>
1057                                         <description>
1058                                                 <para>Allow this transport to be reloaded when res_pjsip is reloaded.
1059                                                 This option defaults to "no" because reloading a transport may disrupt
1060                                                 in-progress calls.</para>
1061                                         </description>
1062                                 </configOption>
1063                         </configObject>
1064                         <configObject name="contact">
1065                                 <synopsis>A way of creating an aliased name to a SIP URI</synopsis>
1066                                 <description><para>
1067                                         Contacts are a way to hide SIP URIs from the dialplan directly.
1068                                         They are also used to make a group of contactable parties when
1069                                         in use with <literal>AoR</literal> lists.
1070                                 </para></description>
1071                                 <configOption name="type">
1072                                         <synopsis>Must be of type 'contact'.</synopsis>
1073                                 </configOption>
1074                                 <configOption name="uri">
1075                                         <synopsis>SIP URI to contact peer</synopsis>
1076                                 </configOption>
1077                                 <configOption name="expiration_time">
1078                                         <synopsis>Time to keep alive a contact</synopsis>
1079                                         <description><para>
1080                                                 Time to keep alive a contact. String style specification.
1081                                         </para></description>
1082                                 </configOption>
1083                                 <configOption name="qualify_frequency" default="0">
1084                                         <synopsis>Interval at which to qualify a contact</synopsis>
1085                                         <description><para>
1086                                                 Interval between attempts to qualify the contact for reachability.
1087                                                 If <literal>0</literal> never qualify. Time in seconds.
1088                                         </para></description>
1089                                 </configOption>
1090                                 <configOption name="qualify_timeout" default="3.0">
1091                                         <synopsis>Timeout for qualify</synopsis>
1092                                         <description><para>
1093                                                 If the contact doesn't repond to the OPTIONS request before the timeout,
1094                                                 the contact is marked unavailable.
1095                                                 If <literal>0</literal> no timeout. Time in fractional seconds.
1096                                         </para></description>
1097                                 </configOption>
1098                                 <configOption name="outbound_proxy">
1099                                         <synopsis>Outbound proxy used when sending OPTIONS request</synopsis>
1100                                         <description><para>
1101                                                 If set the provided URI will be used as the outbound proxy when an
1102                                                 OPTIONS request is sent to a contact for qualify purposes.
1103                                         </para></description>
1104                                 </configOption>
1105                                 <configOption name="path">
1106                                         <synopsis>Stored Path vector for use in Route headers on outgoing requests.</synopsis>
1107                                 </configOption>
1108                                 <configOption name="user_agent">
1109                                         <synopsis>User-Agent header from registration.</synopsis>
1110                                         <description><para>
1111                                                 The User-Agent is automatically stored based on data present in incoming SIP
1112                                                 REGISTER requests and is not intended to be configured manually.
1113                                         </para></description>
1114                                 </configOption>
1115                                 <configOption name="reg_server">
1116                                         <synopsis>Asterisk Server name</synopsis>
1117                                         <description><para>
1118                                                 Asterisk Server name on which SIP endpoint registered.
1119                                         </para></description>
1120                                 </configOption>
1121                         </configObject>
1122                         <configObject name="aor">
1123                                 <synopsis>The configuration for a location of an endpoint</synopsis>
1124                                 <description><para>
1125                                         An AoR is what allows Asterisk to contact an endpoint via res_pjsip. If no
1126                                         AoRs are specified, an endpoint will not be reachable by Asterisk.
1127                                         Beyond that, an AoR has other uses within Asterisk, such as inbound
1128                                         registration.
1129                                         </para><para>
1130                                         An <literal>AoR</literal> is a way to allow dialing a group
1131                                         of <literal>Contacts</literal> that all use the same
1132                                         <literal>endpoint</literal> for calls.
1133                                         </para><para>
1134                                         This can be used as another way of grouping a list of contacts to dial
1135                                         rather than specifing them each directly when dialing via the dialplan.
1136                                         This must be used in conjuction with the <literal>PJSIP_DIAL_CONTACTS</literal>.
1137                                         </para><para>
1138                                         Registrations: For Asterisk to match an inbound registration to an endpoint,
1139                                         the AoR object name must match the user portion of the SIP URI in the "To:"
1140                                         header of the inbound SIP registration. That will usually be equivalent
1141                                         to the "user name" set in your hard or soft phones configuration.
1142                                 </para></description>
1143                                 <configOption name="contact">
1144                                         <synopsis>Permanent contacts assigned to AoR</synopsis>
1145                                         <description><para>
1146                                                 Contacts specified will be called whenever referenced
1147                                                 by <literal>chan_pjsip</literal>.
1148                                                 </para><para>
1149                                                 Use a separate "contact=" entry for each contact required. Contacts
1150                                                 are specified using a SIP URI.
1151                                         </para></description>
1152                                 </configOption>
1153                                 <configOption name="default_expiration" default="3600">
1154                                         <synopsis>Default expiration time in seconds for contacts that are dynamically bound to an AoR.</synopsis>
1155                                 </configOption>
1156                                 <configOption name="mailboxes">
1157                                         <synopsis>Allow subscriptions for the specified mailbox(es)</synopsis>
1158                                         <description><para>This option applies when an external entity subscribes to an AoR
1159                                                 for Message Waiting Indications. The mailboxes specified will be subscribed to.
1160                                                 More than one mailbox can be specified with a comma-delimited string.
1161                                                 app_voicemail mailboxes must be specified as mailbox@context;
1162                                                 for example: mailboxes=6001@default. For mailboxes provided by external sources,
1163                                                 such as through the res_external_mwi module, you must specify strings supported by
1164                                                 the external system.
1165                                         </para><para>
1166                                                 For endpoints that cannot SUBSCRIBE for MWI, you can set the <literal>mailboxes</literal> option in your
1167                                                 endpoint configuration section to enable unsolicited MWI NOTIFYs to the endpoint.
1168                                         </para></description>
1169                                 </configOption>
1170                                 <configOption name="voicemail_extension">
1171                                         <synopsis>The voicemail extension to send in the NOTIFY Message-Account header</synopsis>
1172                                 </configOption>
1173                                 <configOption name="maximum_expiration" default="7200">
1174                                         <synopsis>Maximum time to keep an AoR</synopsis>
1175                                         <description><para>
1176                                                 Maximium time to keep a peer with explicit expiration. Time in seconds.
1177                                         </para></description>
1178                                 </configOption>
1179                                 <configOption name="max_contacts" default="0">
1180                                         <synopsis>Maximum number of contacts that can bind to an AoR</synopsis>
1181                                         <description><para>
1182                                                 Maximum number of contacts that can associate with this AoR. This value does
1183                                                 not affect the number of contacts that can be added with the "contact" option.
1184                                                 It only limits contacts added through external interaction, such as
1185                                                 registration.
1186                                                 </para>
1187                                                 <note><para>This should be set to <literal>1</literal> and
1188                                                 <replaceable>remove_existing</replaceable> set to <literal>yes</literal> if you
1189                                                 wish to stick with the older <literal>chan_sip</literal> behaviour.
1190                                                 </para></note>
1191                                         </description>
1192                                 </configOption>
1193                                 <configOption name="minimum_expiration" default="60">
1194                                         <synopsis>Minimum keep alive time for an AoR</synopsis>
1195                                         <description><para>
1196                                                 Minimum time to keep a peer with an explict expiration. Time in seconds.
1197                                         </para></description>
1198                                 </configOption>
1199                                 <configOption name="remove_existing" default="no">
1200                                         <synopsis>Determines whether new contacts replace existing ones.</synopsis>
1201                                         <description><para>
1202                                                 On receiving a new registration to the AoR should it remove
1203                                                 the existing contact that was registered against it?
1204                                                 </para>
1205                                                 <note><para>This should be set to <literal>yes</literal> and
1206                                                 <replaceable>max_contacts</replaceable> set to <literal>1</literal> if you
1207                                                 wish to stick with the older <literal>chan_sip</literal> behaviour.
1208                                                 </para></note>
1209                                         </description>
1210                                 </configOption>
1211                                 <configOption name="type">
1212                                         <synopsis>Must be of type 'aor'.</synopsis>
1213                                 </configOption>
1214                                 <configOption name="qualify_frequency" default="0">
1215                                         <synopsis>Interval at which to qualify an AoR</synopsis>
1216                                         <description><para>
1217                                                 Interval between attempts to qualify the AoR for reachability.
1218                                                 If <literal>0</literal> never qualify. Time in seconds.
1219                                         </para></description>
1220                                 </configOption>
1221                                 <configOption name="qualify_timeout" default="3.0">
1222                                         <synopsis>Timeout for qualify</synopsis>
1223                                         <description><para>
1224                                                 If the contact doesn't repond to the OPTIONS request before the timeout,
1225                                                 the contact is marked unavailable.
1226                                                 If <literal>0</literal> no timeout. Time in fractional seconds.
1227                                         </para></description>
1228                                 </configOption>
1229                                 <configOption name="authenticate_qualify" default="no">
1230                                         <synopsis>Authenticates a qualify request if needed</synopsis>
1231                                         <description><para>
1232                                                 If true and a qualify request receives a challenge or authenticate response
1233                                                 authentication is attempted before declaring the contact available.
1234                                         </para></description>
1235                                 </configOption>
1236                                 <configOption name="outbound_proxy">
1237                                         <synopsis>Outbound proxy used when sending OPTIONS request</synopsis>
1238                                         <description><para>
1239                                                 If set the provided URI will be used as the outbound proxy when an
1240                                                 OPTIONS request is sent to a contact for qualify purposes.
1241                                         </para></description>
1242                                 </configOption>
1243                                 <configOption name="support_path">
1244                                         <synopsis>Enables Path support for REGISTER requests and Route support for other requests.</synopsis>
1245                                         <description><para>
1246                                                 When this option is enabled, the Path headers in register requests will be saved
1247                                                 and its contents will be used in Route headers for outbound out-of-dialog requests
1248                                                 and in Path headers for outbound 200 responses. Path support will also be indicated
1249                                                 in the Supported header.
1250                                         </para></description>
1251                                 </configOption>
1252                         </configObject>
1253                         <configObject name="system">
1254                                 <synopsis>Options that apply to the SIP stack as well as other system-wide settings</synopsis>
1255                                 <description><para>
1256                                         The settings in this section are global. In addition to being global, the values will
1257                                         not be re-evaluated when a reload is performed. This is because the values must be set
1258                                         before the SIP stack is initialized. The only way to reset these values is to either
1259                                         restart Asterisk, or unload res_pjsip.so and then load it again.
1260                                 </para></description>
1261                                 <configOption name="timer_t1" default="500">
1262                                         <synopsis>Set transaction timer T1 value (milliseconds).</synopsis>
1263                                         <description><para>
1264                                                 Timer T1 is the base for determining how long to wait before retransmitting
1265                                                 requests that receive no response when using an unreliable transport (e.g. UDP).
1266                                                 For more information on this timer, see RFC 3261, Section 17.1.1.1.
1267                                         </para></description>
1268                                 </configOption>
1269                                 <configOption name="timer_b" default="32000">
1270                                         <synopsis>Set transaction timer B value (milliseconds).</synopsis>
1271                                         <description><para>
1272                                                 Timer B determines the maximum amount of time to wait after sending an INVITE
1273                                                 request before terminating the transaction. It is recommended that this be set
1274                                                 to 64 * Timer T1, but it may be set higher if desired. For more information on
1275                                                 this timer, see RFC 3261, Section 17.1.1.1.
1276                                         </para></description>
1277                                 </configOption>
1278                                 <configOption name="compact_headers" default="no">
1279                                         <synopsis>Use the short forms of common SIP header names.</synopsis>
1280                                 </configOption>
1281                                 <configOption name="threadpool_initial_size" default="0">
1282                                         <synopsis>Initial number of threads in the res_pjsip threadpool.</synopsis>
1283                                 </configOption>
1284                                 <configOption name="threadpool_auto_increment" default="5">
1285                                         <synopsis>The amount by which the number of threads is incremented when necessary.</synopsis>
1286                                 </configOption>
1287                                 <configOption name="threadpool_idle_timeout" default="60">
1288                                         <synopsis>Number of seconds before an idle thread should be disposed of.</synopsis>
1289                                 </configOption>
1290                                 <configOption name="threadpool_max_size" default="0">
1291                                         <synopsis>Maximum number of threads in the res_pjsip threadpool.
1292                                         A value of 0 indicates no maximum.</synopsis>
1293                                 </configOption>
1294                                 <configOption name="disable_tcp_switch" default="yes">
1295                                         <synopsis>Disable automatic switching from UDP to TCP transports.</synopsis>
1296                                         <description><para>
1297                                                 Disable automatic switching from UDP to TCP transports if outgoing
1298                                                 request is too large.  See RFC 3261 section 18.1.1.
1299                                         </para></description>
1300                                 </configOption>
1301                                 <configOption name="type">
1302                                         <synopsis>Must be of type 'system'.</synopsis>
1303                                 </configOption>
1304                         </configObject>
1305                         <configObject name="global">
1306                                 <synopsis>Options that apply globally to all SIP communications</synopsis>
1307                                 <description><para>
1308                                         The settings in this section are global. Unlike options in the <literal>system</literal>
1309                                         section, these options can be refreshed by performing a reload.
1310                                 </para></description>
1311                                 <configOption name="max_forwards" default="70">
1312                                         <synopsis>Value used in Max-Forwards header for SIP requests.</synopsis>
1313                                 </configOption>
1314                                 <configOption name="keep_alive_interval" default="0">
1315                                         <synopsis>The interval (in seconds) to send keepalives to active connection-oriented transports.</synopsis>
1316                                 </configOption>
1317                                 <configOption name="contact_expiration_check_interval" default="30">
1318                                         <synopsis>The interval (in seconds) to check for expired contacts.</synopsis>
1319                                 </configOption>
1320                                 <configOption name="disable_multi_domain" default="no">
1321                                         <synopsis>Disable Multi Domain support</synopsis>
1322                                         <description><para>
1323                                                 If disabled it can improve realtime performace by reducing number of database requsts.
1324                                         </para></description>
1325                                 </configOption>
1326                                 <configOption name="max_initial_qualify_time" default="0">
1327                                         <synopsis>The maximum amount of time from startup that qualifies should be attempted on all contacts.
1328                                         If greater than the qualify_frequency for an aor, qualify_frequency will be used instead.</synopsis>
1329                                 </configOption>
1330                                 <configOption name="unidentified_request_period" default="5">
1331                                         <synopsis>The number of seconds over which to accumulate unidentified requests.</synopsis>
1332                                         <description><para>
1333                                         If <literal>unidentified_request_count</literal> unidentified requests are received
1334                                         during <literal>unidentified_request_period</literal>, a security event will be generated.
1335                                         </para></description>
1336                                 </configOption>
1337                                 <configOption name="unidentified_request_count" default="5">
1338                                         <synopsis>The number of unidentified requests from a single IP to allow.</synopsis>
1339                                         <description><para>
1340                                         If <literal>unidentified_request_count</literal> unidentified requests are received
1341                                         during <literal>unidentified_request_period</literal>, a security event will be generated.
1342                                         </para></description>
1343                                 </configOption>
1344                                 <configOption name="unidentified_request_prune_interval" default="30">
1345                                         <synopsis>The interval at which unidentified requests are older than
1346                                         twice the unidentified_request_period are pruned.</synopsis>
1347                                 </configOption>
1348                                 <configOption name="type">
1349                                         <synopsis>Must be of type 'global'.</synopsis>
1350                                 </configOption>
1351                                 <configOption name="user_agent" default="Asterisk &lt;Asterisk Version&gt;">
1352                                         <synopsis>Value used in User-Agent header for SIP requests and Server header for SIP responses.</synopsis>
1353                                 </configOption>
1354                                 <configOption name="regcontext" default="">
1355                                         <synopsis>When set, Asterisk will dynamically create and destroy a NoOp priority 1 extension for a given
1356                                         peer who registers or unregisters with us.</synopsis>
1357                                 </configOption>
1358                                 <configOption name="default_outbound_endpoint" default="default_outbound_endpoint">
1359                                         <synopsis>Endpoint to use when sending an outbound request to a URI without a specified endpoint.</synopsis>
1360                                 </configOption>
1361                                 <configOption name="default_voicemail_extension">
1362                                         <synopsis>The voicemail extension to send in the NOTIFY Message-Account header if not specified on endpoint or aor</synopsis>
1363                                 </configOption>
1364                                 <configOption name="debug" default="no">
1365                                         <synopsis>Enable/Disable SIP debug logging.  Valid options include yes|no or
1366                                         a host address</synopsis>
1367                                 </configOption>
1368                                 <configOption name="endpoint_identifier_order" default="ip,username,anonymous">
1369                                         <synopsis>The order by which endpoint identifiers are processed and checked.
1370                                         Identifier names are usually derived from and can be found in the endpoint
1371                                         identifier module itself (res_pjsip_endpoint_identifier_*).
1372                                         You can use the CLI command "pjsip show identifiers" to see the
1373                                         identifiers currently available.</synopsis>
1374                     <description>
1375                                                 <note><para>
1376                                                 One of the identifiers is "auth_username" which matches on the username in
1377                                                 an Authentication header.  This method has some security considerations because an
1378                                                 Authentication header is not present on the first message of a dialog when
1379                                                 digest authentication is used.  The client can't generate it until the server
1380                                                 sends the challenge in a 401 response.  Since Asterisk normally sends a security
1381                                                 event when an incoming request can't be matched to an endpoint, using auth_username
1382                                                 requires that the security event be deferred until a request is received with
1383                                                 the Authentication header and only generated if the username doesn't result in a
1384                                                 match.  This may result in a delay before an attack is recognized.  You can control
1385                                                 how many unmatched requests are received from a single ip address before a security
1386                                                 event is generated using the unidentified_request parameters.
1387                                                 </para></note>
1388                     </description>
1389                                 </configOption>
1390                                 <configOption name="default_from_user" default="asterisk">
1391                                         <synopsis>When Asterisk generates an outgoing SIP request, the From header username will be
1392                                         set to this value if there is no better option (such as CallerID) to be
1393                                         used.</synopsis>
1394                                 </configOption>
1395                                 <configOption name="default_realm" default="asterisk">
1396                                         <synopsis>When Asterisk generates an challenge, the digest will be
1397                                         set to this value if there is no better option (such as auth/realm) to be
1398                                         used.</synopsis>
1399                                 </configOption>
1400                         </configObject>
1401                 </configFile>
1402         </configInfo>
1403         <manager name="PJSIPQualify" language="en_US">
1404                 <synopsis>
1405                         Qualify a chan_pjsip endpoint.
1406                 </synopsis>
1407                 <syntax>
1408                         <xi:include xpointer="xpointer(/docs/manager[@name='Login']/syntax/parameter[@name='ActionID'])" />
1409                         <parameter name="Endpoint" required="true">
1410                                 <para>The endpoint you want to qualify.</para>
1411                         </parameter>
1412                 </syntax>
1413                 <description>
1414                         <para>Qualify a chan_pjsip endpoint.</para>
1415                 </description>
1416         </manager>
1417         <managerEvent language="en_US" name="IdentifyDetail">
1418                 <managerEventInstance class="EVENT_FLAG_COMMAND">
1419                         <synopsis>Provide details about an identify section.</synopsis>
1420                         <syntax>
1421                                 <parameter name="ObjectType">
1422                                         <para>The object's type. This will always be 'identify'.</para>
1423                                 </parameter>
1424                                 <parameter name="ObjectName">
1425                                         <para>The name of this object.</para>
1426                                 </parameter>
1427                                 <parameter name="Endpoint">
1428                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip_endpoint_identifier_ip']/configFile[@name='pjsip.conf']/configObject[@name='identify']/configOption[@name='endpoint']/synopsis/node())"/></para>
1429                                 </parameter>
1430                                 <parameter name="Match">
1431                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip_endpoint_identifier_ip']/configFile[@name='pjsip.conf']/configObject[@name='identify']/configOption[@name='match']/synopsis/node())"/></para>
1432                                 </parameter>
1433                                 <parameter name="EndpointName">
1434                                         <para>The name of the endpoint associated with this information.</para>
1435                                 </parameter>
1436                         </syntax>
1437                 </managerEventInstance>
1438         </managerEvent>
1439         <managerEvent language="en_US" name="AorDetail">
1440                 <managerEventInstance class="EVENT_FLAG_COMMAND">
1441                         <synopsis>Provide details about an Address of Record (AoR) section.</synopsis>
1442                         <syntax>
1443                                 <parameter name="ObjectType">
1444                                         <para>The object's type. This will always be 'aor'.</para>
1445                                 </parameter>
1446                                 <parameter name="ObjectName">
1447                                         <para>The name of this object.</para>
1448                                 </parameter>
1449                                 <parameter name="MinimumExpiration">
1450                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='aor']/configOption[@name='minimum_expiration']/synopsis/node())"/></para>
1451                                 </parameter>
1452                                 <parameter name="MaximumExpiration">
1453                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='aor']/configOption[@name='maximum_expiration']/synopsis/node())"/></para>
1454                                 </parameter>
1455                                 <parameter name="DefaultExpiration">
1456                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='aor']/configOption[@name='default_expiration']/synopsis/node())"/></para>
1457                                 </parameter>
1458                                 <parameter name="QualifyFrequency">
1459                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='aor']/configOption[@name='qualify_frequency']/synopsis/node())"/></para>
1460                                 </parameter>
1461                                 <parameter name="AuthenticateQualify">
1462                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='aor']/configOption[@name='authenticate_qualify']/synopsis/node())"/></para>
1463                                 </parameter>
1464                                 <parameter name="MaxContacts">
1465                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='aor']/configOption[@name='max_contacts']/synopsis/node())"/></para>
1466                                 </parameter>
1467                                 <parameter name="RemoveExisting">
1468                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='aor']/configOption[@name='remove_existing']/synopsis/node())"/></para>
1469                                 </parameter>
1470                                 <parameter name="Mailboxes">
1471                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='aor']/configOption[@name='mailboxes']/synopsis/node())"/></para>
1472                                 </parameter>
1473                                 <parameter name="OutboundProxy">
1474                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='aor']/configOption[@name='outbound_proxy']/synopsis/node())"/></para>
1475                                 </parameter>
1476                                 <parameter name="SupportPath">
1477                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='aor']/configOption[@name='support_path']/synopsis/node())"/></para>
1478                                 </parameter>
1479                                 <parameter name="TotalContacts">
1480                                         <para>The total number of contacts associated with this AoR.</para>
1481                                 </parameter>
1482                                 <parameter name="ContactsRegistered">
1483                                         <para>The number of non-permanent contacts associated with this AoR.</para>
1484                                 </parameter>
1485                                 <parameter name="EndpointName">
1486                                         <para>The name of the endpoint associated with this information.</para>
1487                                 </parameter>
1488                         </syntax>
1489                 </managerEventInstance>
1490         </managerEvent>
1491         <managerEvent language="en_US" name="AuthDetail">
1492                 <managerEventInstance class="EVENT_FLAG_COMMAND">
1493                         <synopsis>Provide details about an authentication section.</synopsis>
1494                         <syntax>
1495                                 <parameter name="ObjectType">
1496                                         <para>The object's type. This will always be 'auth'.</para>
1497                                 </parameter>
1498                                 <parameter name="ObjectName">
1499                                         <para>The name of this object.</para>
1500                                 </parameter>
1501                                 <parameter name="Username">
1502                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='auth']/configOption[@name='username']/synopsis/node())"/></para>
1503                                 </parameter>
1504                                 <parameter name="Password">
1505                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='auth']/configOption[@name='username']/synopsis/node())"/></para>
1506                                 </parameter>
1507                                 <parameter name="Md5Cred">
1508                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='auth']/configOption[@name='md5_cred']/synopsis/node())"/></para>
1509                                 </parameter>
1510                                 <parameter name="Realm">
1511                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='auth']/configOption[@name='realm']/synopsis/node())"/></para>
1512                                 </parameter>
1513                                 <parameter name="NonceLifetime">
1514                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='auth']/configOption[@name='nonce_lifetime']/synopsis/node())"/></para>
1515                                 </parameter>
1516                                 <parameter name="AuthType">
1517                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='auth']/configOption[@name='auth_type']/synopsis/node())"/></para>
1518                                 </parameter>
1519                                 <parameter name="EndpointName">
1520                                         <para>The name of the endpoint associated with this information.</para>
1521                                 </parameter>
1522                         </syntax>
1523                 </managerEventInstance>
1524         </managerEvent>
1525         <managerEvent language="en_US" name="TransportDetail">
1526                 <managerEventInstance class="EVENT_FLAG_COMMAND">
1527                         <synopsis>Provide details about an authentication section.</synopsis>
1528                         <syntax>
1529                                 <parameter name="ObjectType">
1530                                         <para>The object's type. This will always be 'transport'.</para>
1531                                 </parameter>
1532                                 <parameter name="ObjectName">
1533                                         <para>The name of this object.</para>
1534                                 </parameter>
1535                                 <parameter name="Protocol">
1536                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='protocol']/synopsis/node())"/></para>
1537                                 </parameter>
1538                                 <parameter name="Bind">
1539                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='bind']/synopsis/node())"/></para>
1540                                 </parameter>
1541                                 <parameter name="AsycOperations">
1542                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='async_operations']/synopsis/node())"/></para>
1543                                 </parameter>
1544                                 <parameter name="CaListFile">
1545                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='ca_list_file']/synopsis/node())"/></para>
1546                                 </parameter>
1547                                 <parameter name="CaListPath">
1548                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='ca_list_path']/synopsis/node())"/></para>
1549                                 </parameter>
1550                                 <parameter name="CertFile">
1551                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='cert_file']/synopsis/node())"/></para>
1552                                 </parameter>
1553                                 <parameter name="PrivKeyFile">
1554                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='priv_key_file']/synopsis/node())"/></para>
1555                                 </parameter>
1556                                 <parameter name="Password">
1557                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='password']/synopsis/node())"/></para>
1558                                 </parameter>
1559                                 <parameter name="ExternalSignalingAddress">
1560                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='external_signaling_address']/synopsis/node())"/></para>
1561                                 </parameter>
1562                                 <parameter name="ExternalSignalingPort">
1563                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='external_signaling_port']/synopsis/node())"/></para>
1564                                 </parameter>
1565                                 <parameter name="ExternalMediaAddress">
1566                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='external_media_address']/synopsis/node())"/></para>
1567                                 </parameter>
1568                                 <parameter name="Domain">
1569                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='domain']/synopsis/node())"/></para>
1570                                 </parameter>
1571                                 <parameter name="VerifyServer">
1572                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='verify_server']/synopsis/node())"/></para>
1573                                 </parameter>
1574                                 <parameter name="VerifyClient">
1575                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='verify_client']/synopsis/node())"/></para>
1576                                 </parameter>
1577                                 <parameter name="RequireClientCert">
1578                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='require_client_cert']/synopsis/node())"/></para>
1579                                 </parameter>
1580                                 <parameter name="Method">
1581                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='method']/synopsis/node())"/></para>
1582                                 </parameter>
1583                                 <parameter name="Cipher">
1584                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='cipher']/synopsis/node())"/></para>
1585                                 </parameter>
1586                                 <parameter name="LocalNet">
1587                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='local_net']/synopsis/node())"/></para>
1588                                 </parameter>
1589                                 <parameter name="Tos">
1590                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='tos']/synopsis/node())"/></para>
1591                                 </parameter>
1592                                 <parameter name="Cos">
1593                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='cos']/synopsis/node())"/></para>
1594                                 </parameter>
1595                                 <parameter name="WebsocketWriteTimeout">
1596                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='transport']/configOption[@name='websocket_write_timeout']/synopsis/node())"/></para>
1597                                 </parameter>
1598                                 <parameter name="EndpointName">
1599                                         <para>The name of the endpoint associated with this information.</para>
1600                                 </parameter>
1601                         </syntax>
1602                 </managerEventInstance>
1603         </managerEvent>
1604         <managerEvent language="en_US" name="EndpointDetail">
1605                 <managerEventInstance class="EVENT_FLAG_COMMAND">
1606                         <synopsis>Provide details about an endpoint section.</synopsis>
1607                         <syntax>
1608                                 <parameter name="ObjectType">
1609                                         <para>The object's type. This will always be 'endpoint'.</para>
1610                                 </parameter>
1611                                 <parameter name="ObjectName">
1612                                         <para>The name of this object.</para>
1613                                 </parameter>
1614                                 <parameter name="Context">
1615                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='context']/synopsis/node())"/></para>
1616                                 </parameter>
1617                                 <parameter name="Disallow">
1618                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='disallow']/synopsis/node())"/></para>
1619                                 </parameter>
1620                                 <parameter name="Allow">
1621                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='allow']/synopsis/node())"/></para>
1622                                 </parameter>
1623                                 <parameter name="DtmfMode">
1624                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='dtmf_mode']/synopsis/node())"/></para>
1625                                 </parameter>
1626                                 <parameter name="RtpIpv6">
1627                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='rtp_ipv6']/synopsis/node())"/></para>
1628                                 </parameter>
1629                                 <parameter name="RtpSymmetric">
1630                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='rtp_symmetric']/synopsis/node())"/></para>
1631                                 </parameter>
1632                                 <parameter name="IceSupport">
1633                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='ice_support']/synopsis/node())"/></para>
1634                                 </parameter>
1635                                 <parameter name="UsePtime">
1636                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='use_ptime']/synopsis/node())"/></para>
1637                                 </parameter>
1638                                 <parameter name="ForceRport">
1639                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='force_rport']/synopsis/node())"/></para>
1640                                 </parameter>
1641                                 <parameter name="RewriteContact">
1642                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='rewrite_contact']/synopsis/node())"/></para>
1643                                 </parameter>
1644                                 <parameter name="Transport">
1645                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='transport']/synopsis/node())"/></para>
1646                                 </parameter>
1647                                 <parameter name="OutboundProxy">
1648                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='outbound_proxy']/synopsis/node())"/></para>
1649                                 </parameter>
1650                                 <parameter name="MohSuggest">
1651                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='moh_suggest']/synopsis/node())"/></para>
1652                                 </parameter>
1653                                 <parameter name="100rel">
1654                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='100rel']/synopsis/node())"/></para>
1655                                 </parameter>
1656                                 <parameter name="Timers">
1657                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='timers']/synopsis/node())"/></para>
1658                                 </parameter>
1659                                 <parameter name="TimersMinSe">
1660                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='timers_min_se']/synopsis/node())"/></para>
1661                                 </parameter>
1662                                 <parameter name="TimersSessExpires">
1663                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='timers_sess_expires']/synopsis/node())"/></para>
1664                                 </parameter>
1665                                 <parameter name="Auth">
1666                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='auth']/synopsis/node())"/></para>
1667                                 </parameter>
1668                                 <parameter name="OutboundAuth">
1669                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='outbound_auth']/synopsis/node())"/></para>
1670                                 </parameter>
1671                                 <parameter name="Aors">
1672                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='aors']/synopsis/node())"/></para>
1673                                 </parameter>
1674                                 <parameter name="MediaAddress">
1675                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='media_address']/synopsis/node())"/></para>
1676                                 </parameter>
1677                                 <parameter name="IdentifyBy">
1678                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='identify_by']/synopsis/node())"/></para>
1679                                 </parameter>
1680                                 <parameter name="DirectMedia">
1681                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='direct_media']/synopsis/node())"/></para>
1682                                 </parameter>
1683                                 <parameter name="DirectMediaMethod">
1684                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='direct_media_method']/synopsis/node())"/></para>
1685                                 </parameter>
1686                                 <parameter name="ConnectedLineMethod">
1687                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='connected_line_method']/synopsis/node())"/></para>
1688                                 </parameter>
1689                                 <parameter name="DirectMediaGlareMitigation">
1690                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='direct_media_glare_mitigation']/synopsis/node())"/></para>
1691                                 </parameter>
1692                                 <parameter name="DisableDirectMediaOnNat">
1693                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='disable_direct_media_on_nat']/synopsis/node())"/></para>
1694                                 </parameter>
1695                                 <parameter name="Callerid">
1696                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='callerid']/synopsis/node())"/></para>
1697                                 </parameter>
1698                                 <parameter name="CalleridPrivacy">
1699                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='callerid_privacy']/synopsis/node())"/></para>
1700                                 </parameter>
1701                                 <parameter name="CalleridTag">
1702                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='callerid_tag']/synopsis/node())"/></para>
1703                                 </parameter>
1704                                 <parameter name="TrustIdInbound">
1705                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='trust_id_inbound']/synopsis/node())"/></para>
1706                                 </parameter>
1707                                 <parameter name="TrustIdOutbound">
1708                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='trust_id_outbound']/synopsis/node())"/></para>
1709                                 </parameter>
1710                                 <parameter name="SendPai">
1711                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='send_pai']/synopsis/node())"/></para>
1712                                 </parameter>
1713                                 <parameter name="SendRpid">
1714                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='send_rpid']/synopsis/node())"/></para>
1715                                 </parameter>
1716                                 <parameter name="SendDiversion">
1717                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='send_diversion']/synopsis/node())"/></para>
1718                                 </parameter>
1719                                 <parameter name="Mailboxes">
1720                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='mailboxes']/synopsis/node())"/></para>
1721                                 </parameter>
1722                                 <parameter name="AggregateMwi">
1723                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='aggregate_mwi']/synopsis/node())"/></para>
1724                                 </parameter>
1725                                 <parameter name="MediaEncryption">
1726                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='media_encryption']/synopsis/node())"/></para>
1727                                 </parameter>
1728                                 <parameter name="MediaEncryptionOptimistic">
1729                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='media_encryption_optimistic']/synopsis/node())"/></para>
1730                                 </parameter>
1731                                 <parameter name="UseAvpf">
1732                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='use_avpf']/synopsis/node())"/></para>
1733                                 </parameter>
1734                                 <parameter name="ForceAvp">
1735                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='force_avp']/synopsis/node())"/></para>
1736                                 </parameter>
1737                                 <parameter name="MediaUseReceivedTransport">
1738                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='media_use_received_transport']/synopsis/node())"/></para>
1739                                 </parameter>
1740                                 <parameter name="OneTouchRecording">
1741                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='one_touch_recording']/synopsis/node())"/></para>
1742                                 </parameter>
1743                                 <parameter name="InbandProgress">
1744                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='inband_progress']/synopsis/node())"/></para>
1745                                 </parameter>
1746                                 <parameter name="CallGroup">
1747                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='call_group']/synopsis/node())"/></para>
1748                                 </parameter>
1749                                 <parameter name="PickupGroup">
1750                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='pickup_group']/synopsis/node())"/></para>
1751                                 </parameter>
1752                                 <parameter name="NamedCallGroup">
1753                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='named_call_group']/synopsis/node())"/></para>
1754                                 </parameter>
1755                                 <parameter name="NamedPickupGroup">
1756                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='named_pickup_group']/synopsis/node())"/></para>
1757                                 </parameter>
1758                                 <parameter name="DeviceStateBusyAt">
1759                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='device_state_busy_at']/synopsis/node())"/></para>
1760                                 </parameter>
1761                                 <parameter name="T38Udptl">
1762                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='t38_udptl']/synopsis/node())"/></para>
1763                                 </parameter>
1764                                 <parameter name="T38UdptlEc">
1765                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='t38_udptl_ec']/synopsis/node())"/></para>
1766                                 </parameter>
1767                                 <parameter name="T38UdptlMaxdatagram">
1768                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='t38_udptl_maxdatagram']/synopsis/node())"/></para>
1769                                 </parameter>
1770                                 <parameter name="FaxDetect">
1771                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='fax_detect']/synopsis/node())"/></para>
1772                                 </parameter>
1773                                 <parameter name="T38UdptlNat">
1774                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='t38_udptl_nat']/synopsis/node())"/></para>
1775                                 </parameter>
1776                                 <parameter name="T38UdptlIpv6">
1777                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='t38_udptl_ipv6']/synopsis/node())"/></para>
1778                                 </parameter>
1779                                 <parameter name="ToneZone">
1780                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='tone_zone']/synopsis/node())"/></para>
1781                                 </parameter>
1782                                 <parameter name="Language">
1783                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='language']/synopsis/node())"/></para>
1784                                 </parameter>
1785                                 <parameter name="RecordOnFeature">
1786                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='record_on_feature']/synopsis/node())"/></para>
1787                                 </parameter>
1788                                 <parameter name="RecordOffFeature">
1789                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='record_off_feature']/synopsis/node())"/></para>
1790                                 </parameter>
1791                                 <parameter name="AllowTransfer">
1792                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='allow_transfer']/synopsis/node())"/></para>
1793                                 </parameter>
1794                                 <parameter name="UserEqPhone">
1795                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='user_eq_phone']/synopsis/node())"/></para>
1796                                 </parameter>
1797                                 <parameter name="MohPassthrough">
1798                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='moh_passthrough']/synopsis/node())"/></para>
1799                                 </parameter>
1800                                 <parameter name="SdpOwner">
1801                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='sdp_owner']/synopsis/node())"/></para>
1802                                 </parameter>
1803                                 <parameter name="SdpSession">
1804                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='sdp_session']/synopsis/node())"/></para>
1805                                 </parameter>
1806                                 <parameter name="TosAudio">
1807                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='tos_audio']/synopsis/node())"/></para>
1808                                 </parameter>
1809                                 <parameter name="TosVideo">
1810                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='tos_video']/synopsis/node())"/></para>
1811                                 </parameter>
1812                                 <parameter name="CosAudio">
1813                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='cos_audio']/synopsis/node())"/></para>
1814                                 </parameter>
1815                                 <parameter name="CosVideo">
1816                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='cos_video']/synopsis/node())"/></para>
1817                                 </parameter>
1818                                 <parameter name="AllowSubscribe">
1819                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='allow_subscribe']/synopsis/node())"/></para>
1820                                 </parameter>
1821                                 <parameter name="SubMinExpiry">
1822                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='sub_min_expiry']/synopsis/node())"/></para>
1823                                 </parameter>
1824                                 <parameter name="FromUser">
1825                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='from_user']/synopsis/node())"/></para>
1826                                 </parameter>
1827                                 <parameter name="FromDomain">
1828                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='from_domain']/synopsis/node())"/></para>
1829                                 </parameter>
1830                                 <parameter name="MwiFromUser">
1831                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='mwi_from_user']/synopsis/node())"/></para>
1832                                 </parameter>
1833                                 <parameter name="RtpEngine">
1834                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='rtp_engine']/synopsis/node())"/></para>
1835                                 </parameter>
1836                                 <parameter name="DtlsVerify">
1837                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='dtls_verify']/synopsis/node())"/></para>
1838                                 </parameter>
1839                                 <parameter name="DtlsRekey">
1840                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='dtls_rekey']/synopsis/node())"/></para>
1841                                 </parameter>
1842                                 <parameter name="DtlsCertFile">
1843                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='dtls_cert_file']/synopsis/node())"/></para>
1844                                 </parameter>
1845                                 <parameter name="DtlsPrivateKey">
1846                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='dtls_private_key']/synopsis/node())"/></para>
1847                                 </parameter>
1848                                 <parameter name="DtlsCipher">
1849                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='dtls_cipher']/synopsis/node())"/></para>
1850                                 </parameter>
1851                                 <parameter name="DtlsCaFile">
1852                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='dtls_ca_file']/synopsis/node())"/></para>
1853                                 </parameter>
1854                                 <parameter name="DtlsCaPath">
1855                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='dtls_ca_path']/synopsis/node())"/></para>
1856                                 </parameter>
1857                                 <parameter name="DtlsSetup">
1858                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='dtls_setup']/synopsis/node())"/></para>
1859                                 </parameter>
1860                                 <parameter name="SrtpTag32">
1861                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='srtp_tag_32']/synopsis/node())"/></para>
1862                                 </parameter>
1863                                 <parameter name="RedirectMethod">
1864                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='redirect_method']/synopsis/node())"/></para>
1865                                 </parameter>
1866                                 <parameter name="SetVar">
1867                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='set_var']/synopsis/node())"/></para>
1868                                 </parameter>
1869                                 <parameter name="MessageContext">
1870                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='message_context']/synopsis/node())"/></para>
1871                                 </parameter>
1872                                 <parameter name="Accountcode">
1873                                         <para><xi:include xpointer="xpointer(/docs/configInfo[@name='res_pjsip']/configFile[@name='pjsip.conf']/configObject[@name='endpoint']/configOption[@name='accountcode']/synopsis/node())"/></para>
1874                                 </parameter>
1875                                 <parameter name="DeviceState">
1876                                         <para>The aggregate device state for this endpoint.</para>
1877                                 </parameter>
1878                                 <parameter name="ActiveChannels">
1879                                         <para>The number of active channels associated with this endpoint.</para>
1880                                 </parameter>
1881                         </syntax>
1882                 </managerEventInstance>
1883         </managerEvent>
1884         <managerEvent language="en_US" name="ContactStatusDetail">
1885                 <managerEventInstance class="EVENT_FLAG_COMMAND">
1886                         <synopsis>Provide details about a contact's status.</synopsis>
1887                         <syntax>
1888                                 <parameter name="AOR">
1889                                         <para>The AoR that owns this contact.</para>
1890                                 </parameter>
1891                                 <parameter name="URI">
1892                                         <para>This contact's URI.</para>
1893                                 </parameter>
1894                                 <parameter name="Status">
1895                                         <para>This contact's status.</para>
1896                                         <enumlist>
1897                                                 <enum name="Reachable"/>
1898                                                 <enum name="Unreachable"/>
1899                                         </enumlist>
1900                                 </parameter>
1901                                 <parameter name="RoundtripUsec">
1902                                         <para>The round trip time in microseconds.</para>
1903                                 </parameter>
1904                                 <parameter name="EndpointName">
1905                                         <para>The name of the endpoint associated with this information.</para>
1906                                 </parameter>
1907                                 <parameter name="UserAgent">
1908                                         <para>Content of the User-Agent header in REGISTER request</para>
1909                                 </parameter>
1910                                 <parameter name="RegExpire">
1911                                         <para>Absolute time that this contact is no longer valid after</para>
1912                                 </parameter>
1913                         </syntax>
1914                 </managerEventInstance>
1915         </managerEvent>
1916         <managerEvent language="en_US" name="EndpointList">
1917                 <managerEventInstance class="EVENT_FLAG_COMMAND">
1918                         <synopsis>Provide details about a contact's status.</synopsis>
1919                         <syntax>
1920                                 <parameter name="ObjectType">
1921                                         <para>The object's type. This will always be 'endpoint'.</para>
1922                                 </parameter>
1923                                 <parameter name="ObjectName">
1924                                         <para>The name of this object.</para>
1925                                 </parameter>
1926                                 <parameter name="Transport">
1927                                         <para>The transport configurations associated with this endpoint.</para>
1928                                 </parameter>
1929                                 <parameter name="Aor">
1930                                         <para>The aor configurations associated with this endpoint.</para>
1931                                 </parameter>
1932                                 <parameter name="Auths">
1933                                         <para>The inbound authentication configurations associated with this endpoint.</para>
1934                                 </parameter>
1935                                 <parameter name="OutboundAuths">
1936                                         <para>The outbound authentication configurations associated with this endpoint.</para>
1937                                 </parameter>
1938                                 <parameter name="DeviceState">
1939                                         <para>The aggregate device state for this endpoint.</para>
1940                                 </parameter>
1941                                 <parameter name="ActiveChannels">
1942                                         <para>The number of active channels associated with this endpoint.</para>
1943                                 </parameter>
1944                         </syntax>
1945                 </managerEventInstance>
1946         </managerEvent>
1947         <manager name="PJSIPShowEndpoints" language="en_US">
1948                 <synopsis>
1949                         Lists PJSIP endpoints.
1950                 </synopsis>
1951                 <syntax />
1952                 <description>
1953                         <para>
1954                         Provides a listing of all endpoints.  For each endpoint an <literal>EndpointList</literal> event
1955                         is raised that contains relevant attributes and status information.  Once all
1956                         endpoints have been listed an <literal>EndpointListComplete</literal> event is issued.
1957                         </para>
1958                 </description>
1959                 <responses>
1960                         <list-elements>
1961                                 <xi:include xpointer="xpointer(/docs/managerEvent[@name='EndpointList'])" />
1962                         </list-elements>
1963                         <managerEvent language="en_US" name="EndpointListComplete">
1964                                 <managerEventInstance class="EVENT_FLAG_COMMAND">
1965                                         <synopsis>Provide final information about an endpoint list.</synopsis>
1966                                         <syntax>
1967                                                 <parameter name="EventList"/>
1968                                                 <parameter name="ListItems"/>
1969                                         </syntax>
1970                                 </managerEventInstance>
1971                         </managerEvent>
1972                 </responses>
1973         </manager>
1974         <manager name="PJSIPShowEndpoint" language="en_US">
1975                 <synopsis>
1976                         Detail listing of an endpoint and its objects.
1977                 </synopsis>
1978                 <syntax>
1979                         <xi:include xpointer="xpointer(/docs/manager[@name='Login']/syntax/parameter[@name='ActionID'])" />
1980                         <parameter name="Endpoint" required="true">
1981                                 <para>The endpoint to list.</para>
1982                         </parameter>
1983                 </syntax>
1984                 <description>
1985                         <para>
1986                         Provides a detailed listing of options for a given endpoint.  Events are issued
1987                         showing the configuration and status of the endpoint and associated objects.  These
1988                         events include <literal>EndpointDetail</literal>, <literal>AorDetail</literal>,
1989                         <literal>AuthDetail</literal>, <literal>TransportDetail</literal>, and
1990                         <literal>IdentifyDetail</literal>.  Some events may be listed multiple times if multiple objects are
1991                         associated (for instance AoRs).  Once all detail events have been raised a final
1992                         <literal>EndpointDetailComplete</literal> event is issued.
1993                         </para>
1994                 </description>
1995                 <responses>
1996                         <list-elements>
1997                                 <xi:include xpointer="xpointer(/docs/managerEvent[@name='EndpointDetail'])" />
1998                                 <xi:include xpointer="xpointer(/docs/managerEvent[@name='IdentifyDetail'])" />
1999                                 <xi:include xpointer="xpointer(/docs/managerEvent[@name='ContactStatusDetail'])" />
2000                                 <xi:include xpointer="xpointer(/docs/managerEvent[@name='AuthDetail'])" />
2001                                 <xi:include xpointer="xpointer(/docs/managerEvent[@name='TransportDetail'])" />
2002                                 <xi:include xpointer="xpointer(/docs/managerEvent[@name='AorDetail'])" />
2003                         </list-elements>
2004                         <managerEvent language="en_US" name="EndpointDetailComplete">
2005                                 <managerEventInstance class="EVENT_FLAG_COMMAND">
2006                                         <synopsis>Provide final information about endpoint details.</synopsis>
2007                                         <syntax>
2008                                                 <parameter name="EventList"/>
2009                                                 <parameter name="ListItems"/>
2010                                         </syntax>
2011                                 </managerEventInstance>
2012                         </managerEvent>
2013                 </responses>
2014         </manager>
2015  ***/
2016
2017 #define MOD_DATA_CONTACT "contact"
2018
2019 /*! Number of serializers in pool if one not supplied. */
2020 #define SERIALIZER_POOL_SIZE            8
2021
2022 /*! Next serializer pool index to use. */
2023 static int serializer_pool_pos;
2024
2025 /*! Pool of serializers to use if not supplied. */
2026 static struct ast_taskprocessor *serializer_pool[SERIALIZER_POOL_SIZE];
2027
2028 static pjsip_endpoint *ast_pjsip_endpoint;
2029
2030 static struct ast_threadpool *sip_threadpool;
2031
2032 /*! Local host address for IPv4 */
2033 static pj_sockaddr host_ip_ipv4;
2034
2035 /*! Local host address for IPv4 (string form) */
2036 static char host_ip_ipv4_string[PJ_INET6_ADDRSTRLEN + 2];
2037
2038 /*! Local host address for IPv6 */
2039 static pj_sockaddr host_ip_ipv6;
2040
2041 /*! Local host&n