Skip to content
Snippets Groups Projects
Commit 18669df2 authored by Adrien Béraud's avatar Adrien Béraud
Browse files

sipcall: don't provide certificate to clients

Change-Id: Ic959e2db4a484bde5c19fa1bec7a997cb332f571
parent f52c6cdb
No related branches found
No related tags found
No related merge requests found
......@@ -1217,10 +1217,15 @@ SIPCall::getDetails() const
details.emplace(DRing::Call::Details::REGISTERED_NAME, peerRegistredName_);
#endif
#ifdef ENABLE_CLIENT_CERT
if (transport_ and transport_->isSecure()) {
const auto& tlsInfos = transport_->getTlsInfos();
const auto& cipher = pj_ssl_cipher_name(tlsInfos.cipher);
details.emplace(DRing::TlsTransport::TLS_CIPHER, cipher ? cipher : "");
if (tlsInfos.cipher != PJ_TLS_UNKNOWN_CIPHER) {
const auto& cipher = pj_ssl_cipher_name(tlsInfos.cipher);
details.emplace(DRing::TlsTransport::TLS_CIPHER, cipher ? cipher : "");
} else {
details.emplace(DRing::TlsTransport::TLS_CIPHER, "");
}
if (tlsInfos.peerCert) {
details.emplace(DRing::TlsTransport::TLS_PEER_CERT,
tlsInfos.peerCert->toString());
......@@ -1239,6 +1244,7 @@ SIPCall::getDetails() const
details.emplace(DRing::TlsTransport::TLS_PEER_CA_NUM, "");
}
}
#endif
return details;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment