summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2016-10-20ARI: Add duplicate channel ID checking for channel creation.Mark Michelson
This is similar to what is done for origination, but for the 14 and up channel creation method. When attempting to create a channel, if a channel ID is specified and a channel already exists with that ID, then a 409 is returned. Change-Id: I77f9253278c6947939c418073b6b31065489187c
2016-10-20ARI: Detect duplicate channel IDsMark Michelson
ARI and AMI allow for an explicit channel ID to be specified when originating channels. Unfortunately, there is nothing in place to prevent someone from using the same ID for multiple channels. Further complicating things, adding ID validation to channel allocation makes it impossible for ARI to discern why channel allocation failed, resulting in a vague error code being returned. The fix for this is to institute a new method for channel errors to be discerned. The method mirrors errno, in that when an error occurs, the caller can consult the channel errno value to determine what the error was. This initial iteration of the feature only introduces "unknown" and "channel ID exists" errors. However, it's possible to add more errors as needed. ARI uses this feature to determine why channel allocation failed and can return a 409 error during origination to show that a channel with the given ID already exists. ASTERISK-26421 Change-Id: Ibba7ae68842dab6df0c2e9c45559208bc89d3d06
2016-10-20Fix issue with CLI not returning to prompt after running "features show"snuffy
ASTERISK-26444 #close Change-Id: I91d645b7e6e5dba35f8c410df2be77a8c0e3acb8
2016-10-19Merge "utils.c: Fix ast_set_default_eid for multiple platforms"zuul
2016-10-19Merge "res_rtp_asterisk: Add ice_blacklist option"zuul
2016-10-19Merge "chan_sip: Support nat=auto_comedia or nat=force_rport,auto_comedia."Joshua Colp
2016-10-19res_rtp_asterisk: Add ice_blacklist optionMichael Walton
Introduces ice_blacklist configuration in rtp.conf. Subnets listed in the form ice_blacklist = <subnet spec>, e.g. ice_blacklist = 192.168.1.0/255.255.255.0, are excluded from ICE host, srflx and relay discovery. This is useful for optimizing the ICE process where a system has multiple host address ranges and/or physical interfaces and certain of them are not expected to be used for RTP. Multiple ice_blacklist configuration lines may be used. If left unconfigured, all discovered host addresses are used, as per previous behavior. Documention in rtp.conf.sample. ASTERISK-26418 #close Change-Id: Ibee88f80d7693874fda1cceaef94a03bd86012c9
2016-10-18CDR: Alter destruction pattern for CDR chains.Mark Michelson
CDRs form chains. When the root of the chain is destroyed, it then unreferences the next CDR in the chain. That CDR is destroyed, and it then unreferences the next CDR in the chain. This repeats until the end of the chain is reached. While this typically does not cause any sort of problems, it is possible in strange scenarios for the CDR chain to grow way longer than expected. In such a scenario, the destruction pattern can result in a stack overflow. This patch fixes the problem by switching from a recursive pattern to an iterative pattern for destruction. When the root CDR is destroyed, it is responsible for iterating over the rest of the CDRs and unreferencing each one. Other CDRs in the chain, since they are not the root, will simply destroy themselves and be done. This causes the stack depth not to increase. ASTERISK-26421 #close Reported by Andrew Nagy Change-Id: I3ca90c2b8051f3b7ead2e0e43f60d2c18fb204b8
2016-10-18Merge "menuselect: invalid test for GTK2"zuul
2016-10-18Merge "cli: Auto-complete File not Module for core set debug."Joshua Colp
2016-10-18ari: Update model validator based on addition of asterisk_id.Joshua Colp
ASTERISK-26470 Change-Id: I9c386f7a1c7d969161b28f189eb6298bbc5b7541
2016-10-18Merge "Binaural synthesis (confbridge): On/off setting for binaural synthesis."Joshua Colp
2016-10-18Merge "chan_rtp: Set a sane default rtp engine for unicast."Joshua Colp
2016-10-18menuselect: invalid test for GTK2Tzafrir Cohen
configuire.ac was only checking for the existence of pkg-config and not the gtk2 package itself. Now it calls AST_PKG_CONFIG_CHECK for gtk+-2.0. ASTERISK-26356 #close Change-Id: I93e9d0166341f0e7f84b52955bb6f81da42f2ef6
2016-10-18Merge "res/ari: Add the Asterisk EID field to outgoing events"Joshua Colp
2016-10-18cli: Auto-complete File not Module for core set debug.Alexander Traud
Since Asterisk 1.8, the command "core set debug" on the command-line interface asks not for a file (.c) but a module name. This change shows modules (.so) on the auto-completion via a tabulator or the question mark. Now, when you partially type a module name, TAB or ?, you get the correct candidiates. ASTERISK-26480 Change-Id: I1213f1dd409bd4ff8de08ad80cb0c73cafb1bae0
2016-10-17Merge "app_queue: Added initialization for "context" parameter"zuul
2016-10-17Binaural synthesis (confbridge): On/off setting for binaural synthesis.frahaase
Adds setting to confbridge.conf (binaural_active) that determines if binaural synthesis can be available in bridge_softmix. ASTERISK-26292 Change-Id: I59dfcb8e55fe1df4ef32045882fea5bb58fc71db
2016-10-17pjproject_bundled: Add patch to address SSL crashGeorge Joseph
Addresses crashes when an attempt is made to operate on an SSL socket after the socket has been closed. ASTERISK-26477 #close Change-Id: I421305b357558b4f9e690210dc0f4831ef4b3002
2016-10-17app_queue: Added initialization for "context" parameterLeandro Dardini
When using Asterisk Realtime Architecture, empty fields are skipped and the default values are used. If the "context" parameter in queue was set and then cleared from the database, the old value remains in memory and it continues to be used. This change initialize the "context" parameter with an empty value, allowing clearing the parameter. ASTERISK-26462 #close Change-Id: I64be73d5044ce38dd02408bd0e53de965ef65905
2016-10-17res/ari: Add the Asterisk EID field to outgoing eventsMatt Jordan
This patch adds the Asterisk EID field to all outgoing ARI events. Because this field should be added to all events as they are transmitted, it is appended to the JSON message just prior to it being handed off to the application message handler. This makes it somewhat resilient to both new events being added to ARI, as well as other potential event transport mechanisms. ASTERISK-26470 #close Change-Id: Ieff0ecc24464e83f3f44e9c3e7bd9a5d70b87a1d
2016-10-17chan_rtp: Set a sane default rtp engine for unicast.Moises Silva
ASTERISK-26439 Change-Id: I7f5ee2eeba8906e9ecb3293dbe3a747770bb5011
2016-10-16utils.c: Fix ast_set_default_eid for multiple platformsGeorge Joseph
ast_set_default_eid was searching for ethX, emX, enoX, ensX and even pciD#U interface names. While this was a good attempt, it wasn't inclusive enough to capture interfaces like enp6s0 or ens6d1, etc. Rather than relying on interface names, we now simply find the first interface returned by the OS that has a hardware address and that address isn't all 0x00 or all 0xff. The code IS different for BSD, Solaris and Linux based on what method is available for enumerating interfaces. Tested on: FreeBSD9 CentOS6 Ubuntu14 Fedora24 I was unable to test on Solaris at this time but the code for Solaris is used elsewhere at Digium. Change-Id: Iaa6db87ca78a9a375e47d70e043ae08c1448cb72
2016-10-15chan_sip: Only send video on outgoing channel if incoming channel supports itMichael Kuron
Previously, the settings videosupport=always and videosupport=yes behaved identically and unconditionally caused a video offer to be sent in the SDP on an outgoing call. This was a regression introduced with commit 5a1d90e1fbfc4b48927aad55311f3b38efbf1f54 in Asterisk 1.6.1. This commit restores correct behavior: videosupport=always causes a video offer to be sent unconditionally, while videosupport=yes will only offer video on an outbound channel if the incoming channel it is bridged to also supports video. That way, the device receiving the outgoing call can display the correct user interface elements for audio or video and will not unnecessarily show a blank video window on an audio-only call. ASTERISK-17470 #close Change-Id: I782f4409d436114dbc97061c3570c0cd24f7c3ae
2016-10-14Merge "Fix issues with bundled pjproject cached download."zuul
2016-10-14Merge "Audit ast_json_pack() calls for needed UTF-8 checks."zuul
2016-10-14Merge "json: Check party id name, number, subaddresses for UTF-8."zuul
2016-10-14Merge "json: Add UTF-8 check call."zuul
2016-10-14Merge "res_config_mysql: Fix several issues related to recent table changes"zuul
2016-10-14Merge "aoc.c: Whitespace cleanup"zuul
2016-10-14Merge "app_queue.c: Fix clearing of pause reason string."zuul
2016-10-14Fix issues with bundled pjproject cached download.Corey Farrell
Previously when testing I had a preexisting makeopts in ASTTOPDIR. The ordering of configure.ac causes --with-externals-cache to be processed after third-party configure. In cases where the Asterisk clone is cleaned it would cause pjproject to be downloaded to /tmp. This moves processing of the externals cache and sounds cache to happen before third-party configure. This also addresses a possible issue with the third-party Makefile. If TMPDIR is set by the environment it would override the path given to --with-externals-cache. ASTERISK-26416 Change-Id: Ifab7f35bfcd5a31a31a3a4353cc26a68c8c6592d
2016-10-13Audit ast_json_pack() calls for needed UTF-8 checks.Richard Mudgett
Added needed UTF-8 checks before constructing json objects in various files for strings obtained outside the system. In this case string values from a channel driver's peer and not from the user setting channel variables. * aoc.c: Fixed type mismatch in s_to_json() for time and granularity json object construction. ASTERISK-26466 Reported by: Richard Mudgett Change-Id: Iac2d867fa598daba5c5dbc619b5464625a7f2096
2016-10-13json: Check party id name, number, subaddresses for UTF-8.Richard Mudgett
* Updated unit test as ast_json_name_number() is now NULL tolerant. ASTERISK-26466 #close Reported by: Richard Mudgett Change-Id: I7d4e14194f8f81f24a1dc34d1b8602c0950265a6
2016-10-13json: Add UTF-8 check call.Richard Mudgett
Since the json library does not make the check function public we recreate/copy the function in our interface module. ASTERISK-26466 Reported by: Richard Mudgett Change-Id: I36d3d750b6f5f1a110bc69ea92b435ecdeeb2a99
2016-10-13aoc.c: Whitespace cleanupRichard Mudgett
* In s_to_json() removed unnecessary ast_json_ref() to ast_json_null() when creating the type json object. The ref is a noop. Change-Id: I2be8b836876fc2e34a27c161f8b1c53b58a3889a
2016-10-13app_minivm.c: Fix malformed ast_json_pack() call.Richard Mudgett
Change-Id: I082b239022fac462666e52a14a44304748908dc0
2016-10-13app_queue.c: Fix clearing of pause reason string.Richard Mudgett
The pause reason is not always cleared when it should be cleared. * Made set_queue_member_pause() always clear pause reason if not pausing with a reason string. Change-Id: I993dad19626ec017478a230e980989438b778c53
2016-10-12res_config_mysql: Fix several issues related to recent table changesGeorge Joseph
Unlike any of the other database drivers, res_config_mysql checks that the table definition matches the requirements for every insert and update statement. Since all requirements are forced to 'char', any column that isn't a char, like ps_contacts' expiration_time, qualify_timeout, etc., will throw a warning. It's kinda harmless but very misleading. Since no other driver does those checks on insert or update, they've been removed from res_config_mysql. Also, all the logic that actually attempted to ALTER the table to fix the issue has been removed. With the move to alembic, the auto-alter functionality is not only unnecessary, it's also dangerous. The other issue is that res_config_mysql calls the mysql_insert_id function inside store_mysql. Presumably the intention was to return the number of rows inserted DESPITE A NOTE IN THE CODE THAT THE VALUE IS NON_PORTABLE AND MAY CHANGE. That value is then returned to config realtime as the number of rows inserted. Guess what? The value changed. It now only returns the number of rows inserted if there's an auto increment column on the table, which ps_contacts doesn't have. Otherwise it returns 0. So now, the insert worked but we tell config realtime and sorcery that no rows were inserted. That call to mysql_insert_id was removed and we now always return 1 if the insert succeeded. We're only inserting 1 row at a time anyway. If the insert fails, we still return -1. ASTERISK-26362 #close Reported-by: Carlos Chavez Change-Id: I83ce633efdb477b03c8399946994ee16fefceaf4
2016-10-12Binaural synthesis (confbridge): Adds libfftw3 as dependency.frahaase
Adds libfftw3 to the build chain that is is going to be used for binaural synthesis by bridge_softmix. ASTERISK-26292 Change-Id: Iedc2f174e4ccb39ae5d9e698e339c6a17155867b
2016-10-12Merge "Binaural synthesis (confbridge): interleaved two-channel audio."zuul
2016-10-12Merge "bundled_pjproject: Add tests for programs used by the Makefile, et al."zuul
2016-10-12res_fax: Fix a tight race condition causing fax to crash in audio fallbackTorrey Searle
When T.38 gets rejected and G711 failback occurs there is a period of time where neither AST_FAX_TECH_T38 nor AST_FAX_TECH_AUDIO is set, leading to a crash. Change-Id: Icc3f457b2292d48a9d7843dac0028347420cc982
2016-10-11Merge "Add text of cdr directory into README.md for ast-db-manage"zuul
2016-10-11Merge "res_calendar: Add support for fetching calendars when reloading"zuul
2016-10-11Merge "audiohooks: Remove redundant codec translations when using audiohooks"zuul
2016-10-11Merge "vector: After remove element recheck index"zuul
2016-10-11Merge "app_dial: Add the "Q" option to set the cause on unanswered channels"zuul
2016-10-11Merge "logger: Prevent output of verbose messages initiated from rasterisk."zuul
2016-10-11app_dial: Add the "Q" option to set the cause on unanswered channelsGeorge Joseph
The "Q" option will set the cause on the unanswered channels when another channel answers. It overrides the default of ANSWERED_ELSEWHERE. NOTE: chan_sip does not support setting the cause on a CANCEL to anything other than ANSWERED_ELSEWHERE. ASTERISK-26446 #close Change-Id: I71742e0919aaa16784c30a2b2e73fbeed7672e47