mirror of
https://git.jami.net/savoirfairelinux/jami-daemon.git
synced 2025-08-07 22:02:12 +08:00
[#1744] Put SRTP call on hold when SDES activated
This commit is contained in:
@ -222,7 +222,7 @@ sfl::AudioZrtpSession * AudioRtpFactory::getAudioZrtpSession()
|
||||
|
||||
void AudioRtpFactory::setRemoteCryptoInfo(sfl::SdesNegotiator& nego)
|
||||
{
|
||||
if ( (_rtpSessionType != NULL) && (_rtpSessionType == Sdes)) {
|
||||
if ( _rtpSession && _rtpSessionType && (_rtpSessionType == Sdes)) {
|
||||
static_cast<AudioSrtpSession *> (_rtpSession)->setRemoteCryptoInfo(nego);
|
||||
}
|
||||
else {
|
||||
|
@ -2571,6 +2571,8 @@ pj_status_t SIPVoIPLink::createTlsTransport(const AccountID& accountID, std::str
|
||||
{
|
||||
pj_status_t success;
|
||||
|
||||
_debug("Create TLS transport for account %s\n", accountID.c_str());
|
||||
|
||||
// Retrieve the account information
|
||||
SIPAccount * account = dynamic_cast<SIPAccount *> (Manager::instance().getAccount (accountID));
|
||||
|
||||
@ -3184,10 +3186,12 @@ void call_on_media_update (pjsip_inv_session *inv, pj_status_t status)
|
||||
_debug("SDES negociation successfull \n");
|
||||
nego_success = true;
|
||||
|
||||
if(call->getAudioRtp()->getAudioRtpType() == sfl::Sdes) {
|
||||
_debug("Set remote cryptographic context\n");
|
||||
call->getAudioRtp()->setRemoteCryptoInfo(sdesnego);
|
||||
}
|
||||
_debug("Set remote cryptographic context\n");
|
||||
try {
|
||||
call->getAudioRtp()->setRemoteCryptoInfo(sdesnego);
|
||||
}
|
||||
catch(...) {}
|
||||
|
||||
}
|
||||
else {
|
||||
|
||||
|
Reference in New Issue
Block a user