Donat Zenichev
bebe291656
MT#59086 Unify header files inclusions.
In the file implementations follow the rules:
1. Firstly goes the correlated header file, then one empty row.
2. Secondly go system headers, so in angle-brackets, then one empty row.
3. Thirdly, go custom header files, so in double quotes,
then one empty row.
4. If there is "xt_RTPENGINE.h", it's mentioned next, but separately,
then one empty row.
5. If there are pre-processor definitions, they are added.
6. And eventually at least one empty row before the code.
In some situations it's allowed to step aside from the rules,
when inclusions are dependent on each other, so on the sequence,
and also possibly on some inline objects definitions, but if possible
to follow the rules, it's being done.
Change-Id: Ie512a970e230fe202398656d1942e8874bb14cd9
2 years ago
Richard Fuchs
7b2ba5339a
MT#55283 use typed G* for call members
Change-Id: Idcd7d703952d5559d3e13bf681cf7342e6768f12
2 years ago
Richard Fuchs
2975b2131d
MT#55283 convert struct call to typedef
Change-Id: I1f01fdf74d6d3952413ebc02dfdb9770b324481c
2 years ago
Richard Fuchs
9510b01a29
MT#55283 use typed GQueue for dtmf_events
Change-Id: I241190eb84420e8d84b5267d2ba47906ddbd5e6c
2 years ago
Richard Fuchs
57598e1255
MT#55283 use typed GQueue for stream/handlers
Change-Id: I874680db25f26466400f4a08641a97cb6f7be36b
2 years ago
Steven Ayre
1e64ac2340
MT#55283 add label to dtmf notification
closes #1747
Change-Id: Ie19b01a5003428b4645057abc037163ccfbd44d8
2 years ago
Tom Briden
e40e6c5cd0
MT#55283 Allow dtmf injection when also using a delay buffer
previously, dtmf_inject wouldn't add the events as the dtmf_payload_type
was set to -1 as part of the delay buffer handling. However, as we
know we want this DTMF, this change updates the function to check for
and use the real_dtmf_payload_type value
Then, in codec_add_dtmf_event, we can check the injected bool and
if set, use the real_dtmf_payload_type again to decide whether to
push the event onto the queue
closes #1722
Change-Id: I34e35f92e014f4aed9e045737df7400155b86602
2 years ago
Alex Hermann
d4d93332a4
MT#55283 Don't log an error on success when sending DTMF event
closes #1701
Change-Id: I1bc894bf7cc1b716ec847045dcf1bf4a676e81f7
2 years ago
Richard Fuchs
5e5e08e377
MT#55283 rename variables to eliminate shadowing
Change-Id: Iaf5f98dd4820669e1ee0133dceed8a6a6d791b23
3 years ago
Richard Fuchs
4389aed9e9
MT#56861 use correct codec handler for DTMF inject
DTMF injection must use the codec handler of the primary payload (audio
stream), not the handler of the DTMF PT itself.
Change-Id: Ied2d1f969bfc76ef7af0ada063b90a47c4633557
3 years ago
Richard Fuchs
93d4fe74c1
MT#56861 use SSRC TS for "encoder" TS
Support using the SSRC TS derived from received RTP packets as "encoder"
TS (the "next" expected TS) for passthrough RTP in addition to the FIFO
TS of an actual encoder.
Change-Id: I7c49c27651eb89c5349bbf290b1c0ad160f77e3b
3 years ago
Richard Fuchs
6b5f1f081c
MT#56856 log duration only for end events
The "duration" is not valid for events which are not end events as
there's no previous event to derive a duration from.
Change-Id: I3f9dad536b168cce24d1a58c5bcf25e5cacfe7a8
3 years ago
Richard Fuchs
2267023f07
MT#56861 use correct printf formats
Change-Id: I3a6bcc8453c7623887e042b083e0eb685dd91127
3 years ago
Richard Fuchs
0914bf761d
MT#55283 add per-call dtmf-log-dest
Closes #1628
Change-Id: If2a4175cc64e1143de8c749676ed215f7dc52915
3 years ago
Richard Fuchs
998b55cbcc
MT#55283 unconditionally create DTMF socket
In order to support a per-call toggle for DTMF logging without having
the global config option set, we always open the socket just in case.
Change-Id: Ibb62672afa21e41623e74603214b4d9d8b94443c
3 years ago
Richard Fuchs
711d43646f
MT#55283 switch DTMF socket to connectionless
Make it possible to send to other/multiple destinations
Change-Id: Ic46f420f5fb9719c72063966f3e8e8fe73ed817a
3 years ago
Tom Briden
35ac2610af
MT#55283 Add an option to not send dtmf log events for injected dtmf
global config option that defaults to false to preserve existing
behaviour
Closes #1627
Change-Id: I78a88fcc5c262f1786bf0812753231a0076e0c88
3 years ago
Richard Fuchs
25e2640145
TT#136957 support multiple frequencies for `tone`
Support multiple tone frequencies for DTMF-security=tone to enable
audibly distinguishing multiple consecutive DTMF events from one
another.
Change-Id: I6fa33a5768aae198220d0b0cc4c53308c5661a52
3 years ago
Richard Fuchs
f95495d4f0
TT#136957 move rand_code from _send to _recv
The `dtmf_send` event might not have a matching entry while handling a
received DTMF event. Move bookkeeping of the random output event into
`dtmf_recv`.
Change-Id: I5507b0b7f5eca6e29cbcaccc905ab25249b22aa3
3 years ago
Richard Fuchs
7be1d0aef1
TT#189201 refactor sink/handler attributes
Create a dedicated struct to hold certain attributes shared by both sink
handlers and media subscriptions, as a preparation to simplify handling
these attributs.
Change-Id: I866159c33ed6d6a2873d2cf68c4906ea705d253e
3 years ago
Richard Fuchs
84fed5ca7e
TT#136957 obsolete TRANSCODE flag
Change-Id: I7307b63a8f5a10aa3b5c98fb48218bcc7a123441
4 years ago
Richard Fuchs
2240921ab3
TT#136957 use separate sequencer per sink/destination
Change-Id: Ib960108003d5aa13ba1732d7a5e8c6720feca5c0
4 years ago
Richard Fuchs
c0d9f84e49
TT#14008 rename instance of `func` for clarity
Change-Id: Ie61bc4e9ea8bcd4fdf540cce67acb8032eecff63
4 years ago
Richard Fuchs
7836035f3f
TT#14008 fix double mutex unlock
Change-Id: I6098b6f01141e8fb6967f74538416ccede471fa3
Warned-by: coverity
4 years ago
Richard Fuchs
60fe7104e7
TT#14008 fix possible unintentional integer overflow
Change-Id: I9dacb34cf92d461029bfb393a251736676431fc7
Warned-by: coverity
4 years ago
Richard Fuchs
3582b623a9
TT#136957 DTMF delay support
Change-Id: I62dce272a1acc0a9a3b6b8c37df68a18357dbee4
4 years ago
Richard Fuchs
1ef4eeba80
TT#136957 split up DTMF event queue into in and out
Change-Id: I2e0619071d43df8537736187104ca12bb2f86f64
4 years ago
Richard Fuchs
c794c00efa
TT#136957 refactor DTMF event tracking into a list
Change-Id: I09aec46cad4cbb92aab67b7e9158d4d1598df186
4 years ago
Richard Fuchs
2ca64340e1
TT#136957 support DTMF triggers for blocking
Change-Id: I32e0d02e739ceb5a34aaf187b1ea086482e6d73e
4 years ago
Richard Fuchs
6ac4f12c01
TT#136956 add more options for DTMF replacement
Change-Id: Ic78a34042ad664bd54e35647636864ea99e60385
4 years ago
Richard Fuchs
576774614b
TT#136956 add support for DTMF-security=zero
Change-Id: I48d612697ac3f89852b2b7374cf6e442e4a8222e
4 years ago
Richard Fuchs
9da5a46fcb
TT#136956 support DTMF-security=random
Change-Id: I4100c1511be743901d302491238872990f213118
4 years ago
Richard Fuchs
38f97c2df8
TT#136956 support DTMF silence replacement
Change-Id: If693800a955a9ddf7245da0082426ae609deb407
4 years ago
Richard Fuchs
478c2608e8
TT#136956 upgrade `block_dtmf` to enum to allow for different modes
Change-Id: I8bfa1cb9067a00958a2a1415b82e01c02deaf758
4 years ago
Richard Fuchs
ba556db1d4
TT#136955 tie in DSP DTMF events with other DTMF reporting
Change-Id: I72fe6b670c42fe4ed6ba32a1fd142c290b2aaca2
4 years ago
Richard Fuchs
fdb529eb5a
TT#136955 refactor DTMF event reporting
Change-Id: I420f56674a639a4b41b5333d8d9b8ffa843a7042
4 years ago
Richard Fuchs
24f607752c
TT#145450 add support for tracking multiple SSRCs per stream
Change-Id: I885fbf7973133af8d7c9184eb0e75f5401309c8e
4 years ago
Richard Fuchs
92fb330a46
TT#91151 implement one-to-many forwarding
Change-Id: I80fd35da680d4ad1f4d3d21f14f11363106b9917
5 years ago
Richard Fuchs
1e0765bf6e
TT#91151 tie codec handlers to output media/sink
Change-Id: Id577f9afabbe5645a6e220b6450c39a35ff839a9
5 years ago
Richard Fuchs
1d387b98ef
TT#112700 rework codec offer/answer routine
Complete overhaul of the codec handling code:
*) obsolete flags `asymmetric codecs`, `symmetric codecs`, `reorder
codecs`
*) support proper codec offer/answer
*) split codec manipulation (strip/offer/accept/etc) into separate
functions for clarity and better code maintenance
*) fully update codec handlers in both directions after an answer
*) explicit allocation and handling of codecs and payload types in a
codec_store object
*) improve codec matchup logic during answer
*) more explicit handling of supplemental codecs (CN/DTMF)
*) remove now obsolete hacks for handling certain use cases
Change-Id: I996705ba8fe339524c2f70e6bb0fd854f9a1f4fb
5 years ago
Richard Fuchs
256b9917ec
TT#121752 associate SSRC hash to monologue instead of entire call
This solves problems when the same SSRC is looped through the same call
multiple times in different mono/dialogues, with different parameters.
Change-Id: I1d033cb1f012574d82b5bcbfffe11eb5f983cfd8
5 years ago
Richard Fuchs
b734fc080e
TT#14008 fix integer handling (overflow/sign) issues
Warned-by: coverity
Change-Id: Ia473075046253b2ffcf65344f65469772e6df993
5 years ago
Richard Fuchs
6527fb513c
TT#111150 fix an SSRC reference leak
get_ssrc_ctx() returns a new reference to the SSRC object, therefore we
must release the referece when we're done with it.
Change-Id: I0db07e4cca49a37af68d072ac6d0630c025b8809
5 years ago
Richard Fuchs
d5d0a3a994
TT#111150 convert str.len to size_t
This makes the type in line with string(3) functions and eliminates some
compiler warnings.
Also update the related bencode data type.
Change-Id: I7ef4024f4b5a0f737b3dbe03bcd078032395bce6
5 years ago
Guillem Jover
a8a0adb759
TT#111150 Remove tautological test in dtmf_inject()
The tracker.most array is of unsigned char, so pt which gets
unconditionally assigned will always be >= 0.
Change-Id: I8adc06fc6c65aa0e33ef6614eb77c67b0dc07517
Warned-by: lgtm
5 years ago
Richard Fuchs
af6ef843da
TT#100200 suppress audio packets during a DTMF event
Change-Id: I9612d692c3c6945c93b3194760383e67e5bca0e0
5 years ago
Guillem Jover
6a9d61dffd
TT#108003 Check send() return code for DTMF UDP logging
Log an error and continue anyway if the send() failed, this is just
logging.
Change-Id: I542385489f8e37e6e524b766371fed3ba558ff2f
5 years ago
Damir Nedžibović
0ae0681b28
TT#14008 Squashed commit of the following:
closes #1183
commit a74cf4a7f9
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Tue Feb 2 11:06:50 2021 +0100
Add --dtmf-log-ng-tcp CLI option.
commit a428764d9b
Merge: 2bbfcb27 8abc6b1c
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Tue Feb 2 09:16:26 2021 +0100
Merge branch 'master' into dtmf_events_over_ng_tcp
commit 2bbfcb2750
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Mon Feb 1 14:28:07 2021 +0100
Replace hex values with chars.
commit dc1084d122
Merge: 2bce444b 2c7163ea
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Mon Feb 1 13:53:27 2021 +0100
Merge branch 'dtmf_events_over_ng_tcp' of github.com:enreached/rtpengine into dtmf_events_over_ng_tcp
commit 2bce444b26
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Mon Feb 1 13:28:06 2021 +0100
Prevent use after free.
commit 5a256fd3ae
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Fri Jan 29 13:30:31 2021 +0100
Add missing includes.
commit a14f4034b9
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Fri Jan 29 13:27:27 2021 +0100
Add support for sending DTMF events via protocol NG TCP.
commit b861fe3087
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Thu Jan 28 18:09:10 2021 +0100
Add missing include.
commit 7bfe08fb08
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Thu Jan 28 18:05:44 2021 +0100
Implementation of control-ng via TCP.
commit 2c7163eaf3
Merge: fd286813 9165bf1f
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Mon Feb 1 13:49:00 2021 +0100
Merge branch 'dtmf_events_over_ng_tcp' of github.com:enreached/rtpengine into dtmf_events_over_ng_tcp
commit fd28681350
Author: Richard Fuchs <rfuchs@sipwise.com>
Date: Fri Jan 29 10:20:02 2021 -0500
TT#14008 fix AEAD kernel API for < 4.2
Untested whether it actually works
closes #1176
Change-Id: If6398632ac62525a673b844cfb4ce842a8aa0346
commit 0626dcdd96
Author: Richard Fuchs <rfuchs@sipwise.com>
Date: Fri Jan 29 13:07:25 2021 -0500
TT#14008 improve log output for stray packets
Change-Id: Ic4b03928b279aade761de3ba1646b5c27318e6a3
commit 8fcccb77cc
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Mon Feb 1 13:28:06 2021 +0100
Prevent use after free.
commit f0d90d1831
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Fri Jan 29 13:30:31 2021 +0100
Add missing includes.
commit 37462b8e4d
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Fri Jan 29 13:27:27 2021 +0100
Add support for sending DTMF events via protocol NG TCP.
commit 9165bf1f75
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Mon Feb 1 13:28:06 2021 +0100
Prevent use after free.
commit d616f2941f
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Fri Jan 29 13:30:31 2021 +0100
Add missing includes.
commit bb063386c6
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Fri Jan 29 13:27:27 2021 +0100
Add support for sending DTMF events via protocol NG TCP.
commit b28ab07532
Merge: 813a4f1c 6e4373af
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Fri Jan 29 09:21:31 2021 +0100
Merge branch 'control_ng_tcp' of github.com:enreached/rtpengine into control_ng_tcp
commit 813a4f1caa
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Thu Jan 28 18:09:10 2021 +0100
Add missing include.
commit 0c87a19c55
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Thu Jan 28 18:05:44 2021 +0100
Implementation of control-ng via TCP.
commit 6e4373affb
Merge: fbf74bfe 7799f23a
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Fri Jan 29 09:19:46 2021 +0100
Merge branch 'control_ng_tcp' of github.com:enreached/rtpengine into control_ng_tcp
commit fbf74bfe2d
Author: Richard Fuchs <rfuchs@sipwise.com>
Date: Wed Jan 27 10:18:14 2021 -0500
TT#14008 fix possible segfault
closes #1172
Change-Id: I94bb52c290c2032073e54528283660f03e694033
commit 1a5bcc0905
Author: Richard Fuchs <rfuchs@sipwise.com>
Date: Thu Jan 28 14:49:43 2021 -0500
TT#109251 fix redis restore segfault
Change-Id: I501a47b065e7b8ff28a3ac157c0ce567f228557f
commit b38b49fd60
Author: Richard Fuchs <rfuchs@sipwise.com>
Date: Thu Jan 28 13:44:44 2021 -0500
TT#102450 added tests for Ia9fa96cf
Change-Id: Ic9728e12a012335c30c5640ac0b5c88e39ad24ed
commit f33877bfe3
Author: Richard Fuchs <rfuchs@sipwise.com>
Date: Thu Jan 28 13:43:46 2021 -0500
TT#102450 fix some timestamping issues
Make sure G.722 rate multiplies is applied in the right places
Don't trust encoders to return proper timestamps, but instead track them
explicitly based on frame duration
Change-Id: Ia9fa96cf662da97159fa170c3a3f37516889e1bd
commit 39a25b954d
Author: Richard Fuchs <rfuchs@sipwise.com>
Date: Thu Jan 28 14:07:53 2021 -0500
TT#106101 mem leak fix for 554034eb7e
Change-Id: I9c410211580d8513a203a29f898970a78175d08b
commit 11d11aed90
Author: Richard Fuchs <rfuchs@sipwise.com>
Date: Thu Jan 28 13:41:28 2021 -0500
TT#14008 clean up some tests
Looks like packet order can be an issue in some cases
Change-Id: Ib8fb8c553c9d0f2919b24dda1e15e5a23832c619
commit 7799f23aa5
Merge: ba7ee9d6 e191e16c
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Fri Jan 29 09:18:24 2021 +0100
Merge branch 'master' of https://github.com/sipwise/rtpengine into control_ng_tcp
commit ba7ee9d6b1
Merge: f805d881 ffe187f1
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Thu Jan 28 18:15:58 2021 +0100
Merge branch 'control_ng_tcp' of github.com:enreached/rtpengine into control_ng_tcp
commit f805d881fa
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Thu Jan 28 18:09:10 2021 +0100
Add missing include.
commit c548a3ca4b
Author: Damir Nedžibović <damir.nedzibovic@enreach.com>
Date: Thu Jan 28 18:05:44 2021 +0100
Implementation of control-ng via TCP.
commit ffe187f116
Author: Damir Nedžibović <damir.nedzibovic@bad-team.net>
Date: Thu Jan 28 18:05:44 2021 +0100
Implementation of control-ng via TCP.
Change-Id: I8383fa80bce59aa865009e34caff5263b97ab588
5 years ago
Richard Fuchs
e8aac8272c
TT#91003 add media_out pointer to media_packet
Change-Id: I21c76fef05d6af394f09476e9761c439e7a0da44
5 years ago
Richard Fuchs
e04fb03787
Recrypt SRTP for DTMF logging
Change-Id: Id877b8464e99cfd5dca728a01fcdc3ffc654d698
5 years ago