Browse Source

MT#59038 support `block DTMF` flag

Change-Id: I6426798708d4dfb73253236ffdc0030e85494efd
pull/1802/head
Richard Fuchs 2 years ago
parent
commit
953fabbf10
3 changed files with 14 additions and 0 deletions
  1. +7
    -0
      daemon/call_interfaces.c
  2. +6
    -0
      docs/ng_control_protocol.md
  3. +1
    -0
      include/call_interfaces.h

+ 7
- 0
daemon/call_interfaces.c View File

@ -1015,6 +1015,10 @@ static void call_ng_flags_flags(sdp_ng_flags *out, str *s, helper_arg dummy) {
case CSH_LOOKUP("player"):
out->audio_player = AP_TRANSCODING;
break;
case CSH_LOOKUP("block-dtmf"):
case CSH_LOOKUP("block-DTMF"):
out->block_dtmf = 1;
break;
case CSH_LOOKUP("block-short"):
case CSH_LOOKUP("block-shorts"):
case CSH_LOOKUP("block-short-packets"):
@ -2162,6 +2166,9 @@ static const char *call_offer_answer_ng(ng_buffer *ngbuf, bencode_item_t *input,
CALL_CLEAR(call, DROP_TRAFFIC);
}
if (flags.block_dtmf)
call_set_dtmf_block(call, monologues[0], &flags);
ret = monologue_offer_answer(monologues, &streams, &flags);
if (!ret)
ret = sdp_replace(chopper, &parsed, to_ml, &flags);


+ 6
- 0
docs/ng_control_protocol.md View File

@ -815,6 +815,12 @@ Spaces in each string may be replaced by hyphens.
Corresponds to the *rtpproxy* `a` flag. Advertises an RTP endpoint which uses asymmetric
RTP, which disables learning of endpoint addresses (see below).
* `block DTMF`
Useful in `offer` or `answer` messages to immdiately enable DTMF blocking
(or other DTMF security mechanism) for the relevant call party, identical
to using a `block DTMF` message for the call party immediately after.
* `block short` or `block short packets`
Enables blocking of short RTP packets for the applicable call participant.


+ 1
- 0
include/call_interfaces.h View File

@ -183,6 +183,7 @@ struct sdp_ng_flags {
accept_any:1,
inject_dtmf:1,
detect_dtmf:1,
block_dtmf:1,
t38_decode:1,
t38_force:1,
t38_stop:1,


Loading…
Cancel
Save