Commit Graph

7894 Commits

Author SHA1 Message Date
Richard Mudgett 3ccd5dee18 udptl: Dead code elimination. ast_udptl_bridge was not used.
Removing dead code starting with ast_udptl_bridge() eliminated the code in
this change.

Note: This code has actually been dead since Asterisk v1.4 when it was
first put in.

Review: https://reviewboard.asterisk.org/r/3079/
........

Merged revisions 404354 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404355 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-19 17:13:53 +00:00
Richard Mudgett e4803bbd9e Voicemail: Remove mailbox identifier format (box@context) assumptions in the system.
This change is in preparation for external MWI support.

Removed code from the system for normal mailbox handling that appends
@default to the mailbox identifier if it does not have a context.  The
only exception is the legacy hasvoicemail users.conf option.  The legacy
option will only work for app_voicemail mailboxes.  The system cannot make
any assumptions about the format of the mailbox identifer used by
app_voicemail.

chan_sip and chan_dahdi/sig_pri had the most changes because they both
tried to interpret the mailbox identifier.  chan_sip just stored and
compared the two components.  chan_dahdi actually used the box
information.

The ISDN MWI support configuration options had to be reworked because
chan_dahdi was parsing the box@context format to get the box number.  As a
result the mwi_vm_boxes chan_dahdi.conf option was added and is documented
in the chan_dahdi.conf.sample file.

Review: https://reviewboard.asterisk.org/r/3072/
........

Merged revisions 404348 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404350 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-19 16:52:43 +00:00
Damien Wedhorn c2fd229fba Fixup some skinny bugs causing Fracks and ao2 cleanup issues.
Moved channel locking into setsubstate so that a process can complete
working on a sub before another starts changing it. The existing code
was causing some Fracks with schedule deletion.

Removed multiple rtp cleanup. Now only cleansup up once, fixing ao2 
object cleanup issues.
........

Merged revisions 404306 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404307 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-19 02:59:52 +00:00
Damien Wedhorn af723c6572 Fixup skinny registration following network issues.
On session registration, if device is already reporting that it is
connected to a device, an innocuous packet (update time) is sent to
the already connected device. If the tcp connection is down, the
device will be unregistered and the new connection allowed.

Without this patch, network issues can see a situation where a device
can not reregister until after 3*timeout.
........

Merged revisions 404292 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404293 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-19 00:32:00 +00:00
Kevin Harwell ed0c493222 chan_oss.c: channel being locked twice and unlocked once
Removed channel lock as it is now being down in ast_channel_alloc
........

Merged revisions 404261 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404262 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-18 20:48:49 +00:00
Kevin Harwell 28c0cb28d0 channel locking: Add locking for channel snapshot creation
Original commit message by mmichelson (asterisk 12 r403311):

"This adds channel locks around calls to create channel snapshots as well
as other functions which operate on a channel and then end up
creating a channel snapshot. Functions that expect the channel to be
locked prior to being called have had their documentation updated to
indicate such."

The above was initially committed and then reverted at r403398.  The problem
was found to be in core_local.c in the publish_local_bridge_message function.
The ast_unreal_lock_all function locks and adds a reference to the returned
channels and while they were being unlocked they were not being unreffed when
no longer needed.  Fixed by unreffing the channels.

Also in bridge.c a lock was obtained on "other->chan", but then an attempt was
made to unlock "other" and not the previously locked channel.  Fixed by
unlocking "other->chan"

(closes issue ASTERISK-22709)
Reported by: John Bigelow
........

Merged revisions 404237 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404260 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-18 20:33:37 +00:00
Joshua Colp e2630fcd51 channels: Return allocated channels locked.
This change makes ast_channel_alloc return allocated channels
locked. By doing so no other thread can acquire, lock, and manipulate
the channel before it is completely set up.

(closes issue AST-1256)

Review: https://reviewboard.asterisk.org/r/3067/
........

Merged revisions 404204 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404210 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-18 19:28:05 +00:00
Rusty Newton f7c60b8fb6 Several components: fixing Typos in comments and code, "avaliable" instead of "available"
(issue ASTERISK-23021)
(closes issue ASTERISK-23021)
Reported by: Jeremy Lainé
Tested by: Rusty Newton
Patches:
   available.patch uploaded by Jeremy Lainé (license 6561)
........

Merged revisions 404046 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404047 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-17 23:38:02 +00:00
Matthew Jordan 4ddf45fd24 pjsip/dialplan_functions: Use the right buffer length when printing URIs
While entertaining, sizeof(buflen) is not the same as buflen. Doh.
........

Merged revisions 403823 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@403824 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-15 01:39:20 +00:00
Kevin Harwell 84e1790beb bridge_native_rtp: Deadlock during 4-way conference creation
The change contains a slightly adjusted patch that was on the issue
(submitted by kmoore).  A fix was made by adding in a bridge lock
while calling bridge_start/stop from the framehook callback.  Since
the framehook callback is not called from the bridging core the bridge
is not locked, but needs to be before calling bridge_start.

(closes issue ASTERISK-22749)
Reported by: Kinsey Moore
Review: https://reviewboard.asterisk.org/r/3066/
Patches:
     lock_inversion.diff uploaded by kmoore (license 6273)
........

Merged revisions 403767 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@403768 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-13 18:33:25 +00:00
Matthew Jordan fc8c0ef28f channels/Makefile: clean pjsip directory
........

Merged revisions 403736 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@403737 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-13 05:00:53 +00:00
Jonathan Rose 5583d2c629 chan_pjsip: Revert r403587
This patch was intended to eliminate a deadlock that occurs when
masquerades occur in pjsip channels, but has some potential side
effects. Mark Michelson is currently working on addressing this
problem from another angle.

(issue ASTERISK-22936)
Reported by: Jonathan Rose
........

Merged revisions 403705 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@403707 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-12 19:18:06 +00:00
Russell Bryant 90108b15a0 Reset peer outboundproxy on sip.conf reload
If you set a peer's outboundproxy and then removed it from the config,
this would not get picked up in a config reload.  This patch fixes that
by resetting it in set_peer_defaults().

Closes ASTERISK-19454
Review: https://reviewboard.asterisk.org/r/3065/
........

Merged revisions 403634 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 403635 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 403639 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@403652 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-11 19:22:05 +00:00
Matthew Jordan ce423d2ea4 func_channel, chan_pjsip: Add CHANNEL read function support for chan_pjsip
This patch adds CHANNEL read support for chan_pjsip. This allows the dialplan
to use the CHANNEL function on a chan_pjsip channel to obtain run-time
information about the channel from the PJSIP channel driver and the PJSIP
stack. This includes:
 * RTP information, including source/destination media addresses, whether or
   not the media is secure, held, and other properties.
 * RTCP information. This includes sets of parseable information, as well as
   individual statistic attriutes.
 * PJSIP information. This includes URIs, local/remote signalling addresses,
   whether or not the signalling is secure, and other properties.
 * The endpoint name. This can be used in conjunction with the PJSIP_ENDPOINT
   function to obtain more detailed endpoint information.

Review: https://reviewboard.asterisk.org/r/3038/
........

Merged revisions 403618 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@403619 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-11 13:06:30 +00:00
Jonathan Rose 905a7de52b chan_pjsip: Fix a sticking channel lock caused by channel masquerades
(closes issue ASTERISK-22936)
Reported by: Jonathan Rose
Review: https://reviewboard.asterisk.org/r/3042/
........

Merged revisions 403587 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@403588 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-09 22:59:14 +00:00
David M. Lee 1212906351 Reverting r403311. It's causing ARI tests to hang.
........

Merged revisions 403398 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@403404 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-05 22:10:20 +00:00
Mark Michelson 8e8b329e14 Add channel locking for channel snapshot creation.
This adds channel locks around calls to create channel snapshots as well
as other functions which operate on a channel and then end up
creating a channel snapshot. Functions that expect the channel to be
locked prior to being called have had their documentation updated to
indicate such.
........

Merged revisions 403311 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@403314 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-12-03 17:07:29 +00:00
Kinsey Moore 95bc7626aa chan_dahdi: Fix crash during caller ID read
Asterisk will sometimes core dump during caller id read on analog
channels due to a negative return value from the read() in
my_get_callerid that slips through as a negative length argument to
callerid_feed() if the errno returned by DAHDI is ELAST. This change
ensures that the negative return is treated properly even when it is
ELAST.

(closes issue ASTERISK-22746)
Reported by: Michael Walton
Patches:
    chan_dahdi_cid_crash_fix.r401410.patch uploaded by Michael Walton (License 6502)
........

Merged revisions 402708 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 402709 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 402710 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@402711 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-11-12 15:03:18 +00:00
Scott Griepentrog 094db82a73 chan_sip: keep same local (from) tag for outgoing register requests
For outbound register requests the tag on the From line was
updated every 20 seconds prior to a successful registration
and also once for each registration renewal.  That behavior
can possibly cause the registration to be denied because of
the different tag, and is not aligned with the intention of
RFC 3261 8.1.3.5 "... request constitutes a new transaction
and SHOULD have the same value of the Call-ID, To, and From
of the previous request...".  This updates chan_sip to have
a field to keep the local tag in the registration structure
and use that tag for registration requests where the callid
is also unchanged.

(closes issue ASTERISK-12117)
Reported by: Pawel Pierscionek
Review: https://reviewboard.asterisk.org/r/2988/
........

Merged revisions 402604 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 402605 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 402606 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@402607 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-11-08 23:07:50 +00:00
Matthew Jordan 029ce1e962 chan_sip: Use AST_AF* defined constant when calling ast_get_ip
While the structure passed to ast_get_ip should be set memset to 0, thus
initializing the ss_family member to 0, explicitly setting it to AST_AF_UNSPEC
is more portable.
........

Merged revisions 402507 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@402508 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-11-05 21:17:30 +00:00
Matthew Jordan f6bd22b0fd chan_iax2: Fix incorrect usage of ast_get_ip involving uninitialized struct
This started off as a fix for the failing IAX2 acl_call test in the Asterisk
Test Suite. When inspecting why that test was failing, it became clear that all
attempts to bind to any local loopback address was failing:

[Nov  2 15:56:28] VERBOSE[15787] chan_iax2.c:   == Binding IAX2 to address
                                 127.0.0.1:4569
[Nov  2 15:56:28] DEBUG[15787] netsock2.c: Splitting '127.0.0.1' into...
[Nov  2 15:56:28] DEBUG[15787] netsock2.c: ...host '127.0.0.1' and port ''.
[Nov  2 15:56:28] ERROR[15787] netsock2.c: getaddrinfo("127.0.0.1", "(null)",
                               ...): ai_family not supported
[Nov  2 15:56:28] WARNING[15787] acl.c: Unable to lookup '127.0.0.1'

While there's conceivably other ways for getaddrino to return EAI_FAMILY, the
most common way is if AF_INET, AF_INET6, or AF_UNSPEC is not provided as the
desired family. The culprit was the call to ast_get_ip, defined in acl.h. This
function uses the family from the passed in addr object (which it will also
populate when it returns!) when it eventually calls getaddrinfo.

This patch fixes the use of ast_get_ip that were not specifying the family in
chan_iax2. This prevents uninitialized use of the structure, so that the
addresses resolve correctly.

Review: https://reviewboard.asterisk.org/r/2991
........

Merged revisions 402505 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@402506 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-11-05 21:14:42 +00:00
Kevin Harwell fe47684b43 chan_sip: notify dialog info ignores presentation indicator in callerid
The presentation indicator in a callerid (e.g. set by dialplan function
Set(CALLERID(name-pres)= ...)) is not checked when SIP Dialog Info Notifies
are generated during extension monitoring.  Added a check to make sure the
name and/or number presentations on the callee (remote identity) are set to
allow.  If they are restricted then "anonymous" is used instead.

(closes issue AST-1175)
Reported by: Thomas Arimont
Review: https://reviewboard.asterisk.org/r/2976/
........

Merged revisions 402450 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 402452 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@402453 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-11-04 21:02:18 +00:00
Kinsey Moore 98dea21bc1 chan_sip: Fix RTCP port for SRFLX ICE candidates
This corrects one-way audio between Asterisk and Chrome/jssip as a
result of Asterisk inserting the incorrect RTCP port into RTCP SRFLX
ICE candidates. This also exposes an ICE component enumeration to
extract further details from candidates.

(closes issue ASTERISK-21383)
Reported by: Shaun Clark
Review: https://reviewboard.asterisk.org/r/2967/
........

Merged revisions 402345 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 402348 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@402349 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-11-01 12:40:40 +00:00
Kevin Harwell 4746c068dc pjsip_messaging: Added debug for in dialog messaging
(issue ASTERISK-22777)
Reported by: Matt Jordan
........

Merged revisions 402265 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@402266 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-30 17:54:26 +00:00
Michael L. Young 230141d677 chan_sip: Clarify 'Forcerport' Setting Displayed When Running "sip show peers"
While looking at ASTERISK-22236, Walter Doekes pointed out that when running
"sip show peers", the setting being displayed can be confusing.  The display of
"N" used to mean NAT (i.e. yes).  The NAT setting has gone through many
different changes resulting in the display of different characters to try and
convey what the current setting is for 'Forcerport' (A for Auto and Forcerport
is currently on, a for Auto but Forcerport is off, Y for yes, and N for no).
During the initial code review to try and clarify these settings (especially
since "N" no longer meant what it used to mean in prior versions of Asterisk),
Mark Michelson suggested using the full space available to display the settings
which helped to make the settings very clear.  That was a great suggestion.

Therefore, this patch does the following:

* The column for 'Forcerport' now will show: Auto (Yes), Auto (No), Yes, or No.

* A column for the 'Comedia' setting has been added.  It too will display the
  setting in a non-cryptic way: Auto (Yes), Auto (No), Yes, or No.

* UPGRADE.txt has been updated to document this change.

(closes issue ASTERISK-22728)
Reported by: Walter Doekes
Tested by: Michael L. Young
Patches:
    asterisk-forcerport-display-clarification_v3.diff
                                     uploaded by Michael L. Young (license 5026)

Review: https://reviewboard.asterisk.org/r/2941
........

Merged revisions 402111 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 402112 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@402113 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-28 14:59:16 +00:00
Joshua Colp 26914adc00 chan_pjsip: Fix a crash when direct media is enabled and an ACK is received after the channel is hung up.
(closes issue ASTERISK-22731)
Reported by: Kinsey Moore
........

Merged revisions 402064 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@402065 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-26 12:56:08 +00:00
Kevin Harwell 9ba7742431 chan_sip: Allow a sip peer to accept both AVP and AVPF calls
Adapts the behaviour of avpf to only impact the format of outgoing calls. For
inbound calls, both AVP and AVPF calls will be accepted regardless of the value
of avpf in the configuration.

(closes issue ASTERISK-22005)
Reported by: Torrey Searle
Patches:
     optional_avpf_trunk.patch uploaded by tsearle (license 5334)
........

Merged revisions 401884 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 401885 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@401886 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-25 16:09:05 +00:00
Jonathan Rose 4ca0f222e8 memory leaks: Memory leak cleanup patch by Corey Farrell (second set)
Also covers ast_app_parse_timelen-fail-zero-length.patch, but the patch was
replaced with one of my own.

(issue ASTERISK-22467)
Reported by: Corey Farrell
Patches:
    chan_dahdi-cleanup_push.patch uploaded by coreyfarrell (license 5909)
    clicompat-r2.patch uploaded by coreyfarrell (license 5909)
    codecs-ilbc-doCPLC.patch uploaded by coreyfarrell (license 5909)
    data-cleanup-test-registration.patch uploaded by coreyfarrell (license 5909)
    main-asterisk-kill-listener.patch uploaded by coreyfarrell (license 5909)
........

Merged revisions 401704 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 401705 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 401706 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@401707 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-24 17:00:27 +00:00
Jonathan Rose beb5cdbef5 memory leaks: Memory leak cleanup patch by Corey Farrell (first set)
(issue ASTERSIK-22467)
Reported by: Corey Farrell
Patches:
    chan_sip-parse_contact_header_test-free-contacts.patch uploaded by coreyfarrell (license 5909)
    cli-filename-completion-leak.patch uploaded by coreyfarrell (license 5909)
    func_math.patch uploaded by corefarrell (license 5909)
    main-test-cleanup.patch uploaded by coreyfarrell (license 5909)
    test_dlinklists.patch uploaded by coreyfarrell (license 5909)
........

Merged revisions 401660 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 401661 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 401662 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@401663 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-23 20:10:30 +00:00
Kinsey Moore dfd3f4ef46 chan_mgcp: Properly handle malformed media lines
This corrects a situation in which a media line was not parsed properly
and resulted in a crash.

(closes issue ASTERISK-21190)
Reported by: adomjan
Patches:
    chan_mgcp.c-sscnaf_fix uploaded by adomjan (License 5448)
........

Merged revisions 401537 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 401538 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 401539 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@401540 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-23 15:23:58 +00:00
Joshua Colp f4e028a765 chan_sip: Fix an issue where an incompatible audio format may be added to SDP.
If preferred codecs included any non-audio format the code would
mistakenly add the audio format, even if it was not a joint capability
with the remote side.

(closes issue ASTERISK-21131)
Reported by: nbougues
Patches:
	patch_unsupported_codec_1.8.patch uploaded by nbougues (license 6470)
........

Merged revisions 401497 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 401498 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 401499 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@401500 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-23 11:16:44 +00:00
Michael L. Young 4ca92e3b8a chan_iax2: Fix Binding To Multiple Addresses Again
When reworking chan_iax2 for IPv6, the ability to bind to multiple addresses
was removed by mistake.  This patch restores this functionality and adds notes
about IPv6 addresses in the sample config.

(closes issue ASTERISK-22741)
Reported by: Joshua Colp
Tested by: Michael L. Young
Patches:
    asterisk-22741-fix-binding-multiple-addr.diff
                                     uploaded by Michael L. Young (license 5026)

Review: https://reviewboard.asterisk.org/r/2945/
........

Merged revisions 401488 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@401489 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-23 02:36:01 +00:00
Kinsey Moore 3407f27c88 Fix IAX2 incoming call address lookups
This fixes address lookup for incoming calls without a peer definition.
The address family was unset instead of being set to AST_AF_UNSPEC
which was causing lookup failures on "127.0.0.1". This is one of the
causes of the current failure of the app_page integration test.

Review: https://reviewboard.asterisk.org/r/2933/
........

Merged revisions 401291 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@401292 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-19 21:57:07 +00:00
Michael L. Young 32d758ed32 Remove Port Restriction When Checking For NAT
When trying to determine if a peer is behind NAT, we should not be using the
ports when comparing addresses.

This patch removes the port from being checked and just useds the addresses
now.

(closes issue ASTERISK-22729)
Reported by: Michael L. Young
Tested by: Michael L. Young
Patches:
    asterisk-remove-using-port-for-nat-check.diff
                                     uploaded by Michael L. Young (license 5026)

Review: https://reviewboard.asterisk.org/r/2927/
........

Merged revisions 401182 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 401183 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@401184 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-18 15:14:36 +00:00
Michael L. Young 42f3cae1fd Fix Setting A chan_sip Dialog's SIP_NAT_FORCE_RPORT Flag
A condition was added in a commit to fix ASTERISK-21374, that, if the
SIP_PAGE3_NAT_AUTO_RPORT flag was set, to then copy a peer's SIP_NAT_FORCE_RPORT
flag to the dialog.  This condition should not have been there since it assumed
that if Asterisk is in an environment where NAT is involved, that the auto_* nat
settings or force_rport setting would be on in the global settings.  If the nat
setting in the global setting is set to 'nat=no' and then turned on for peers
(which is not quite the recommended way, although it is allowed) this flag is
never copied to the dialog resulting in problems like, REGISTER replies going
to the wrong port.

This patch removes this conditional check and will now always use the peer's
flag which by this point in the code the checks on whether the peer is behind
NAT or not (if using auto_force_rport) have already been run.

(closes issue ASTERISK-22236)
Reported by: Filip Frank
Tested by: Michael L. Young
Patches:
    asterisk-2236-always-set-rport.diff uploaded
                                              by Michael L. Young (license 5026)

Review: https://reviewboard.asterisk.org/r/2919/
........

Merged revisions 401167 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 401168 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@401169 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-17 20:39:29 +00:00
Richard Mudgett 66e7dc041d bridge_native_dahdi: Return channel join failure if could not make the channels compatible.
........

Merged revisions 401030 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@401031 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-15 20:26:13 +00:00
Richard Mudgett 3208058831 chan_iax2: Fix channel left locked in off nominal code path.
........

Merged revisions 401016 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 401017 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@401020 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-15 20:05:47 +00:00
Mark Michelson 2c927b871f Prevent chan_sip from sending duplicate BYEs.
When a 200 OK for an initial INVITE is received, we were doing
the right thing by ACKing and sending an immediate BYE. However,
we also were doing the wrong thing and queuing an answer frame,
thus causing the call to be answered. This would cause the call
to be hung up by the channel thread, thus resulting in a second
BYE being sent out.

In this fix, I also have set the hangupcause to be correct since
the initial BYE being sent by Asterisk had an unknown hangup
cause. I have changed to using "Bearer capabilty not available"
since the call was hung up due to an SDP offer/answer error.

(closes issue ASTERISK-22621)
reported by Kinsey Moore
........

Merged revisions 400970 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 400971 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 400984 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400998 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-15 15:26:06 +00:00
Richard Mudgett 2127848d6c chan_dahdi: Add config support for hwgain settings.
* Add hwtxgain and hwrxgain config options to chan_dahdi.conf with
documentation in chan_dahdi.conf.sample.

(closes issue ASTERISK-22429)
Reported by: Jaco Kroon
Patches:
      jira_asterisk_22429_hwgain_trunk.patch (license #5621) patch uploaded by rmudgett


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400950 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-14 22:52:42 +00:00
Richard Mudgett edb437ee6c chan_dahdi: Reflect the set software gain in the CLI "dahdi show channel" output.
* Remember the swgain setting from CLI "dahdi set swgain" command so the
CLI "dahdi show channel" output will reflect the current setting.

* Updated CLI "dahdi set hwgain" and "dahdi set swgain" documentation.

(issue ASTERISK-22429)
Reported by: Jaco Kroon
Patches:
      jira_asterisk_22429_v1.8_v2.patch (license #5621) patch uploaded by rmudgett
........

Merged revisions 400907 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 400909 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 400911 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400913 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-14 22:06:01 +00:00
Mark Michelson 47e910bfe6 chan_sip: Do not increment the SDP version between 183 and 200 responses.
Bumping the SDP version number can cause interoperability problems
since receivers of the responses will expect that a 200 SDP will
be identical to a previous 183 SDP.

(closes issue ASTERISK-21204)
reported by NITESH BANSAL

Patches:
	dont-increment-session-version-in-2xx-after-183.patch uploaded by NITESH BANSAL (License #6418)
........

Merged revisions 400906 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 400908 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 400910 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400912 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-14 22:03:22 +00:00
Richard Mudgett e2a0a6ed19 chan_iax2: Fix compile error.
........

Merged revisions 400588 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400593 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-05 00:59:17 +00:00
Michael L. Young 2af53640c8 Add IPv6 Support To chan_iax2
This patch adds IPv6 support to chan_iax2.  Yay!

(closes issue ASTERISK-22025)
Patches:
  iax2-ipv6-v5-reviewboard.diff by Michael L. Young (license 5026)

Review: https://reviewboard.asterisk.org/r/2660/
........

Merged revisions 400567 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400568 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-04 21:41:58 +00:00
Jonathan Rose d35b5c9cb0 chan_sip: Don't ignore expires value in contact header if it lacks semicolon
(closes issue ASTERISK-22574)
Reported by: Filip Jenicek
Patches:
    chan_sip_expires.patch uploaded by Filip Jenicek (license 6277)
........

Merged revisions 400469 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 400470 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 400471 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400482 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-03 23:20:00 +00:00
Richard Mudgett e3d69a5628 chan_vpb: Make compile again.
........

Merged revisions 400373 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400374 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-03 16:28:35 +00:00
Mark Michelson ee21eee7e0 Cache string values of formats on ast_format_cap() to save processing.
Channel snapshots have string representations of the channel's native formats.
Prior to this change, the format strings were re-created on ever channel snapshot
creation. Since channel native formats rarely change, this was very wasteful.
Now, string representations of formats may optionally be stored on the ast_format_cap
for cases where string representations may be requested frequently. When formats
are altered, the string cache is marked as invalid. When strings are requested, the
cache validity is checked. If the cache is valid, then the cached strings are copied.
If the cache is invalid, then the string cache is rebuilt and copied, and the cache
is marked as being valid again.

Review: https://reviewboard.asterisk.org/r/2879
........

Merged revisions 400356 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400363 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-03 14:58:16 +00:00
Mark Michelson addbf276f5 Multiple revisions 400318-400319
........
  r400318 | mmichelson | 2013-10-02 17:08:49 -0500 (Wed, 02 Oct 2013) | 12 lines
  
  Remove unnecessary waits from stasis.
  
  Since caches are updated on publisher threads, there is no need
  to wait for the cache updates to occur after a stasis message
  is published.
  
  In the case of chan_pjsip device state changes, this set of
  changes caused an improvement to performance.
  
  Review: https://reviewboard.asterisk.org/r/2890
........
  r400319 | mmichelson | 2013-10-02 17:10:54 -0500 (Wed, 02 Oct 2013) | 3 lines
  
  Remove svn:mergeinfo property.
........

Merged revisions 400318-400319 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400335 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-02 22:22:17 +00:00
Michael L. Young e4ed9886e6 Cast Integer Argument To Unsigned Char
The member reg in the peercnt structure is an unsigned char and peercnt_modify()
is expecting an unsigned char argument which gets assigned to peercnt->reg.

This patch fixes that by casting the integer argument being passed to
peercnt_modify to unsigned char.
........

Merged revisions 400314 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 400315 from http://svn.asterisk.org/svn/asterisk/branches/11
........

Merged revisions 400316 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400317 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-02 21:33:42 +00:00
Richard Mudgett d14869bcad sig_ss7: Fix compiler warnings.
........

Merged revisions 400268 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400269 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-02 17:10:39 +00:00
Joshua Colp c1235f2639 Reduce channel snapshot creation and publishing by up to 50%.
This change introduces the ability to stage channel snapshot
creation and publishing by suppressing the implicit creation
and publishing that some functions have. Once all operations
are executed the staging is marked as done and a single snapshot
is created and published.

Review: https://reviewboard.asterisk.org/r/2889/
........

Merged revisions 400265 from http://svn.asterisk.org/svn/asterisk/branches/12


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@400266 65c4cc65-6c06-0410-ace0-fbb531ad65f3
2013-10-02 16:23:34 +00:00