Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 234 Next »

SIP Resource using PJProject

This configuration documentation is for functionality provided by res_pjsip.

pjsip.conf

endpoint

Endpoint

Configuration Option Reference

Option Name

Type

Default Value

Regular Expression

Description

100rel

 

yes

 

Allow support for RFC3262 provisional ACK tags

aggregate_mwi

 

yes

 

Condense MWI notifications into a single NOTIFY.

allow

 

 

 

Media Codec(s) to allow

aors

 

 

 

AoR(s) to be used with the endpoint

auth

 

 

 

Authentication Object(s) associated with the endpoint

callerid

 

 

 

CallerID information for the endpoint

callerid_privacy

 

 

 

Default privacy level

callerid_tag

 

 

 

Internal id_tag for the endpoint

context

 

 

 

Dialplan context for inbound sessions

direct_media_glare_mitigation

 

none

 

Mitigation of direct media (re)INVITE glare

direct_media_method

 

invite

 

Direct Media method type

connected_line_method

 

invite

 

Connected line method type

direct_media

 

yes

 

Determines whether media may flow directly between endpoints.

disable_direct_media_on_nat

 

no

 

Disable direct media session refreshes when NAT obstructs the media session

disallow

 

 

 

Media Codec(s) to disallow

dtmf_mode

 

rfc4733

 

DTMF mode

media_address

 

 

 

IP address used in SDP for media handling

bind_rtp_to_media_address

 

 

 

Bind the RTP instance to the media_address

force_rport

 

yes

 

Force use of return port

ice_support

 

no

 

Enable the ICE mechanism to help traverse NAT

identify_by

 

username,location

 

Way(s) for Endpoint to be identified

redirect_method

 

 

 

How redirects received from an endpoint are handled

mailboxes

 

 

 

NOTIFY the endpoint when state changes for any of the specified mailboxes

mwi_subscribe_replaces_unsolicited

 

 

 

An MWI subscribe will replace sending unsolicited NOTIFYs

voicemail_extension

 

 

 

The voicemail extension to send in the NOTIFY Message-Account header

moh_suggest

 

default

 

Default Music On Hold class

outbound_auth

 

 

 

Authentication object used for outbound requests

outbound_proxy

 

 

 

Proxy through which to send requests, a full SIP URI must be provided

rewrite_contact

 

 

 

Allow Contact header to be rewritten with the source IP address-port

rtp_ipv6

 

no

 

Allow use of IPv6 for RTP traffic

rtp_symmetric

 

no

 

Enforce that RTP must be symmetric

send_diversion

 

yes

 

Send the Diversion header, conveying the diversion information to the called user agent

send_pai

 

no

 

Send the P-Asserted-Identity header

send_rpid

 

no

 

Send the Remote-Party-ID header

rpid_immediate

 

no

 

Immediately send connected line updates on unanswered incoming calls.

timers_min_se

 

90

 

Minimum session timers expiration period

timers

 

yes

 

Session timers for SIP packets

timers_sess_expires

 

1800

 

Maximum session timer expiration period

transport

 

 

 

Desired transport configuration

trust_id_inbound

 

no

 

Accept identification information received from this endpoint

trust_id_outbound

 

no

 

Send private identification details to the endpoint.

type

 

 

 

Must be of type 'endpoint'.

use_ptime

 

no

 

Use Endpoint's requested packetisation interval

use_avpf

 

no

 

Determines whether res_pjsip will use and enforce usage of AVPF for this endpoint.

force_avp

 

no

 

Determines whether res_pjsip will use and enforce usage of AVP, regardless of the RTP profile in use for this endpoint.

media_use_received_transport

 

no

 

Determines whether res_pjsip will use the media transport received in the offer SDP in the corresponding answer SDP.

media_encryption

 

no

 

Determines whether res_pjsip will use and enforce usage of media encryption for this endpoint.

media_encryption_optimistic

 

no

 

Determines whether encryption should be used if possible but does not terminate the session if not achieved.

g726_non_standard

 

no

 

Force g.726 to use AAL2 packing order when negotiating g.726 audio

inband_progress

 

no

 

Determines whether chan_pjsip will indicate ringing using inband progress.

call_group

 

 

 

The numeric pickup groups for a channel.

pickup_group

 

 

 

The numeric pickup groups that a channel can pickup.

named_call_group

 

 

 

The named pickup groups for a channel.

named_pickup_group

 

 

 

The named pickup groups that a channel can pickup.

device_state_busy_at

 

0

 

The number of in-use channels which will cause busy to be returned as device state

t38_udptl

 

no

 

Whether T.38 UDPTL support is enabled or not

t38_udptl_ec

 

none

 

T.38 UDPTL error correction method

t38_udptl_maxdatagram

 

0

 

T.38 UDPTL maximum datagram size

fax_detect

 

no

 

Whether CNG tone detection is enabled

fax_detect_timeout

 

 

 

How long into a call before fax_detect is disabled for the call

t38_udptl_nat

 

no

 

Whether NAT support is enabled on UDPTL sessions

t38_udptl_ipv6

 

no

 

Whether IPv6 is used for UDPTL Sessions

tone_zone

 

 

 

Set which country's indications to use for channels created for this endpoint.

language

 

 

 

Set the default language to use for channels created for this endpoint.

one_touch_recording

 

no

 

Determines whether one-touch recording is allowed for this endpoint.

record_on_feature

 

automixmon

 

The feature to enact when one-touch recording is turned on.

record_off_feature

 

automixmon

 

The feature to enact when one-touch recording is turned off.

rtp_engine

 

asterisk

 

Name of the RTP engine to use for channels created for this endpoint

allow_transfer

 

yes

 

Determines whether SIP REFER transfers are allowed for this endpoint

user_eq_phone

 

no

 

Determines whether a user=phone parameter is placed into the request URI if the user is determined to be a phone number

sdp_owner

 

-

 

String placed as the username portion of an SDP origin (o=) line.

sdp_session

 

Asterisk

 

String used for the SDP session (s=) line.

tos_audio

 

 

 

DSCP TOS bits for audio streams

tos_video

 

 

 

DSCP TOS bits for video streams

cos_audio

 

 

 

Priority for audio streams

cos_video

 

 

 

Priority for video streams

allow_subscribe

 

yes

 

Determines if endpoint is allowed to initiate subscriptions with Asterisk.

sub_min_expiry

 

60

 

The minimum allowed expiry time for subscriptions initiated by the endpoint.

from_user

 

 

 

Username to use in From header for requests to this endpoint.

mwi_from_user

 

 

 

Username to use in From header for unsolicited MWI NOTIFYs to this endpoint.

from_domain

 

 

 

Domain to user in From header for requests to this endpoint.

dtls_verify

 

 

 

Verify that the provided peer certificate is valid

dtls_rekey

 

 

 

Interval at which to renegotiate the TLS session and rekey the SRTP session

dtls_cert_file

 

 

 

Path to certificate file to present to peer

dtls_private_key

 

 

 

Path to private key for certificate file

dtls_cipher

 

 

 

Cipher to use for DTLS negotiation

dtls_ca_file

 

 

 

Path to certificate authority certificate

dtls_ca_path

 

 

 

Path to a directory containing certificate authority certificates

dtls_setup

 

 

 

Whether we are willing to accept connections, connect to the other party, or both.

dtls_fingerprint

 

 

 

Type of hash to use for the DTLS fingerprint in the SDP.

srtp_tag_32

 

 

 

Determines whether 32 byte tags should be used instead of 80 byte tags.

set_var

 

 

 

Variable set on a channel involving the endpoint.

message_context

 

 

 

Context to route incoming MESSAGE requests to.

accountcode

 

 

 

An accountcode to set automatically on any channels created for this endpoint.

rtp_keepalive

 

 

 

Number of seconds between RTP comfort noise keepalive packets.

rtp_timeout

 

0

 

Maximum number of seconds without receiving RTP (while off hold) before terminating call.

rtp_timeout_hold

 

0

 

Maximum number of seconds without receiving RTP (while on hold) before terminating call.

acl

 

 

 

List of IP ACL section names in acl.conf

deny

 

 

 

List of IP addresses to deny access from

permit

 

 

 

List of IP addresses to permit access from

contact_acl

 

 

 

List of Contact ACL section names in acl.conf

contact_deny

 

 

 

List of Contact header addresses to deny

contact_permit

 

 

 

List of Contact header addresses to permit

subscribe_context

 

 

 

Context for incoming MESSAGE requests.

contact_user

 

 

 

Force the user on the outgoing Contact header to this value.

asymmetric_rtp_codec

 

no

 

Allow the sending and receiving RTP codec to differ

Configuration Option Descriptions

100rel
  • no
  • required
  • yes

aggregate_mwi

When enabled, aggregate_mwi condenses message waiting notifications from multiple mailboxes into a single NOTIFY. If it is disabled, individual NOTIFYs are sent for each mailbox.

aors

List of comma separated AoRs that the endpoint should be associated with.

auth

This is a comma-delimited list of auth sections defined in pjsip.conf to be used to verify inbound connection attempts.

Endpoints without an authentication object configured will allow connections without vertification.

callerid

Must be in the format Name <Number>, or only <Number>.

callerid_privacy
  • allowed_not_screened
  • allowed_passed_screen
  • allowed_failed_screen
  • allowed
  • prohib_not_screened
  • prohib_passed_screen
  • prohib_failed_screen
  • prohib
  • unavailable

direct_media_glare_mitigation

This setting attempts to avoid creating INVITE glare scenarios by disabling direct media reINVITEs in one direction thereby allowing designated servers (according to this option) to initiate direct media reINVITEs without contention and significantly reducing call setup time.

A more detailed description of how this option functions can be found on the Asterisk wiki https://wiki.asterisk.org/wiki/display/AST/SIP+Direct+Media+Reinvite+Glare+Avoidance

  • none
  • outgoing
  • incoming

direct_media_method

Method for setting up Direct Media between endpoints.

  • invite
  • reinvite - Alias for the invite value.
  • update

connected_line_method

Method used when updating connected line information.

  • invite
  • reinvite - Alias for the invite value.
  • update

dtmf_mode

This setting allows to choose the DTMF mode for endpoint communication.

  • rfc4733 - DTMF is sent out of band of the main audio stream. This supercedes the older RFC-2833 used within the older chan_sip.
  • inband - DTMF is sent as part of audio stream.
  • info - DTMF is sent as SIP INFO packets.
  • auto - DTMF is sent as RFC 4733 if the other side supports it or as INBAND if not.

media_address

At the time of SDP creation, the IP address defined here will be used as the media address for individual streams in the SDP.

Note

Icon

Be aware that the external_media_address option, set in Transport configuration, can also affect the final media address used in the SDP.

bind_rtp_to_media_address

If media_address is specified, this option causes the RTP instance to be bound to the specified ip address which causes the packets to be sent from that address.

identify_by

Endpoints and aors can be identified in multiple ways. Currently, the supported options are username, which matches the endpoint or aor id based on the username and domain in the From header (or To header for aors), and auth_username, which matches the endpoint or aor id based on the username and realm in the Authentication header. In all cases, if an exact match on both username and domain/realm fails, the match will be retried with just the username.

Note

Icon

Identification by auth_username has some security considerations because an Authentication header is not present on the first message of a dialog when digest authentication is used. The client can't generate it until the server sends the challenge in a 401 response. Since Asterisk normally sends a security event when an incoming request can't be matched to an endpoint, using auth_username requires that the security event be deferred until a request is received with the Authentication header and only generated if the username doesn't result in a match. This may result in a delay before an attack is recognized. You can control how many unmatched requests are received from a single ip address before a security event is generated using the unidentified_request parameters in the "global" configuration object.

Note

Icon

Endpoints can also be identified by IP address; however, that method of identification is not handled by this configuration option. See the documentation for the identify configuration section for more details on that method of endpoint identification. If this option is set and an identify configuration section exists for the endpoint, then the endpoint can be identified in multiple ways.

  • username
  • auth_username

redirect_method

When a redirect is received from an endpoint there are multiple ways it can be handled. If this option is set to user the user portion of the redirect target is treated as an extension within the dialplan and dialed using a Local channel. If this option is set to uri_core the target URI is returned to the dialing application which dials it using the PJSIP channel driver and endpoint originally used. If this option is set to uri_pjsip the redirect occurs within chan_pjsip itself and is not exposed to the core at all. The uri_pjsip option has the benefit of being more efficient and also supporting multiple potential redirect targets. The con is that since redirection occurs within chan_pjsip redirecting information is not forwarded and redirection can not be prevented.

  • user
  • uri_core
  • uri_pjsip

mailboxes

Asterisk will send unsolicited MWI NOTIFY messages to the endpoint when state changes happen for any of the specified mailboxes. More than one mailbox can be specified with a comma-delimited string. app_voicemail mailboxes must be specified as [email protected]; for example: [email protected] For mailboxes provided by external sources, such as through the res_external_mwi module, you must specify strings supported by the external system.

For endpoints that SUBSCRIBE for MWI, use the mailboxes option in your AOR configuration.

rewrite_contact

On inbound SIP messages from this endpoint, the Contact header or an appropriate Record-Route header will be changed to have the source IP address and port. This option does not affect outbound messages sent to this endpoint.

rpid_immediate

When enabled, immediately send 180 Ringing or 183 Progress response messages to the caller if the connected line information is updated before the call is answered. This can send a 180 Ringing response before the call has even reached the far end. The caller can start hearing ringback before the far end even gets the call. Many phones tend to grab the first connected line information and refuse to update the display if it changes. The first information is not likely to be correct if the call goes to an endpoint not under the control of this Asterisk box.

When disabled, a connected line update must wait for another reason to send a message with the connected line information to the caller before the call is answered. You can trigger the sending of the information by using an appropriate dialplan application such as Ringing.

timers_min_se

Minimium session timer expiration period. Time in seconds.

timers
  • no
  • yes
  • required
  • always
  • forced - Alias of always

timers_sess_expires

Maximium session timer expiration period. Time in seconds.

transport

This will set the desired transport configuration to send SIP data through.

Warning

Icon

Not specifying a transport will DEFAULT to the first configured transport in pjsip.conf which is valid for the URI we are trying to contact.

Warning

Icon

Transport configuration is not affected by reloads. In order to change transports, a full Asterisk restart is required

trust_id_inbound

This option determines whether Asterisk will accept identification from the endpoint from headers such as P-Asserted-Identity or Remote-Party-ID header. This option applies both to calls originating from the endpoint and calls originating from Asterisk. If no, the configured Caller-ID from pjsip.conf will always be used as the identity for the endpoint.

trust_id_outbound

This option determines whether res_pjsip will send private identification information to the endpoint. If no, private Caller-ID information will not be forwarded to the endpoint. "Private" in this case refers to any method of restricting identification. Example: setting callerid_privacy to any prohib variation. Example: If trust_id_inbound is set to yes, the presence of a Privacy: id header in a SIP request or response would indicate the identification provided in the request is private.

use_avpf

If set to yes, res_pjsip will use the AVPF or SAVPF RTP profile for all media offers on outbound calls and media updates and will decline media offers not using the AVPF or SAVPF profile.

If set to no, res_pjsip will use the AVP or SAVP RTP profile for all media offers on outbound calls and media updates, and will decline media offers not using the AVP or SAVP profile.

force_avp

If set to yes, res_pjsip will use the AVP, AVPF, SAVP, or SAVPF RTP profile for all media offers on outbound calls and media updates including those for DTLS-SRTP streams.

If set to no, res_pjsip will use the respective RTP profile depending on configuration.

media_use_received_transport

If set to yes, res_pjsip will use the received media transport.

If set to no, res_pjsip will use the respective RTP profile depending on configuration.

media_encryption
  • no - res_pjsip will offer no encryption and allow no encryption to be setup.
  • sdes - res_pjsip will offer standard SRTP setup via in-SDP keys. Encrypted SIP transport should be used in conjunction with this option to prevent exposure of media encryption keys.
  • dtls - res_pjsip will offer DTLS-SRTP setup.

media_encryption_optimistic

This option only applies if media_encryption is set to sdes or dtls.

g726_non_standard

When set to "yes" and an endpoint negotiates g.726 audio then use g.726 for AAL2 packing order instead of what is recommended by RFC3551. Since this essentially replaces the underlying 'g726' codec with 'g726aal2' then 'g726aal2' needs to be specified in the endpoint's allowed codec list.

inband_progress

If set to yes, chan_pjsip will send a 183 Session Progress when told to indicate ringing and will immediately start sending ringing as audio.

If set to no, chan_pjsip will send a 180 Ringing when told to indicate ringing and will NOT send it as audio.

call_group

Can be set to a comma separated list of numbers or ranges between the values of 0-63 (maximum of 64 groups).

pickup_group

Can be set to a comma separated list of numbers or ranges between the values of 0-63 (maximum of 64 groups).

named_call_group

Can be set to a comma separated list of case sensitive strings limited by supported line length.

named_pickup_group

Can be set to a comma separated list of case sensitive strings limited by supported line length.

device_state_busy_at

When the number of in-use channels for the endpoint matches the devicestate_busy_at setting the PJSIP channel driver will return busy as the device state instead of in use.

t38_udptl

If set to yes T.38 UDPTL support will be enabled, and T.38 negotiation requests will be accepted and relayed.

t38_udptl_ec
  • none - No error correction should be used.
  • fec - Forward error correction should be used.
  • redundancy - Redundacy error correction should be used.

t38_udptl_maxdatagram

This option can be set to override the maximum datagram of a remote endpoint for broken endpoints.

fax_detect

This option can be set to send the session to the fax extension when a CNG tone is detected.

fax_detect_timeout

The option determines how many seconds into a call before the fax_detect option is disabled for the call. Setting the value to zero disables the timeout.

t38_udptl_nat

When enabled the UDPTL stack will send UDPTL packets to the source address of received packets.

t38_udptl_ipv6

When enabled the UDPTL stack will use IPv6.

record_on_feature

When an INFO request for one-touch recording arrives with a Record header set to "on", this feature will be enabled for the channel. The feature designated here can be any built-in or dynamic feature defined in features.conf.

Note

Icon

This setting has no effect if the endpoint's one_touch_recording option is disabled

record_off_feature

When an INFO request for one-touch recording arrives with a Record header set to "off", this feature will be enabled for the channel. The feature designated here can be any built-in or dynamic feature defined in features.conf.

Note

Icon

This setting has no effect if the endpoint's one_touch_recording option is disabled

tos_audio

See https://wiki.asterisk.org/wiki/display/AST/IP+Quality+of+Service for more information about QoS settings

tos_video

See https://wiki.asterisk.org/wiki/display/AST/IP+Quality+of+Service for more information about QoS settings

cos_audio

See https://wiki.asterisk.org/wiki/display/AST/IP+Quality+of+Service for more information about QoS settings

cos_video

See https://wiki.asterisk.org/wiki/display/AST/IP+Quality+of+Service for more information about QoS settings

dtls_verify

This option only applies if media_encryption is set to dtls.

dtls_rekey

This option only applies if media_encryption is set to dtls.

If this is not set or the value provided is 0 rekeying will be disabled.

dtls_cert_file

This option only applies if media_encryption is set to dtls.

dtls_private_key

This option only applies if media_encryption is set to dtls.

dtls_cipher

This option only applies if media_encryption is set to dtls.

Many options for acceptable ciphers. See link for more:

http://www.openssl.org/docs/apps/ciphers.html#CIPHER\_STRINGS

dtls_ca_file

This option only applies if media_encryption is set to dtls.

dtls_ca_path

This option only applies if media_encryption is set to dtls.

dtls_setup

This option only applies if media_encryption is set to dtls.

  • active - res_pjsip will make a connection to the peer.
  • passive - res_pjsip will accept connections from the peer.
  • actpass - res_pjsip will offer and accept connections from the peer.

dtls_fingerprint

This option only applies if media_encryption is set to dtls.

  • SHA-256
  • SHA-1

srtp_tag_32

This option only applies if media_encryption is set to sdes or dtls.

set_var

When a new channel is created using the endpoint set the specified variable(s) on that channel. For multiple channel variables specify multiple 'set_var'(s).

message_context

If specified, incoming MESSAGE requests will be routed to the indicated dialplan context. If no message_context is specified, then the context setting is used.

accountcode

If specified, any channel created for this endpoint will automatically have this accountcode set on it.

rtp_keepalive

At the specified interval, Asterisk will send an RTP comfort noise frame. This may be useful for situations where Asterisk is behind a NAT or firewall and must keep a hole open in order to allow for media to arrive at Asterisk.

rtp_timeout

This option configures the number of seconds without RTP (while off hold) before considering a channel as dead. When the number of seconds is reached the underlying channel is hung up. By default this option is set to 0, which means do not check.

rtp_timeout_hold

This option configures the number of seconds without RTP (while on hold) before considering a channel as dead. When the number of seconds is reached the underlying channel is hung up. By default this option is set to 0, which means do not check.

acl

This matches sections configured in acl.conf. The value is defined as a list of comma-delimited section names.

deny

The value is a comma-delimited list of IP addresses. IP addresses may have a subnet mask appended. The subnet mask may be written in either CIDR or dotted-decimal notation. Separate the IP address and subnet mask with a slash ('/')

permit

The value is a comma-delimited list of IP addresses. IP addresses may have a subnet mask appended. The subnet mask may be written in either CIDR or dotted-decimal notation. Separate the IP address and subnet mask with a slash ('/')

contact_acl

This matches sections configured in acl.conf. The value is defined as a list of comma-delimited section names.

contact_deny

The value is a comma-delimited list of IP addresses. IP addresses may have a subnet mask appended. The subnet mask may be written in either CIDR or dotted-decimal notation. Separate the IP address and subnet mask with a slash ('/')

contact_permit

The value is a comma-delimited list of IP addresses. IP addresses may have a subnet mask appended. The subnet mask may be written in either CIDR or dotted-decimal notation. Separate the IP address and subnet mask with a slash ('/')

subscribe_context

If specified, incoming SUBSCRIBE requests will be searched for the matching extension in the indicated context. If no subscribe_context is specified, then the context setting is used.

contact_user

On outbound requests, force the user portion of the Contact header to this value.

asymmetric_rtp_codec

When set to "yes" the codec in use for sending will be allowed to differ from that of the received one. PJSIP will not automatically switch the sending one to the receiving one.

auth

Authentication type

Configuration Option Reference

Option Name

Type

Default Value

Regular Expression

Description

auth_type

 

userpass

 

Authentication type

nonce_lifetime

 

32

 

Lifetime of a nonce associated with this authentication config.

md5_cred

 

 

 

MD5 Hash used for authentication.

password

 

 

 

PlainText password used for authentication.

realm

 

asterisk

 

SIP realm for endpoint

type

 

 

 

Must be 'auth'

username

 

 

 

Username to use for account

Configuration Option Descriptions

auth_type

This option specifies which of the password style config options should be read when trying to authenticate an endpoint inbound request. If set to userpass then we'll read from the 'password' option. For md5 we'll read from 'md5_cred'.

  • md5
  • userpass

md5_cred

Only used when auth_type is md5.

password

Only used when auth_type is userpass.

domain_alias

Domain Alias

Configuration Option Reference

Option Name

Type

Default Value

Regular Expression

Description

type

 

 

 

Must be of type 'domain_alias'.

domain

 

 

 

Domain to be aliased

transport

SIP Transport

Configuration Option Reference

Option Name

Type

Default Value

Regular Expression

Description

async_operations

 

1

 

Number of simultaneous Asynchronous Operations

bind

 

 

 

IP Address and optional port to bind to for this transport

ca_list_file

 

 

 

File containing a list of certificates to read (TLS ONLY)

ca_list_path

 

 

 

Path to directory containing a list of certificates to read (TLS ONLY)

cert_file

 

 

 

Certificate file for endpoint (TLS ONLY)

cipher

 

 

 

Preferred cryptography cipher names (TLS ONLY)

domain

 

 

 

Domain the transport comes from

external_media_address

 

 

 

External IP address to use in RTP handling

external_signaling_address

 

 

 

External address for SIP signalling

external_signaling_port

 

0

 

External port for SIP signalling

method

 

 

 

Method of SSL transport (TLS ONLY)

local_net

 

 

 

Network to consider local (used for NAT purposes).

password

 

 

 

Password required for transport

priv_key_file

 

 

 

Private key file (TLS ONLY)

protocol

 

udp

 

Protocol to use for SIP traffic

require_client_cert

 

false

 

Require client certificate (TLS ONLY)

type

 

 

 

Must be of type 'transport'.

verify_client

 

false

 

Require verification of client certificate (TLS ONLY)

verify_server

 

false

 

Require verification of server certificate (TLS ONLY)

tos

 

false

 

Enable TOS for the signalling sent over this transport

cos

 

false

 

Enable COS for the signalling sent over this transport

websocket_write_timeout

 

 

 

The timeout (in milliseconds) to set on WebSocket connections.

allow_reload

 

no

 

Allow this transport to be reloaded.

Configuration Option Descriptions

cert_file

A path to a .crt or .pem file can be provided. However, only the certificate is read from the file, not the private key. The priv_key_file option must supply a matching key file.

cipher

Comma separated list of cipher names or numeric equivalents. Numeric equivalents can be either decimal or hexadecimal (0xX).

There are many cipher names. Use the CLI command pjsip list ciphers to see a list of cipher names available for your installation. See link for more:

http://www.openssl.org/docs/apps/ciphers.html#CIPHER\_SUITE\_NAMES

external_media_address

When a request or response is sent out, if the destination of the message is outside the IP network defined in the option localnet, and the media address in the SDP is within the localnet network, then the media address in the SDP will be rewritten to the value defined for external_media_address.

method
  • default - The default as defined by PJSIP. This is currently TLSv1, but may change with future releases.
  • unspecified - This option is equivalent to setting 'default'
  • tlsv1
  • sslv2
  • sslv3
  • sslv23

local_net

This must be in CIDR or dotted decimal format with the IP and mask separated with a slash ('/').

protocol
  • udp
  • tcp
  • tls
  • ws
  • wss

tos

See https://wiki.asterisk.org/wiki/display/AST/IP+Quality+of+Service for more information on this parameter.

Note

Icon

This option does not apply to the ws or the wss protocols.

cos

See https://wiki.asterisk.org/wiki/display/AST/IP+Quality+of+Service for more information on this parameter.

Note

Icon

This option does not apply to the ws or the wss protocols.

websocket_write_timeout

If a websocket connection accepts input slowly, the timeout for writes to it can be increased to keep it from being disconnected. Value is in milliseconds; default is 100 ms.

allow_reload

Allow this transport to be reloaded when res_pjsip is reloaded. This option defaults to "no" because reloading a transport may disrupt in-progress calls.

contact

A way of creating an aliased name to a SIP URI

Configuration Option Reference

Option Name

Type

Default Value

Regular Expression

Description

type

 

 

 

Must be of type 'contact'.

uri

 

 

 

SIP URI to contact peer

expiration_time

 

 

 

Time to keep alive a contact

qualify_frequency

 

0

 

Interval at which to qualify a contact

qualify_timeout

 

3.0

 

Timeout for qualify

authenticate_qualify

 

no

 

Authenticates a qualify request if needed

outbound_proxy

 

 

 

Outbound proxy used when sending OPTIONS request

path

 

 

 

Stored Path vector for use in Route headers on outgoing requests.

user_agent

 

 

 

User-Agent header from registration.

endpoint

 

 

 

Endpoint name

reg_server

 

 

 

Asterisk Server name

via_addr

 

 

 

IP-address of the last Via header from registration.

via_port

 

 

 

IP-port of the last Via header from registration.

call_id

 

 

 

Call-ID header from registration.

Configuration Option Descriptions

expiration_time

Time to keep alive a contact. String style specification.

qualify_frequency

Interval between attempts to qualify the contact for reachability. If 0 never qualify. Time in seconds.

qualify_timeout

If the contact doesn't repond to the OPTIONS request before the timeout, the contact is marked unavailable. If 0 no timeout. Time in fractional seconds.

authenticate_qualify

If true and a qualify request receives a challenge or authenticate response authentication is attempted before declaring the contact available.

outbound_proxy

If set the provided URI will be used as the outbound proxy when an OPTIONS request is sent to a contact for qualify purposes.

user_agent

The User-Agent is automatically stored based on data present in incoming SIP REGISTER requests and is not intended to be configured manually.

endpoint

The name of the endpoint this contact belongs to

reg_server

Asterisk Server name on which SIP endpoint registered.

via_addr

The last Via header should contain the address of UA which sent the request. The IP-address of the last Via header is automatically stored based on data present in incoming SIP REGISTER requests and is not intended to be configured manually.

via_port

The IP-port of the last Via header is automatically stored based on data present in incoming SIP REGISTER requests and is not intended to be configured manually.

call_id

The Call-ID header is automatically stored based on data present in incoming SIP REGISTER requests and is not intended to be configured manually.

aor

The configuration for a location of an endpoint

Configuration Option Reference

Option Name

Type

Default Value

Regular Expression

Description

contact

 

 

 

Permanent contacts assigned to AoR

default_expiration

 

3600

 

Default expiration time in seconds for contacts that are dynamically bound to an AoR.

mailboxes

 

 

 

Allow subscriptions for the specified mailbox(es)

voicemail_extension

 

 

 

The voicemail extension to send in the NOTIFY Message-Account header

maximum_expiration

 

7200

 

Maximum time to keep an AoR

max_contacts

 

0

 

Maximum number of contacts that can bind to an AoR

minimum_expiration

 

60

 

Minimum keep alive time for an AoR

remove_existing

 

no

 

Determines whether new contacts replace existing ones.

type

 

 

 

Must be of type 'aor'.

qualify_frequency

 

0

 

Interval at which to qualify an AoR

qualify_timeout

 

3.0

 

Timeout for qualify

authenticate_qualify

 

no

 

Authenticates a qualify request if needed

outbound_proxy

 

 

 

Outbound proxy used when sending OPTIONS request

support_path

 

 

 

Enables Path support for REGISTER requests and Route support for other requests.

Configuration Option Descriptions

contact

Contacts specified will be called whenever referenced by chan_pjsip.

Use a separate "contact=" entry for each contact required. Contacts are specified using a SIP URI.

mailboxes

This option applies when an external entity subscribes to an AoR for Message Waiting Indications. The mailboxes specified will be subscribed to. More than one mailbox can be specified with a comma-delimited string. app_voicemail mailboxes must be specified as [email protected]; for example: [email protected] For mailboxes provided by external sources, such as through the res_external_mwi module, you must specify strings supported by the external system.

For endpoints that cannot SUBSCRIBE for MWI, you can set the mailboxes option in your endpoint configuration section to enable unsolicited MWI NOTIFYs to the endpoint.

maximum_expiration

Maximium time to keep a peer with explicit expiration. Time in seconds.

max_contacts

Maximum number of contacts that can associate with this AoR. This value does not affect the number of contacts that can be added with the "contact" option. It only limits contacts added through external interaction, such as registration.

Note

Icon

This should be set to 1 and remove_existing set to yes if you wish to stick with the older chan_sip behaviour.

minimum_expiration

Minimum time to keep a peer with an explict expiration. Time in seconds.

remove_existing

On receiving a new registration to the AoR should it remove the existing contact that was registered against it?

Note

Icon

This should be set to yes and max_contacts set to 1 if you wish to stick with the older chan_sip behaviour.

qualify_frequency

Interval between attempts to qualify the AoR for reachability. If 0 never qualify. Time in seconds.

qualify_timeout

If the contact doesn't repond to the OPTIONS request before the timeout, the contact is marked unavailable. If 0 no timeout. Time in fractional seconds.

authenticate_qualify

If true and a qualify request receives a challenge or authenticate response authentication is attempted before declaring the contact available.

outbound_proxy

If set the provided URI will be used as the outbound proxy when an OPTIONS request is sent to a contact for qualify purposes.

support_path

When this option is enabled, the Path headers in register requests will be saved and its contents will be used in Route headers for outbound out-of-dialog requests and in Path headers for outbound 200 responses. Path support will also be indicated in the Supported header.

system

Options that apply to the SIP stack as well as other system-wide settings

Configuration Option Reference

Option Name

Type

Default Value

Regular Expression

Description

timer_t1

 

500

 

Set transaction timer T1 value (milliseconds).

timer_b

 

32000

 

Set transaction timer B value (milliseconds).

compact_headers

 

no

 

Use the short forms of common SIP header names.

threadpool_initial_size

 

0

 

Initial number of threads in the res_pjsip threadpool.

threadpool_auto_increment

 

5

 

The amount by which the number of threads is incremented when necessary.

threadpool_idle_timeout

 

60

 

Number of seconds before an idle thread should be disposed of.

threadpool_max_size

 

0

 

Maximum number of threads in the res_pjsip threadpool. A value of 0 indicates no maximum.

disable_tcp_switch

 

yes

 

Disable automatic switching from UDP to TCP transports.

type

 

 

 

Must be of type 'system'.

Configuration Option Descriptions

timer_t1

Timer T1 is the base for determining how long to wait before retransmitting requests that receive no response when using an unreliable transport (e.g. UDP). For more information on this timer, see RFC 3261, Section 17.1.1.1.

timer_b

Timer B determines the maximum amount of time to wait after sending an INVITE request before terminating the transaction. It is recommended that this be set to 64 * Timer T1, but it may be set higher if desired. For more information on this timer, see RFC 3261, Section 17.1.1.1.

disable_tcp_switch

Disable automatic switching from UDP to TCP transports if outgoing request is too large. See RFC 3261 section 18.1.1.

global

Options that apply globally to all SIP communications

Configuration Option Reference

Option Name

Type

Default Value

Regular Expression

Description

max_forwards

 

70

 

Value used in Max-Forwards header for SIP requests.

keep_alive_interval

 

0

 

The interval (in seconds) to send keepalives to active connection-oriented transports.

contact_expiration_check_interval

 

30

 

The interval (in seconds) to check for expired contacts.

disable_multi_domain

 

no

 

Disable Multi Domain support

max_initial_qualify_time

 

0

 

The maximum amount of time from startup that qualifies should be attempted on all contacts. If greater than the qualify_frequency for an aor, qualify_frequency will be used instead.

unidentified_request_period

 

5

 

The number of seconds over which to accumulate unidentified requests.

unidentified_request_count

 

5

 

The number of unidentified requests from a single IP to allow.

unidentified_request_prune_interval

 

30

 

The interval at which unidentified requests are older than twice the unidentified_request_period are pruned.

type

 

 

 

Must be of type 'global'.

user_agent

 

Asterisk <Asterisk Version>

 

Value used in User-Agent header for SIP requests and Server header for SIP responses.

regcontext

 

 

 

When set, Asterisk will dynamically create and destroy a NoOp priority 1 extension for a given peer who registers or unregisters with us.

default_outbound_endpoint

 

default_outbound_endpoint

 

Endpoint to use when sending an outbound request to a URI without a specified endpoint.

default_voicemail_extension

 

 

 

The voicemail extension to send in the NOTIFY Message-Account header if not specified on endpoint or aor

debug

 

no

 

Enable/Disable SIP debug logging. Valid options include yes

no or a host address

endpoint_identifier_order

 

ip,username,anonymous

 

The order by which endpoint identifiers are processed and checked. Identifier names are usually derived from and can be found in the endpoint identifier module itself (res_pjsip_endpoint_identifier_*). You can use the CLI command "pjsip show identifiers" to see the identifiers currently available.

default_from_user

 

asterisk

 

When Asterisk generates an outgoing SIP request, the From header username will be set to this value if there is no better option (such as CallerID) to be used.

default_realm

 

asterisk

 

When Asterisk generates an challenge, the digest will be set to this value if there is no better option (such as auth/realm) to be used.

mwi_tps_queue_high

 

500

 

MWI taskprocessor high water alert trigger level.

mwi_tps_queue_low

 

-1

 

MWI taskprocessor low water clear alert level.

mwi_disable_initial_unsolicited

 

no

 

Enable/Disable sending unsolicited MWI to all endpoints on startup.

ignore_uri_user_options

 

 

 

Enable/Disable ignoring SIP URI user field options.

Configuration Option Descriptions

disable_multi_domain

If disabled it can improve realtime performace by reducing number of database requsts.

unidentified_request_period

If unidentified_request_count unidentified requests are received during unidentified_request_period, a security event will be generated.

unidentified_request_count

If unidentified_request_count unidentified requests are received during unidentified_request_period, a security event will be generated.

endpoint_identifier_order

Note

Icon

One of the identifiers is "auth_username" which matches on the username in an Authentication header. This method has some security considerations because an Authentication header is not present on the first message of a dialog when digest authentication is used. The client can't generate it until the server sends the challenge in a 401 response. Since Asterisk normally sends a security event when an incoming request can't be matched to an endpoint, using auth_username requires that the security event be deferred until a request is received with the Authentication header and only generated if the username doesn't result in a match. This may result in a delay before an attack is recognized. You can control how many unmatched requests are received from a single ip address before a security event is generated using the unidentified_request parameters.

mwi_tps_queue_high

On a heavily loaded system you may need to adjust the taskprocessor queue limits. If any taskprocessor queue size reaches its high water level then pjsip will stop processing new requests until the alert is cleared. The alert clears when all alerting taskprocessor queues have dropped to their low water clear level.

mwi_tps_queue_low

On a heavily loaded system you may need to adjust the taskprocessor queue limits. If any taskprocessor queue size reaches its high water level then pjsip will stop processing new requests until the alert is cleared. The alert clears when all alerting taskprocessor queues have dropped to their low water clear level.

Note

Icon

Set to -1 for the low water level to be 90% of the high water level.

mwi_disable_initial_unsolicited

When the initial unsolicited MWI notification are enabled on startup then the initial notifications get sent at startup. If you have a lot of endpoints (thousands) that use unsolicited MWI then you may want to consider disabling the initial startup notifications.

When the initial unsolicited MWI notifications are disabled on startup then the notifications will start on the endpoint's next contact update.

ignore_uri_user_options

If you have this option enabled and there are semicolons in the user field of a SIP URI then the field is truncated at the first semicolon. This effectively makes the semicolon a non-usable character for PJSIP endpoint names, extensions, and AORs. This can be useful for improving compatability with an ITSP that likes to use user options for whatever reason.

Example: Sample SIP URI
Example: Sample SIP URI user field
Example: Sample SIP URI user field truncated

Note

Icon

The caller-id and redirecting number strings obtained from incoming SIP URI user fields are always truncated at the first semicolon.

Import Version

This documentation was imported from Asterisk Version GIT-13-13.12.2-240-gbd37196

  • No labels