[Core] switch_ivr: Ensure do_flush decrypts SRTP DTMF packets

This commit is contained in:
Andy Newlands 2022-08-04 11:07:33 +01:00
parent 4cc8031493
commit 015b77fed7
1 changed files with 1 additions and 0 deletions

View File

@ -5913,6 +5913,7 @@ static switch_size_t do_flush(switch_rtp_t *rtp_session, int force, switch_size_
}
#endif
// Ensure we properly decrypt SRPT before reading DTMF
if (!rtp_session->flags[SWITCH_RTP_FLAG_SECURE_RECV_MKI]) {
stat = srtp_unprotect(rtp_session->recv_ctx[rtp_session->srtp_idx_rtp], &rtp_session->recv_msg.header, &sbytes);
} else {