Skip to content
Snippets Groups Projects
  1. Sep 11, 2015
    • Rodrigo Ramírez Norambuena's avatar
      chan_sip.c: Validation on module reload · 865377fc
      Rodrigo Ramírez Norambuena authored
      Change validation on reload module because now used the cli function for
      reload. The sip_reload() function never fail and ever return NULL for this
      reason on reload() now use the call the sip_reload() and return
      AST_MODULE_LOAD_SUCCESS.
      
      This problem is dectected on reload by PUT method on ARI, getting always
      404 http code when the module is reloaded.
      
      ASTERISK-25325 #close
      Reporte by: Rodrigo Ramírez Norambuena
      
      Change-Id: I41215877fb2cfc589e0d4d464000cf6825f4d7fb
      865377fc
  2. Sep 10, 2015
  3. Sep 09, 2015
  4. Sep 08, 2015
  5. Sep 07, 2015
    • Alexander Anikin's avatar
      chan_ooh323: call ast_rtp_instance_stop on ooh323_destroy · 480c443e
      Alexander Anikin authored
          Call ast_rtp_instance_stop on ooh323_destroy to free resources
          allocated by rtp instance
      
          ASTERISK-25299 #close
          Report by: Alexandr Dranchuk
      
      Change-Id: I455096bd7da016b871afe90af86067c2c7c9f33f
      480c443e
    • Matt Jordan's avatar
      res/res_pjsip: Purge contacts when an AoR is deleted · c3e6debd
      Matt Jordan authored
      When an AoR is deleted by an external mechanism, such as through ARI, we
      currently do not remove dynamic contacts that were created for that AoR as a
      result of a received REGISTER request. As a result, re-creating the AoR will
      cause the dynamic contact to be interpreted as a persistent contact, leading
      to some rather strange state being created for the contacts/endpoints.
      
      This patch adds a sorcery observer for the 'aor' object. When a delete is
      issued on the underlying sorcery object, the observer is called, and all
      contacts created and persisted in sorcery for that AoR are also removed. Note
      that we don't want to perform this action when an AO2 object that is an AoR is
      destroyed, as the AoR can still exist in the backing storage (and we would
      thus be removing valid contacts from an AoR that still "exists".)
      
      ASTERISK-25381 #close
      
      Change-Id: I6697e51ef6b2858b5d63401f35dc378bb0f90328
      c3e6debd
  6. Sep 05, 2015
  7. Sep 04, 2015
    • David M. Lee's avatar
      Fix when remote candidates exceed PJ_ICE_MAX_CAND · 61c6c6aa
      David M. Lee authored
      We were passing the wrong count into pj_ice_sess_create_check_list(),
      causing the create to fail if we ever received more than PJ_ICE_MAX_CAND
      candidates.
      
      Change-Id: I0303d8e1ecb20a8de9fe629a3209d216c4028378
      61c6c6aa
    • Mark Michelson's avatar
      res_pjsip: Change default from user value. · ac62928d
      Mark Michelson authored
      When Asterisk sends an outbound SIP request, if there is no direct
      reason to place a specific value for the username in the From header,
      Asterisk would generate a UUID. For example, this would happen when
      sending outbound OPTIONS requests when qualifying or when sending
      outbound INVITE requests when originating (if no explicit caller ID were
      provided). The issue is that some SIP providers reject these sorts of
      requests with a "Name too long" error response.
      
      This patch aims to fix this by changing the default outbound username in
      From headers to "asterisk". This value can be overridden by changing the
      default_from_user option in the global options if desired.
      
      ASTERISK-25377 #close
      Reported by Mark Michelson
      
      Change-Id: I6a4d34a56ff73ff4f661b0075aeba5461b7f3190
      ac62928d
    • Scott Griepentrog's avatar
      endpoint snapshot: avoid second cleanup on alloc failure · 6002472a
      Scott Griepentrog authored
      In ast_endpoint_snapshot_create(), a failure to init the
      string fields results in two attempts to ao2_cleanup the
      same pointer.  Removed RAII_VAR to eliminate problem.
      
      ASTERISK-25375 #close
      Reported by: Scott Griepentrog
      
      Change-Id: If4d9dfb1bbe3836b623642ec690b6d49b25e8979
      6002472a
    • Martin Tomec's avatar
      res/pjsip: Mark WSS transport as secure · d32e516c
      Martin Tomec authored
      Pjsip is refusing to use unsecure transport with "sips" in url.
      WSS should be considered as secure transport.
      
      ASTERISK-24602 #comment Partially fixed by setting WSS as secure
      
      Change-Id: Iddac406c6deba6240c41a603b8859dfefe1a5353
      d32e516c
  8. Sep 02, 2015
    • Joshua Colp's avatar
    • Mark Michelson's avatar
      res_pjsip: Fix contact refleak on stateful responses. · ad9cb6c2
      Mark Michelson authored
      When sending a stateful response, creation of the transaction can fail,
      most commonly because we are trying to create a transaction from a
      retransmitted request. When creation of the transaction fails, we end up
      leaking a reference to a contact that was bumped when the response was
      created.
      
      This patch adds the missing deref and fixes the reference leak.
      
      Change-Id: I2f97ad512aeb1b17e87ca29ae0abacb4d6395f07
      ad9cb6c2
    • Joshua Colp's avatar
      pbx: Fix crash when issuing "core show hints" with long pattern match. · cc136320
      Joshua Colp authored
      When issuing the "core show hints" CLI command a combination of both
      the hint extension and context is created. This uses a fixed size
      buffer expecting that the extension will not exceed maximum extension
      length. When the extension is actually a pattern match this constraint
      does not hold true, and the extension may exceed the maximum extension
      length. In this case extra characters are written past the end of the
      fixed size buffer.
      
      This change makes it so the construction of the combined hint extension
      and context can not exceed the size of the buffer.
      
      ASTERISK-25367 #close
      
      Change-Id: Idfa1b95d0d4dc38e675be7c1de8900b3f981f499
      cc136320
  9. Sep 01, 2015
    • Mark Michelson's avatar
      res_pjsip_pubsub: re-re-fix persistent subscription storage. · d58c8d73
      Mark Michelson authored
      A recent change to res_pjsip_pubsub switched to using pjsip_msg_print as
      a means of writing an appropriate packet to persistent storage. While
      this partially solved the issue, it had its own problems.
      pjsip_msg_print will always add a Content-Length header to the message
      it prints. Frequent restarts of Asterisk can result in persistent
      subscriptions being written with five or more Content-Length headers. In
      addition, sometimes some apparent corruption of individual headers could
      be seen.
      
      This aims to fix the problem by not running a parsed message through an
      interpreter but rather by taking the raw message and saving it. The
      logic for what to save is going to be different depending on whether a
      SUBSCRIBE was received from the wire or if it was pulled from
      persistence. When receiving a packet from the wire, when using a
      streaming transport, the rdata->pkt_info.packet may contain multiple SIP
      messages or fragments. However, the rdata->msg_info.msg_buf will always
      contain the current SIP message to be processed. When pulling from
      persistence, though, the rdata->msg_info.msg_buf will be NULL since no
      transport actually handled the packet. However, since we know that we
      will always ever pull one SIP message from persistence, we are free to
      save directly from rdata->pkt_info.packet instead.
      
      ASTERISK-25365 #close
      Reported by Mark Michelson
      
      Change-Id: I33153b10d0b4dc8e3801aaaee2f48173b867855b
      d58c8d73
  10. Aug 31, 2015
    • Joshua Colp's avatar
    • Mark Michelson's avatar
      Fix deadlock on presence state changes. · 03fe79f2
      Mark Michelson authored
      A deadlock was observed where three threads were competing for different
      locks:
      
      * One thread held the hints lock and was attempting to lock a specific
        hint.
      * One thread was holding the specific hint's lock and was attempting to
        lock the contexts lock
      * One thread was holding the contexts lock and attempting to lock the
        hints lock.
      
      Clearly the second thread was doing the wrong thing here. The fix for
      this is to make sure that the hint's lock is not held on presence state
      changes. Something similar is already done (and commented about) for
      device state changes.
      
      ASTERISK-25362 #close
      Reported by Mark Michelson
      
      Change-Id: I15ec2416b92978a4c0c08273b2d46cb21aff97e2
      03fe79f2
  11. Aug 29, 2015
Loading