Skip to content
Snippets Groups Projects
  1. Mar 28, 2019
    • Ben Ford's avatar
      alembic: Fix errors during upgrade head. · 4edd2484
      Ben Ford authored
      When trying to upgrade using alembic, a couple different errors kept
      popping up that prevented the upgrade. An additional parameter was
      needed when changing the schema for mwi_subscribe_replaces_unsolicited
      from an integer to an enum. When changing from a string to an enum, the
      type needed to be cast for postgresql. The other issue was a parameter
      being used during column creation that did not exist.
      
      After fixing the upgrade process, it revealed errors with the downgrade
      process. One was a variable not being defined in the downgrade function,
      and the other was tables not existing when using MySQL. This was due to
      a context check that should have encompassed MySQL, but in the end was
      not doing so.
      
      Change-Id: Ib4d70cf3ce5080023a50be496272a777b55d6c8e
      4edd2484
  2. Mar 08, 2019
    • Torrey Searle's avatar
      chan_pjsip: add a flag to ignore 183 responses if no SDP present · 4661c085
      Torrey Searle authored
      chan_sip will always ignore 183 responses that do not contain SDP
      however, chan_pjsip will currently always translate it into a
      183 with SDP.  This new flag allows chan_pjsip to have the same
      behavior as chan_sip.
      
      ASTERISK-28322 #close
      
      Change-Id: If81cfaa17c11b6ac703e3d71696f259d86c6be4a
      4661c085
  3. Feb 20, 2019
    • George Joseph's avatar
      taskprocessor: Enable subsystems and overload by subsystem · c2adeb9d
      George Joseph authored
      To prevent one subsystem's taskprocessors from causing others
      to stall, new capabilities have been added to taskprocessors.
      
      * Any taskprocessor name that has a '/' will have the part
        before the '/' saved as its "subsystem".
        Examples:
        "sorcery/acl-0000006a" and "sorcery/aor-00000019"
        will be grouped to subsystem "sorcery".
        "pjsip/distributor-00000025" and "pjsip/distributor-00000026"
        will bn grouped to subsystem "pjsip".
        Taskprocessors with no '/' have an empty subsystem.
      
      * When a taskprocessor enters high-water alert status and it
        has a non-empty subsystem, the subsystem alert count will
        be incremented.
      
      * When a taskprocessor leaves high-water alert status and it
        has a non-empty subsystem, the subsystem alert count will be
        decremented.
      
      * A new api ast_taskprocessor_get_subsystem_alert() has been
        added that returns the number of taskprocessors in alert for
        the subsystem.
      
      * A new CLI command "core show taskprocessor alerted subsystems"
        has been added.
      
      * A new unit test was addded.
      
      REMINDER: The taskprocessor code itself doesn't take any action
      based on high-water alerts or overloading.  It's up to taskprocessor
      users to check and take action themselves.  Currently only the pjsip
      distributor does this.
      
      * A new pjsip/global option "taskprocessor_overload_trigger"
        has been added that allows the user to select the trigger
        mechanism the distributor uses to pause accepting new requests.
        "none": Don't pause on any overload condition.
        "global": Pause on ANY taskprocessor overload (the default and
        current behavior)
        "pjsip_only": Pause only on pjsip taskprocessor overloads.
      
      * The core pjsip pool was renamed from "SIP" to "pjsip" so it can
        be properly grouped into the "pjsip" subsystem.
      
      * stasis taskprocessor names were changed to "stasis" as the
        subsystem.
      
      * Sorcery core taskprocessor names were changed to "sorcery" to
        match the object taskprocessors.
      
      Change-Id: I8c19068bb2fc26610a9f0b8624bdf577a04fcd56
      c2adeb9d
  4. Jan 11, 2019
    • Alexei Gradinari's avatar
      res_pjsip: add option to enable ContactStatus event when contact is updated · f0546d1d
      Alexei Gradinari authored
      The commit I2f97ebfa79969a36a97bb7b9afd5b6268cf1a07d removed sending out
      the ContactStatus AMI event when a contact is updated.
      Thist change broke things which rely on old behavior.
      
      This patch adds a new PJSIP global configuration option
      'send_contact_status_on_update_registration' to be able to preserve old
      ContactStatus behavior.
      By default new behavior, i.e. the ContactStatus event will not be sent when a
      device refreshes its registration.
      
      Change-Id: I706adf7584e7077eb6bde6d9799ca408bc82ce46
      f0546d1d
  5. Dec 03, 2018
  6. Oct 30, 2018
  7. Oct 26, 2018
    • Torrey Searle's avatar
      res_pjsip_session: add new flag use_callerid_contact · cac4ccef
      Torrey Searle authored
      Add a new global flag to res_pjsip to allow the callerid to be used
      as the username in the contact header.  This allows chan_pjsip to have
      the same behavour as chan_sip
      
      ASTERISK-28087 #close
      
      Change-Id: I9a720e058323f6862a91c62f8a8c1a4b5c087b95
      cac4ccef
  8. Oct 24, 2018
    • Nick French's avatar
      res_pjsip: Implement additional SIP RFCs for Google Voice trunk compatability · 37b2e686
      Nick French authored
      This change implements a few different generic things which were brought
      on by Google Voice SIP.
      
      1.  The concept of flow transports have been introduced.  These are
      configurable transports in pjsip.conf which can be used to reference a
      flow of signaling to a target.  These have runtime configuration that can
      be changed by the signaling itself (such as Service-Routes and
      P-Preferred-Identity).  When used these guarantee an individual connection
      (in the case of TCP or TLS) even if multiple flow transports exist to the
      same target.
      
      2.  Service-Routes (RFC 3608) support has been added to the outbound
      registration module which when received will be stored on the flow
      transport and used for requests referencing it.
      
      3.  P-Associated-URI / P-Preferred-Identity (RFC 3325) support has been
      added to the outbound registration module.  If a P-Associated-URI header
      is received it will be used on requests as the P-Preferred-Identity.
      
      4.  Configurable outbound extension support has been added to the outbound
      registration module.  When set the extension will be placed in the
      Supported header.
      
      5.  Header parameters can now be configured on an outbound registration
      which will be placed in the Contact header.
      
      6.  Google specific OAuth / Bearer token authentication
      (draft-ietf-sipcore-sip-authn-02) has been added to the outbound
      registration module.
      
      All functionality changes are controlled by pjsip.conf configuration
      options and do not affect non-configured pjsip endpoints otherwise.
      
      ASTERISK-27971 #close
      
      Change-Id: Id214c2d1c550a41fcf564b7df8f3da7be565bd58
      37b2e686
  9. Sep 18, 2018
    • Florian Floimair's avatar
      alembic: fix suppress_q850_reason_headers column name · 6a1c313f
      Florian Floimair authored
      In the original commit introducing the feature the column in the alembic
      script was called 'suppress_q850_reason_header'.
      In the code however the option is called 'suppress_q850_reason_headers'
      (trailing 's'). This leads to errors when ARI push configuration is used.
      
      Change-Id: Ie84808adbca6fcc9136556e4f5d741adbef5d14f
      6a1c313f
  10. Aug 29, 2018
  11. Aug 23, 2018
    • Florian Floimair's avatar
      alembic: increase uri column size · 3bdbbb76
      Florian Floimair authored
      When mobile SIP clients register with Asterisk that use some sort of
      push notifications, the URI can get quite lengthy due to the
      additional push-service annotations (things like tokens, pn-type, etc.)
      contained in it.
      
      ASTERISK-28022 #close
      
      Change-Id: I4c7ceadc3bb405f3daf722641c8cd5ca4188cc37
      3bdbbb76
  12. Jul 06, 2018
    • George Joseph's avatar
      res_pjsip: Add 'suppress_q850_reason_headers' option to endpoint · 8f42447c
      George Joseph authored
      A new option 'suppress_q850_reason_headers' has been added to the
      endpoint object. Some devices can't accept multiple Reason headers and
      get confused when both 'SIP' and 'Q.850' Reason headers are received.
      This option allows the 'Q.850' Reason header to be suppressed.
      The default value is 'no'.
      
      ASTERISK-27949
      Reported-by: Ross Beer
      
      Change-Id: I54cf37a827d77de2079256bb3de7e90fa5e1deb1
      8f42447c
  13. Jun 26, 2018
    • George Joseph's avatar
      res_pjsip_session: Add ability to accept multiple sdp answers · 880fbff6
      George Joseph authored
      pjproject by default currently will follow media forked during an INVITE
      on outbound calls if the To tag is different on a subsequent response as
      that on an earlier response.  We handle this correctly.  There have
      been reported cases where the To tag is the same but we still need to
      follow the media.  The pjproject patch in this commit adds the
      capability to sip_inv and also adds the capability to control it at
      runtime.  The original "different tag" behavior was always controllable
      at runtime but we never did anything with it and left it to default to
      TRUE.
      
      So, along with the pjproject patch, this commit adds options to both the
      system and endpoint objects to control the two behaviors, and a small
      logic change to session_inv_on_media_update in res_pjsip_session to
      control the behavior at the endpoint level.
      
      The default behavior for "different tags" remains the same at TRUE and
      the default for "same tag" is FALSE.
      
      Change-Id: I64d071942b79adb2f0a4e13137389b19404fe3d6
      ASTERISK-27936
      Reported-by: Ross Beer
      880fbff6
  14. Jan 30, 2018
    • George Joseph's avatar
      res_pjsip_pubsub: Prune subs with reliable transports at startup · 2b9aa6b5
      George Joseph authored
      In an earlier release, inbound registrations on a reliable transport
      were pruned on Asterisk restart since the TCP connection would have
      been torn down and become unusable when Asterisk stopped.  This same
      process is now also applied to inbound subscriptions.
      
      Also fixed issues in res_pjsip_registrar where it wasn't handling the
      monitoring correctly when multiple registrations came in over the same
      transport.
      
      To accomplish this, the pjsip_transport_event feature needed to
      be refactored to allow multiple monitors (multiple subcriptions or
      registrations from the same endpoint) to exist on the same transport.
      Since this changed the API, any external modules that may have used the
      transport monitor feature (highly unlikey) will need to be changed.
      
      ASTERISK-27612
      Reported by: Ross Beer
      
      Change-Id: Iee87cf4eb9b7b2b93d5739a72af52d6ca8fbbe36
      2b9aa6b5
  15. Jan 16, 2018
    • Richard Mudgett's avatar
      res_pjsip: Split type=identify to IP address and SIP header matching priorities · 8494e780
      Richard Mudgett authored
      The type=identify endpoint identification method can match by IP address
      and by SIP header.  However, the SIP header matching has limited
      usefulness because you cannot specify the SIP header matching priority
      relative to the IP address matching.  All the matching happens at the same
      priority and the order of evaluating the identify sections is
      indeterminate.  e.g., If you had two type=identify sections where one
      matches by IP address for endpoint alice and the other matches by SIP
      header for endpoint bob then you couldn't predict which endpoint is
      matched when a request comes in that matches both.
      
      * Extract the SIP header matching criteria into its own "header" endpoint
      identification method so the user can specify the relative priority of the
      SIP header and the IP address matching criteria in the global
      endpoint_identifier_order option.  The "ip" endpoint identification method
      now only matches by IP address.
      
      ASTERISK-27491
      
      Change-Id: I9df142a575b7e1e3471b7cda5d3ea156cef08095
      8494e780
  16. Dec 22, 2017
  17. Dec 18, 2017
  18. Nov 06, 2017
    • Sean Bright's avatar
      dtls: Add support for ephemeral DTLS certificates. · 04d3785a
      Sean Bright authored
      This mimics the behavior of Chrome and Firefox and creates an ephemeral
      X.509 certificate for each DTLS session.
      
      Currently, the only supported key type is ECDSA because of its faster
      generation time, but other key types can be added in the future as
      necessary.
      
      ASTERISK-27395
      
      Change-Id: I5122e5f4b83c6320cc17407a187fcf491daf30b4
      04d3785a
  19. Oct 30, 2017
  20. Oct 25, 2017
    • Joshua Colp's avatar
      res_pjsip: Add 'ip' as a valid option to 'identify_by' on endpoint. · 9e1fbab3
      Joshua Colp authored
      When the identify_by option on an endpoint is set to ip it will
      only be identified using the res_pjsip_endpoint_identifier_ip module.
      This ensures that it is not mistakenly matched using the username of
      the From header. To ensure behavior has not changed the default has
      been changed to "username,ip" for the identify_by option.
      
      ASTERISK-27206
      
      Change-Id: I2170b86a7f7e221b4f00bf14aa1ef1ac5b050bbd
      9e1fbab3
  21. Sep 13, 2017
    • George Joseph's avatar
      res_pjsip: Add handling for incoming unsolicited MWI NOTIFY · 446d48fd
      George Joseph authored
      A new endpoint parameter "incoming_mwi_mailbox" allows Asterisk to
      receive unsolicited MWI NOTIFY requests and make them available to
      other modules via the stasis message bus.
      
      res_pjsip_pubsub has a new handler "pubsub_on_rx_mwi_notify_request"
      that parses a simple-message-summary body and, if
      endpoint->incoming_mwi_account is set, calls ast_publish_mwi_state
      with the voice-message counts from the message.
      
      Change-Id: I08bae3d16e77af48fcccc2c936acce8fc0ef0f3c
      446d48fd
  22. Sep 11, 2017
  23. Sep 08, 2017
    • Florian Floimair's avatar
      alembic: Add support for MS-SQL · e9a81157
      Florian Floimair authored
      MS-SQL has no native Enum-type support and therefore
      needs to work with constraints.
      Since these constraints need unique names the suggested approach
      referenced in the following alembic documentation has been applied:
      http://bit.ly/2x9r8pb
      
      ASTERISK-27255 #close
      
      Change-Id: I8b579750dae0c549f1103ee50172644afb9b2f95
      e9a81157
  24. Sep 06, 2017
  25. Aug 25, 2017
  26. Aug 10, 2017
    • Richard Mudgett's avatar
      res_pjsip: Remove ephemeral registered contacts on transport shutdown. · 82f4ade9
      Richard Mudgett authored
      The fix for the issue is broken up into three parts.
      
      This is part two which handles the server side of REGISTER requests when
      rewrite_contact is enabled.  Any registered reliable transport contact
      becomes invalid when the transport connection becomes disconnected.
      
      * Monitor the rewrite_contact's reliable transport REGISTER contact for
      shutdown.  If it is shutdown then the contact must be removed because it
      is no longer valid.  Otherwise, when the client attempts to re-REGISTER it
      may be blocked because the invalid contact is there.  Also if we try to
      send a call to the endpoint using the invalid contact then the endpoint is
      not likely to see the request.  The endpoint either won't be listening on
      that port for new connections or a NAT/firewall will block it.
      
      * Prune any rewrite_contact's registered reliable transport contacts on
      boot.  The reliable transport no longer exists so the contact is invalid.
      
      * Websockets always rewrite the REGISTER contact address and the transport
      needs to be monitored for shutdown.
      
      * Made the websocket transport set a unique name since that is what we use
      as the ao2 container key.  Otherwise, we would not know which transport we
      find when one of them shuts down.  The names are also used for PJPROJECT
      debug logging.
      
      * Made the websocket transport post the PJSIP_TP_STATE_CONNECTED state
      event.  Now the global keep_alive_interval option, initially idle shutdown
      timer, and the server REGISTER contact monitor can work on wetsocket
      transports.
      
      * Made the websocket transport set the PJSIP_TP_DIR_INCOMING direction.
      Now initially idle websockets will automatically shutdown.
      
      ASTERISK-27147
      
      Change-Id: I397a5e7d18476830f7ffe1726adf9ee6c15964f4
      82f4ade9
  27. Aug 03, 2017
    • Kevin Harwell's avatar
      alembic/res_pjsip: Add "webrtc" configuration option · 521b6fed
      Kevin Harwell authored
      When the "webrtc" option was added in res_pjsip it was not added to the alembic
      scripts. This patch adds the option for alembic.
      
      Also, changed the sorcery configuration type to an OPT_YESNO_T value instead of
      an OPT_BOOL_T so if this field is ever written to a database it will write out
      the correct value.
      
      ASTERISK-27119 #close
      
      Change-Id: I3e199f060aea25e193c439fc5cf96be4d3ed1c7b
      521b6fed
  28. Jul 06, 2017
  29. Jun 29, 2017
    • Torrey Searle's avatar
      res_pjsip: Add DTMF INFO Failback mode · fb7247c5
      Torrey Searle authored
      The existing auto dtmf mode reverts to inband if 4733 fails to be
      negotiated.  This patch adds a new mode auto_info which will
      switch to INFO instead of inband if 4733 is not available.
      
      ASTERISK-27066 #close
      
      Change-Id: Id185b11e84afd9191a2f269e8443019047765e91
      fb7247c5
  30. Jun 28, 2017
    • Mark Michelson's avatar
      chan_pjsip: Add support for multiple streams of the same type. · 45df25a5
      Mark Michelson authored
      The stream topology (list of streams and order) is now stored with the
      configured PJSIP endpoints and used during the negotiation process.
      
      Media negotiation state information has been changed to be stored
      in a separate object. Two of these objects exist at any one time
      on a session. The active media state information is what was previously
      negotiated and the pending media state information is what the
      media state will become if negotiation succeeds. Streams and other
      state information is stored in this object using the index (or
      position) of each individual stream for easy lookup.
      
      The ability for a media type handler to specify a callback for
      writing has been added as well as the ability to add file
      descriptors with a callback which is invoked when data is available
      to be read on them. This allows media logic to live outside of
      the chan_pjsip module.
      
      Direct media has been changed so that only the first audio and
      video stream are directly connected. In the future once the RTP
      engine glue API has been updated to know about streams each individual
      stream can be directly connected as appropriate.
      
      Media negotiation itself will currently answer all the provided streams
      on an offer within configured limits and on an offer will use the
      topology created as a result of the disallow/allow codec lines.
      
      If a stream has been removed or declined we will now mark it as such
      within the resulting SDP.
      
      Applications can now also request that the stream topology change.
      If we are told to do so we will limit any provided formats to the ones
      configured on the endpoint and send a re-invite with the new topology.
      
      Two new configuration options have also been added to PJSIP endpoints:
      
      max_audio_streams: determines the maximum number of audio streams to
      offer/accept from an endpoint. Defaults to 1.
      
      max_video_streams: determines the maximum number of video streams to
      offer/accept from an endpoint. Defaults to 1.
      
      ASTERISK-27076
      
      Change-Id: I8afd8dd2eb538806a39b887af0abd046266e14c7
      45df25a5
  31. Jun 16, 2017
    • Alexei Gradinari's avatar
      res_pjsip: New endpoint option "notify_early_inuse_ringing" · 7a46309d
      Alexei Gradinari authored
      This option was added to control whether to notify dialog-info state
      'early' or 'confirmed' on Ringing when already INUSE.
      The value "yes" is useful for some SIP phones (Cisco SPA)
      to be able to indicate and pick up ringing devices.
      
      ASTERISK-26919 #close
      
      Change-Id: Ie050bc30023543c7dfb4365c5be3ce58c738c711
      7a46309d
  32. May 11, 2017
    • Alexei Gradinari's avatar
      res_pjsip: New endpoint option "refer_blind_progress" · 808f2998
      Alexei Gradinari authored
      This option was added to turn off notifying the progress details
      on Blind Transfer. If this option is not set then the chan_pjsip
      will send NOTIFY "200 OK" immediately after "202 Accepted".
      
      Some SIP phones like Mitel/Aastra or Snom keep the line busy until
      receive "200 OK".
      
      ASTERISK-26333 #close
      
      Change-Id: Id606fbff2e02e967c02138457badc399144720f2
      808f2998
  33. Apr 25, 2017
  34. Apr 07, 2017
    • Joshua Colp's avatar
      pjsip: Add Alembic for PUBLISH support. · 270b485f
      Joshua Colp authored
      This change adds database tables for the PUBLISH support so it
      can be configured using realtime. A minor fix to the
      res_pjsip_publish_asterisk module was done so that it read the
      sorcery configuration from the correct section. Finally the
      sample configuration files have been updated.
      
      ASTERISK-26928
      
      Change-Id: I81991ae5c75af98d247f7eacd1c0b0a763675952
      270b485f
  35. Mar 28, 2017
  36. Mar 22, 2017
    • Richard Begg's avatar
      res_pjsip_session: Enable RFC3578 overlap dialing support. · 6b7697ed
      Richard Begg authored
      Support for RFC3578 overlap dialling (i.e. 484 Response to partially matched
      destinations) as currently provided by chan_sip is missing from res_pjsip.
      This patch adds a new endpoint attribute (allow_overlap) [defaults to yes]
      which when set to yes enables 484 responses to partial destination
      matches rather than the current 404.
      
      ASTERISK-26864
      
      Change-Id: Iea444da3ee7c7d4f1fde1d01d138a3d7b0fe40f6
      6b7697ed
  37. Mar 16, 2017
    • George Joseph's avatar
      res_pjsip: Symmetric transports · 5013d8f5
      George Joseph authored
      A new transport parameter 'symmetric_transport' has been added.
      
      When a request from a dynamic contact comes in on a transport with
      this option set to 'yes', the transport name will be saved and used
      for subsequent outgoing requests like OPTIONS, NOTIFY and INVITE.
      It's saved as a contact uri parameter named 'x-ast-txp' and will
      display with the contact uri in CLI, AMI, and ARI output.  On the
      outgoing request, if a transport wasn't explicitly set on the
      endpoint AND the request URI is not a hostname, the saved transport
      will be used and the 'x-ast-txp' parameter stripped from the
      outgoing packet.
      
      * config_transport was modified to accept and store the new parameter.
      
      * config_transport/transport_apply was updated to store the transport
        name in the pjsip_transport->info field using the pjsip_transport->pool
        on UDP transports.
      
      * A 'multihomed_on_rx_message' function was added to
        pjsip_message_ip_updater that, for incoming requests, retrieves the
        transport name from pjsip_transport->info and retrieves the transport.
        If transport->symmetric_transport is set, an 'x-ast-txp' uri parameter
        containing the transport name is added to the incoming Contact header.
      
      * An 'ast_sip_get_transport_name' function was added to res_pjsip.
        It takes an ast_sip_endpoint and a pjsip_sip_uri and returns a
        transport name if endpoint->transport is set or if there's an
        'x-ast-txp' parameter on the uri and the uri host is an ipv4 or
        ipv6 address.  Otherwise it returns NULL.
      
      * An 'ast_sip_dlg_set_transport' function was added to res_pjsip
        which takes an ast_sip_endpoint, a pjsip_dialog, and an optional
        pjsip_tpselector.  It calls ast_sip_get_transport_name() and if
        a non-NULL is returned, sets the selector and sets the transport
        on the dialog.  If a selector was passed in, it's updated.
      
      * res_pjsip/ast_sip_create_dialog_uac and ast_sip_create_dialog_uas
        were modified to call ast_sip_dlg_set_transport() instead of their
        original logic.
      
      * res_pjsip/create_out_of_dialog_request was modified to call
        ast_sip_get_transport_name() and pjsip_tx_data_set_transport()
        instead of its original logic.
      
      * Existing transport logic was removed from endpt_send_request
        since that can only be called after a create_out_of_dialog_request.
      
      * res_pjsip/ast_sip_create_rdata was converted to a wrapper around
        a new 'ast_sip_create_rdata_with_contact' function which allows
        a contact_uri to be specified in addition to the existing
        parameters.  (See below)
      
      * res_pjsip_pubsub/internal_pjsip_evsub_send_request was eliminated
        since all it did was transport selection and that is now done in
        ast_sip_create_dialog_uac and ast_sip_create_dialog_uas.
      
      * 'contact_uri' was added to subscription_persistence.  This was
        necessary because although the parsed rdata contact header has the
        x-ast-txp parameter added (if appropriate),
        subscription_persistence_update stores the raw packet which
        doesn't have it.  subscription_persistence_recreate was then
        updated to call ast_sip_create_rdata_with_contact with the
        persisted contact_uri so the recreated subscription has the
        correct transport info to send the NOTIFYs.
      
      * res_pjsip_session/internal_pjsip_inv_send_msg was eliminated since
        all it did was transport selection and that is now done in
        ast_sip_create_dialog_uac.
      
      * pjsip_message_ip_updater/multihomed_on_tx_message was updated
        to remove all traces of the x-ast-txp parameter from the
        outgoing headers.
      
      NOTE:  This change does NOT modify the behavior of permanent
      contacts specified on an aor.  To do so would require that the
      permanent contact's contact uri be updated with the x-ast-txp
      parameter and the aor sorcery object updated.  If we need to
      persue this, we need to think about cloning permanent contacts into
      the same store as the dynamic ones on an aor load so they can be
      updated without disturbing the originally configured value.
      
      You CAN add the x-ast-txp parameter to a permanent contact's uri
      but it would be much simpler to just set endpoint->transport.
      
      Change-Id: I4ee1f51473da32ca54b877cd158523efcef9655f
      5013d8f5
  38. Mar 15, 2017
    • Mark Michelson's avatar
      Add rtcp-mux support · 10fa49e3
      Mark Michelson authored
      This commit adds support for RFC 5761: Multiplexing RTP Data and Control
      Packets on a Single Port. Specifically, it enables the feature when
      using chan_pjsip.
      
      A new option, "rtcp_mux" has been added to endpoint configuration in
      pjsip.conf. If set, then Asterisk will attempt to use rtcp-mux with
      whatever it communicates with. Asterisk follows the rules set forth in
      RFC 5761 with regards to falling back to standard RTCP behavior if the
      far end does not indicate support for rtcp-mux.
      
      The lion's share of the changes in this commit are in
      res_rtp_asterisk.c. This is because it was pretty much hard wired to
      have an RTP and an RTCP transport. The strategy used here is that when
      rtcp-mux is enabled, the current RTCP transport and its trappings (such
      as DTLS SSL session) are freed, and the RTCP session instead just
      mooches off the RTP session. This leads to a lot of specialized if
      statements throughout.
      
      ASTERISK-26732 #close
      Reported by Dan Jenkins
      
      Change-Id: If46a93ba1282418d2803e3fd7869374da8b77ab5
      10fa49e3
Loading