Skip to content
Snippets Groups Projects
  1. Jul 19, 2019
  2. Jul 18, 2019
    • Asterisk Development Team's avatar
    • Walter Doekes's avatar
      sched: Don't allow ast_sched_del to deadlock ast_sched_runq from same thread · 34492401
      Walter Doekes authored
      When fixing ASTERISK~24212, a change was done so a scheduled callback could not
      be removed while it was running. The caller of ast_sched_del would have to wait.
      
      However, when the caller of ast_sched_del is the callback itself (however wrong
      this might be), this new check would cause a deadlock: it would wait forever
      for itself.
      
      This changeset introduces an additional check: if ast_sched_del is called
      by the callback itself, it is immediately rejected (along with an ERROR log and
      a backtrace). Additionally, the AST_SCHED_DEL_UNREF macro is adjusted so the
      after-ast_sched_del-refcall function is only run if ast_sched_del returned
      success.
      
      This should fix the following spurious race condition found in chan_sip:
      - thread 1: schedule sip_poke_peer_now (using AST_SCHED_REPLACE)
      - thread 2: run sip_poke_peer_now
      - thread 2: blank out sched-ID (too soon!)
      - thread 1: set sched-ID (too late!)
      - thread 2: try to delete the currently running sched-ID
      
      After this fix, an ERROR would be logged, but no deadlocks (in do_monitor) nor
      excess calls to sip_unref_peer(peer) (causing double frees of rtp_instances and
      other madness) should occur.
      
      (Thanks Richard Mudgett for reviewing/improving this "scary" change.)
      
      Note that this change does not fix the observed race condition: unlocked
      access to peer->pokeexpire (and potentially other scheduled items in chan_sip),
      causing AST_SCHED_DEL_UNREF to look at a changing id. But it will make the
      deadlock go away. And in the observed case, it will not have adverse affects
      (like memory leaks) because the scheduled item is removed through a different
      path.
      
      ASTERISK-28282
      
      Change-Id: Ic26777fa0732725e6ca7010df17af77a012aa856
      34492401
  3. Jul 16, 2019
    • George Joseph's avatar
      Build: Add separate header install/uninstall targets · aaafe8a1
      George Joseph authored
      Two new Makefile targets have been added... "install-headers" and
      "uninstall-headers" to separately control header installation.
      The existing behavior has not changed so "make install" and
      "make uninstall" will continue to also install/uninstall the headers.
      The new targets were added for forward compatibility with Asterisk 17
      in which the headers are no longer installed/uninstalled with the
      "install" and "uninstall" targets.
      
      Also corrects an issue where /usr/include/asterisk.h was never
      being removed at all.
      
      Change-Id: Ia7399f3a0203a4825fc4a9f43b9034dae9a2b643
      aaafe8a1
  4. Jul 15, 2019
    • Kevin Harwell's avatar
      manager: Log AMI actions · d2eaba48
      Kevin Harwell authored
      When manager debugging is turned on, this patch makes it so incoming AMI actions
      are now also logged.
      
      Change-Id: I8047524510e7ac97d99482b2448f8e368f29cd47
      d2eaba48
  5. Jul 14, 2019
  6. Jul 11, 2019
  7. Jul 01, 2019
  8. Jun 27, 2019
  9. Jun 25, 2019
  10. Jun 24, 2019
  11. Jun 21, 2019
  12. Jun 20, 2019
    • Alexei Gradinari's avatar
      res_fax: gateway sends T.38 request to both endpoints if V.21 detected · d5db7473
      Alexei Gradinari authored
      According T.38 Gateway 'Use case 3'
      https://wiki.asterisk.org/wiki/display/AST/T.38+Gateway
      T.38 Gateway should send T.38 negotiation request to called endpoint
      if FAX preamble (using V.21 detector) generated by called endpoint.
      But it does not, because fax_gateway_detect_v21 constructs T.38
      negotiation request, but forwards it only to other channel,
      not to the channel on which FAX preamble is detected.
      
      Some SIP endpoints could be improperly configured to rely on the other side
      to initiate T.38 re-INVITEs.
      
      With this patch the T.38 Gateway tries to negotiate with both sides
      by sending T.38 negotiation request to both endpoints supported T.38.
      
      Change-Id: I73bb24799bfe1a48adae9c034a2edbae54cc2a39
      d5db7473
  13. Jun 19, 2019
    • George Joseph's avatar
      CI: New way to determnine libdir · e4ee209b
      George Joseph authored
      We were using the presence of /usr/lib64 to determine where
      shared libraries should be installed.  This only existed on
      Redhat based systems and was safe.  If it existed, use it,
      otherwise use /usr/lib.
      
      Unfortunately, Ubuntu 19 decided to create a /usr/lib64 BUT
      NOT INCLUDE IT IN THE DEFAULT ld.so.conf.  So if anything is
      installed there, it won't work.
      
      The new method, just looks for $ID in /etc/os-release and if it's
      centos or fedora, uses /usr/lib64 and if ubuntu, uses /usr/lib.
      
      NOTE:  This applies only to the CI scripts.  Normal asterisk
      build and install is not affected.
      
      Change-Id: Iad66374b550fd89349bedbbf2b93f8edd195a7c3
      e4ee209b
  14. Jun 18, 2019
    • Alexei Gradinari's avatar
      translate.c do not log WARNING on empty audio frame · 3bfe1f3a
      Alexei Gradinari authored
      There is WARNING "no samples for ..." on each Playtones.
      The function ast_playtones_start calls ast_activate_generator,
      which calls ast_prod.
      The function ast_prod calls ast_write with empty audio frame.
      In this case it's spam log.
      
      Change-Id: Id4ac309489d9ff281bad02abdef341cecdede660
      3bfe1f3a
  15. Jun 17, 2019
  16. Jun 13, 2019
    • George Joseph's avatar
      app_confbridge: Attended transfer event fixup · 41f5d157
      George Joseph authored
      When a channel already in a conference bridge is attended transfered
      to another extension, or when an existing call is attended
      transferred into a conference bridge, we now generate ConfbridgeJoin
      and ConfbridgeLeave events for the entering and departing channels.
      
      Change-Id: Id7709cfbceb26fbcb828b2d0d2a6b2fbeaf028e1
      41f5d157
    • Joshua Colp's avatar
      res_rtp_asterisk: Add support for DTLS packet fragmentation. · 1ea9bad3
      Joshua Colp authored
      This change adds support for larger TLS certificates by allowing
      OpenSSL to fragment the DTLS packets according to the configured
      MTU. By default this is set to 1200.
      
      This is accomplished by implementing our own BIO method that
      supports MTU querying. The configured MTU is returned to OpenSSL
      which fragments the packet accordingly. When a packet is to be
      sent it is done directly out the RTP instance.
      
      ASTERISK-28018
      
      Change-Id: If2d5032019a28ffd48f43e9e93ed71dbdbf39c06
      1ea9bad3
  17. Jun 12, 2019
Loading