- May 08, 2023
-
-
Naveen Albert authored
Currently, both pulse and tone dialing are always enabled on all FXS lines, with no way of disabling one or the other. In some circumstances, it is desirable or necessary to disable one of these, and this behavior can be problematic. A new "dialmode" option is added which allows setting the methods to support on a per channel basis for FXS (FXO signalled lines). The four options are "both", "pulse", "dtmf"/"tone", and "none". Additionally, integration with the CHANNEL function is added so that this setting can be updated for a channel during a call. Resolves: #35 ASTERISK-29992 UserNote: A "dialmode" option has been added which allows specifying, on a per-channel basis, what methods of subscriber dialing (pulse and/or tone) are permitted. Additionally, this can be changed on a channel at any point during a call using the CHANNEL function. (cherry picked from commit 82d7bb49ddc15cff5ea2e50f5ee6934102fe13d1)
-
- Feb 28, 2023
-
-
Naveen Albert authored
ASTERISK_29392 (a security fix) introduced a regression by not processing frames when we don't have an audio format. Currently, chan_iax2 only calls jb_get to read frames from the jitterbuffer when the voiceformat has been set on the pvt. However, this only happens when we receive a voice frame, which means that prior to receiving voice frames, other types of frames get stalled completely in the jitterbuffer. To fix this, we now fallback to using the format negotiated during call setup until we've actually received a voice frame with a format. This ensures we're always able to read from the jitterbuffer. ASTERISK-30354 #close ASTERISK-30162 #close Change-Id: Ie4fd1e8e088a145ad89e0427c2100a530e964fe9
-
- Jan 10, 2023
-
-
Igor Goncharovsky authored
Add ability to set HANGUPCAUSE when SIP causecode received in BYE (in addition to currently supported Q.850). ASTERISK-30319 #close Change-Id: I3f55622dc680ce713a2ffb5a458ef5dd39fcf645
-
- Jan 09, 2023
-
-
George Joseph authored
----------------- This commit reinstates MES with some casting fixes to the functions in time.h that convert between doubles and timeval structures. The casting issues were causing incorrect timestamps to be calculated which caused transcoding from/to G722 to produce bad or no audio. ASTERISK-30391 ----------------- This module has been updated to provide additional quality statistics in the form of an Asterisk Media Experience Score. The score is avilable using the same mechanisms you'd use to retrieve jitter, loss, and rtt statistics. For more information about the score and how to retrieve it, see https://wiki.asterisk.org/wiki/display/AST/Media+Experience+Score * Updated chan_pjsip to set quality channel variables when a call ends. * Updated channels/pjsip/dialplan_functions.c to add the ability to retrieve the MES along with the existing rtcp stats when using the CHANNEL dialplan function. * Added the ast_debug_rtp_is_allowed and ast_debug_rtcp_is_allowed checks for debugging purposes. * Added several function to time.h for manipulating time-in-samples and times represented as double seconds. * Updated rtp_engine.c to pass through the MES when stats are requested. Also debug output that dumps the stats when an rtp instance is destroyed. * Updated res_rtp_asterisk.c to implement the calculation of the MES. In the process, also had to update the calculation of jitter. Many debugging statements were also changed to be more informative. * Added a unit test for internal testing. The test should not be run during normal operation and is disabled by default. Change-Id: I4fce265965e68c3fdfeca55e614371ee69c65038
-
George Joseph authored
This reverts commit d454801c. Reason for revert: Issue when transcoding to/from g722 Change-Id: I09f49e171b1661548657a9ba7a978c29d0b5be86
-
- Jan 03, 2023
-
-
George Joseph authored
This module has been updated to provide additional quality statistics in the form of an Asterisk Media Experience Score. The score is avilable using the same mechanisms you'd use to retrieve jitter, loss, and rtt statistics. For more information about the score and how to retrieve it, see https://wiki.asterisk.org/wiki/display/AST/Media+Experience+Score * Updated chan_pjsip to set quality channel variables when a call ends. * Updated channels/pjsip/dialplan_functions.c to add the ability to retrieve the MES along with the existing rtcp stats when using the CHANNEL dialplan function. * Added the ast_debug_rtp_is_allowed and ast_debug_rtcp_is_allowed checks for debugging purposes. * Added several function to time.h for manipulating time-in-samples and times represented as double seconds. * Updated rtp_engine.c to pass through the MES when stats are requested. Also debug output that dumps the stats when an rtp instance is destroyed. * Updated res_rtp_asterisk.c to implement the calculation of the MES. In the process, also had to update the calculation of jitter. Many debugging statements were also changed to be more informative. * Added a unit test for internal testing. The test should not be run during normal operation and is disabled by default. ASTERISK-30280 Change-Id: I458cb9a311e8e5dc1db769b8babbcf2e093f107a
-
- Dec 08, 2022
-
-
Naveen Albert authored
ASTERISK_28702 previously attempted to fix an issue with flash hook hold timing out after just under 17 minutes, when it should have never been timing out. It fixed this by changing 999999 to INT_MAX, but it did so in chan_dahdi, which is the wrong place since ss_thread is now in sig_analog and the one in chan_dahdi is mostly dead code. This fixes this by porting the fix to sig_analog. ASTERISK-30336 #close Change-Id: I05eb69cc0b5319d357842a70bd26ef64d145cb15
-
- Nov 29, 2022
-
-
Naveen Albert authored
Currently, chan_dahdi will wait for at least one ring before an incoming call can enter the dialplan. This is generally necessary in order to receive the Caller ID spill and/or distinctive ringing detection. However, if neither of these is required, then there is nothing gained by waiting for one ring and this unnecessarily delays call setup. Users can now use immediate=yes to make FXO channels (FXS signaled) begin processing dialplan as soon as Asterisk receives the call. ASTERISK-30305 #close Change-Id: I20818b370b2e4892c7f40c8a8753fa06a81750b5
-
- Nov 02, 2022
-
-
George Joseph authored
unicast_rtp_request() was setting the channel variables like this: pbx_builtin_setvar_helper(chan, "UNICASTRTP_LOCAL_ADDRESS", ast_sockaddr_stringify_addr(&local_address)); ast_rtp_instance_get_local_address(instance, &local_address); pbx_builtin_setvar_helper(chan, "UNICASTRTP_LOCAL_PORT", ast_sockaddr_stringify_port(&local_address)); ...which made it appear that UNICASTRTP_LOCAL_ADDRESS was being set before local_address was set. In fact, the address part of local_address was set earlier in the function, just not the port. This was confusing however so ast_rtp_instance_get_local_address() is now being called before setting UNICASTRTP_LOCAL_ADDRESS. ASTERISK-30281 Change-Id: I872ac49477100f4eb33891d46efc6ca21ec81aa4
-
- Oct 26, 2022
-
-
Naveen Albert authored
This fixes dahdi_request to properly set the cause code to CONGESTION instead of BUSY if no channels were actually available. Currently, the cause is erroneously set to busy if the channel itself is found, regardless of its current state. However, if the channel is not available (e.g. T1 down, card not operable, etc.), then the channel itself may not be in a functional state, in which case CHANUNAVAIL is the correct cause to use. This adds a simple check to ensure that busy tone is only returned if a channel is encountered that has an owner, since that is the only possible way that a channel could actually be busy. ASTERISK-30274 #close Change-Id: Iad5870223c081240c925b19df8d6af136953b994
-
- Oct 10, 2022
-
-
Naveen Albert authored
Fixes a format truncation warning in notify_message. ASTERISK-30256 #close Change-Id: I983a423c0214641ca4f8c9dfe0b19c47448fdee1
-
- Sep 13, 2022
-
-
Ben Ford authored
This change allows TEL URI requests to come through for basic calls. The allowed requests are INVITE, ACK, BYE, and CANCEL. The From and To headers will now allow TEL URIs, as well as the request URI. Support is only for TEL URIs present in traffic from a remote party. Asterisk does not generate any TEL URIs on its own. ASTERISK-26894 Change-Id: If5729e6cd583be7acf666373bf9f1b9d653ec29a
-
- Sep 12, 2022
-
-
Philip Prindeville authored
ASTERISK-30046 #close Change-Id: I5c738756de75fd27ebad54be144c0ac6193f21b2
-
- Sep 09, 2022
-
-
Sean Bright authored
With gcc (Ubuntu 11.2.0-19ubuntu1) 11.2.0: > chan_dahdi.c:4129:18: error: ‘%s’ directive output may be truncated > writing up to 255 bytes into a region of size between 242 and 252 > [-Werror=format-truncation=] This removes the error-prone sizeof(...) calculations in favor of just doubling the size of the base buffer. Change-Id: I2d276785286730d3d5d0a921bcea2e065dbf27c5
-
- Aug 10, 2022
-
-
Naveen Albert authored
Adds missing dial resource option documentation. ASTERISK-30164 #close Change-Id: I674e1fc9b1e5d67a20599bd4b418ce294d48fc83
-
- Aug 01, 2022
-
-
Naveen Albert authored
Adjusts some logging levels to be more or less important, that is more prominent when actual problems occur and less prominent for less noteworthy things. ASTERISK-30153 #close Change-Id: Ifc8f7df427aa018627db462125ae744986d3261b
-
- Jul 14, 2022
-
-
Naveen Albert authored
There are several things wrong with analog Caller ID handling that are fixed by this commit: callerid.c's Caller ID generation function contains the logic to use the presentation to properly send the proper Caller ID. However, currently, DAHDI does not pass any presentation information to the Caller ID module, which means that presentation is completely ignored on all calls. This means that lines could be getting Caller ID information they aren't supposed to. Part of the reason this has been obscured is because the simple switch logic for handling the built in *67 and *82 is completely wrong. Rather than modifying the presentation for the call accordingly (which is what it's supposed to do), it simply blanks out the Caller ID or fills it in. This is wrong, so wrong that it makes a mockery of the specification. Additionally, it would leave to the "UNAVAILABLE" disposition being used for Caller ID generation as opposed to the "PRIVATE" disposition that it should have been using. This is now fixed to only update the presentation and not modify the number and name, so that the simple switch *67/*82 work correctly. Next, sig_analog currently only copies over the name and number, nothing else, when it is filling in a duplicated caller id structure. Thus, we also now copy over the presentation information so that is available for the Caller ID spill. Additionally, this meant that "valid" was implicitly 0, and as such presentation would always fail to "Unavailable". The validity is therefore also copied over so it can be used by ast_party_id_presentation. As part of this fix, new API is added so that all the relevant Caller ID information can be passed in to the Caller ID generation functions. Parameters that are also completely missing from the Caller ID spill have also been added, to enhance the compatibility, correctness, and completeness of the Asterisk Caller ID implementation. ASTERISK-29991 #close Change-Id: Icc44a5e09979916f4c18a440f96e10dc1c76ae15
-
Naveen Albert authored
Adds a POLARITY function which can be used to retrieve the current polarity of an FXS channel as well as set the polarity of an FXS channel to idle or reverse at any point during a call. ASTERISK-30000 #close Change-Id: If6f50998f723e4484bf68e2473f5cedfeaf9b8f1
-
- Jul 12, 2022
-
-
Naveen Albert authored
ASTERISK-30089 #close Change-Id: I1f5db911fd05a3a211c522c13e990fa1d0e62275
-
- Jul 11, 2022
-
-
Naveen Albert authored
ASTERISK_30007 accidentally made OpenSSL a required depdendency. This adds an ifdef so the relevant code is compiled only if OpenSSL is available, since it only needs to be executed if OpenSSL is available anyways. ASTERISK-30083 #close Change-Id: Iad05c1a9a8bd2a48e7edf8d234eaa9f80779e34d
-
- Jun 15, 2022
-
-
Naveen Albert authored
Three-way calling for analog lines is currently broken. If party A is on a call with party B and initiates a three-way call to party C, the behavior differs depending on whether the call is conferenced prior to party C answering. The post-answer case is correct. However, if A flashes before C answers, then the next flash disconnects B rather than C, which is incorrect. This error occurs because the subs are not swapped in the misbehaving case. This is because the flash handler only swaps the subs if C has answered already, which is wrong. To fix this, we swap the subs regardless of whether C has answered or not when the call is conferenced. This ensures that C is disconnected on the next hook flash, rather than B as can happen currently. ASTERISK-30043 #close Change-Id: I96c5bf6c9b7eb2636136b716c677c82c079b6f06
-
- Jun 06, 2022
-
-
Naveen Albert authored
If a switch is invoked using chan_iax2, deadlock can result because the PBX core is autoservicing the channel while chan_iax2 also then attempts to service it while waiting for the result of the switch. This removes servicing of the channel to prevent any conflicts. ASTERISK-30064 #close Change-Id: Ie92f206d32f9a36924af734ddde652b21106af22
-
- Jun 02, 2022
-
-
Maximilian Fridrich authored
When a PJSIP channel is set on hold or off hold, all streams were set on/off hold. This is not the desired behaviour and caused issues when there were multiple streams in the topology. Now, only the default audio stream is set on/off hold when a hold is indicated. ASTERISK-30051 Change-Id: I04f1110565fd05fea565f5539b534b54549d4f71
-
- May 22, 2022
-
-
Moritz Fain authored
This change exposes the channel driver's unique id (i.e. the Call-ID for chan_sip/chan_pjsip based channels) to ARI channel resources as `protocol_id`. ASTERISK-30027 Reported by: Moritz Fain Tested by: Moritz Fain Change-Id: I7cc6e7a9d29efe74bc27811d788dac20fe559b87
-
- May 09, 2022
-
-
Naveen Albert authored
Currently, the operator services mode in DAHDI is broken and unusable. The actual operator recall functionality works properly; however, when the operator hangs up (which is the only way that such a call is allowed to end), both lines are permanently taken out of service until "dahdi restart" is run. This prevents this feature from being used. Operator mode is one of the few factors that can cause the general analog event handling in sig_analog not to be used. Several years back, much of the analog handling was moved from chan_dahdi to sig_analog. However, this was not done fully or consistently at the time, and when operator mode is active, sig_analog does not get used. Generally this is correct, but in the case of hangup it should be using sig_analog regardless of the operator mode; otherwise, the lines do not properly clear and they become unusable. This bug is fixed so the operator can now hang up and properly release the call. It is treated just like any other hangup. The operator mode functionality continues to work as it did before. ASTERISK-29993 #close Change-Id: Ib2e3ddb40d9c71e8801e0b4bb0a12e2b52f51d24
-
George Joseph authored
Most issues were in stringfields and had to do with comparing a pointer to an constant/interned string with NULL. Since the string was a constant, a pointer to it could never be NULL so the comparison was always "true". gcc now complains about that. There were also a few issues where determining if there was enough space for a memcpy or s(n)printf which were fixed by defining some of the involved variables as "volatile". There were also a few other miscellaneous fixes. ASTERISK-30044 Change-Id: Ia081ca1bcfb329df6487c4660aaf1944309eb570
-
- May 02, 2022
-
-
Naveen Albert authored
Documents the Dial syntax for DAHDI, namely the channel group, distinctive ring, answer confirmation, and digital call options that are specified in the resource itself. ASTERISK-24827 #close Change-Id: Ib95e78497fb00dc5cbfde1c93a69f034bfd08c30
-
Naveen Albert authored
For lines that have mailboxes configured on them, with FSK MWI, DAHDI will periodically try to dispatch FSK to update MWI. However, this is never supposed to be done when a channel is not idle. There is currently an edge case where MWI FSK can extraneously get spooled for the channel if a caller hook flashes and hangs up, which triggers a recall ring. After one ring, the on hook time threshold in this if condition has been satisfied and an MWI update is spooled. This means that when the phone is picked up again, the answerer gets an FSK spill before being reconnected to the party on hold. To prevent this, we now explicitly check to ensure that subchannel 0 has no owner. There is no owner when DAHDI channels are idle, but if the channel is "in use" in some way (such as in the aforementioned scenario), then there is an owner, and we shouldn't process MWI at this time. ASTERISK-28518 #close Change-Id: Ia3904434fd81688d71742f7e84358b7e1c38e92a
-
Naveen Albert authored
Currently, if any custom ring cadences are specified, they are appended to the array of cadences from wherever we left off last time. This works properly the first time, but on subsequent dahdi restarts, it means that the existing cadences are left alone and (most likely) the same cadences are then re-added afterwards. In short order, the cadence array gets maxed out and the user begins seeing warnings that the array is full and no more cadences may be added. This buggy behavior persists until Asterisk is completely restarted; however, if and when dahdi restart is run again, then the same problem is reintroduced. This fixes this behavior so that cadence parsing is more idempotent, that is so running dahdi restart multiple times starts adding cadences from the beginning, rather than from wherever the last cadence was added. As before, it is still not possible to revert to the default cadences by simply removing all cadences in this manner, nor is it possible to delete existing cadences. However, this does make it possible to update existing cadences, which was not possible before, and also ensures that the cadences remain unchanged if the config remains unchanged. ASTERISK-29990 #close Change-Id: Ie32ea3e8a243b766756b1afce684d4a31ee7421d
-
Naveen Albert authored
Currently, if attempting to place a call to a peer that only allows RSA authentication, if we fail to provide an outkey when placing the call, Asterisk will crash. This exposes the broader issue that IAX2 is prone to causing a crash if encryption or decryption is attempted but we never initialized the encryption and decryption keys. In other words, if the logic to use encryption in chan_iax2 is not perfectly aligned with the decision to build keys in the first place, then a crash is not only possible but probable. This was demonstrated by ASTERISK_29264, for instance. This permanently prevents such events from causing a crash by explicitly checking that keys are initialized properly before setting the flags to use encryption for the call. Instead of crashing, the call will now abort. ASTERISK-30007 #close Change-Id: If925c3d86099ceac7f621804f2532baac5050c9a
-
- Apr 27, 2022
-
-
Naveen Albert authored
According to chan_dahdi.conf, up to 64 groups (numbered 0 through 63) can be used when dialing DAHDI channels. However, currently dialing round robin with a group number greater than 31 fails because the array for the round robin structure is only size 32, instead of 64 as it should be. This fixes that so the round robin array size is consistent with the actual groups capacity. ASTERISK-29994 Change-Id: I4caa08d7025f78ac75a0539f71aaf3eb3e85b3b7
-
Mark Petersen authored
If Asterisk receives a SIP REFER with Session-Timers UAC maintain Session-Timers when sending UPDATE" ASTERISK-29843 Change-Id: I8e9a21c13bf757fa34d778f49ba3cf859b29ae5c
-
- Apr 26, 2022
-
-
Naveen Albert authored
PJSIP currently is capable of receiving flash events and converting them to FLASH control frames, but it currently lacks support for doing the reverse: taking a FLASH control frame and converting it into a flash event in the SIP domain. This adds the ability for PJSIP to process flash control frames by converting them into the appropriate SIP INFO message, which can then be sent to the peer. This allows, for example, flash events to be sent between Asterisk systems using PJSIP. ASTERISK-29941 #close Change-Id: I1590221a4d238597f79672fa5825dd4a920c94dd
-
Naveen Albert authored
Adds version information for applications, functions, and manager events/actions. This is not completely exhaustive by any means but covers most new things added that have release versioning information in the issue tracker. ASTERISK-29940 #close Change-Id: I506401e93c799715dbbe97c0a8ba18af2bf5e131
-
Mark Petersen authored
added new global config option "allow_sending_180_after_183" that if enabled will preserve 180 after a 183 ASTERISK-29842 Change-Id: I8a53f8c35595b6d16d8e86e241b5f110d92f3d18
-
Mark Petersen authored
if Asterisk need to send an UPDATE before answer on a channel that uses Record-Route: it will not include a Route header ASTERISK-29955 Change-Id: Id1920ecbfea7739a038b14dc94487ecfe7b57eef
-
- Mar 30, 2022
-
-
Naveen Albert authored
Removes some leftover build and config references to modules that have since been removed from Asterisk. ASTERISK-29935 #close Change-Id: Iaefc73a23f4b2de3c6c14d928050135b6d0ef6af
-
Kevin Harwell authored
Several modules removal and deprecations occurred in 19.0.0 (initial 19 release), but associated UPGRADE files were not removed from staging for some reason in the master branch. This patch removes those files, and also removes a spurious leftover header, chan_phone.h (associated module removed in 19). Change-Id: Ib92142c846b45c882d6b2b6caca7225253c83add
-
- Mar 28, 2022
-
-
Naveen Albert authored
The iax2 show netstats command previously didn't contain enough spacing in the header to properly align the table header with the table body. This caused column headers to not align with the values on longer channel names. Some spacing is added to account for the longest channel names that display (before truncation occurs) so that columns are always properly aligned. ASTERISK-29895 #close patches: 61205_misaligned2.patch submitted by Birger Harzenetter (license 5870) Change-Id: I450ce6bb81157b9d6d149007e53b749f237b6d9f
-
- Mar 25, 2022
-
-
Naveen Albert authored
ASTERISK_22025 introduced a regression that shows the host IP and port as the perceived IP and port again, as opposed to showing the actual perceived address. This fixes this by showing the correct information. ASTERISK-29048 #close Change-Id: I0ad3e25bc6b449e83ce72ea5d1a1cdba72aa304a
-