Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(259)

Unified Diff: talk/app/webrtc/peerconnectioninterface.h

Issue 1269843005: Added DtlsCertificate, a ref counted object owning an SSLIdentity (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Merge with master Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: talk/app/webrtc/peerconnectioninterface.h
diff --git a/talk/app/webrtc/peerconnectioninterface.h b/talk/app/webrtc/peerconnectioninterface.h
index bdbc6a7e38c1e92b07a8e7ee778166bdd2f39abb..39f20f8a246b3328b7911b0cbe172dba0c1ba286 100644
--- a/talk/app/webrtc/peerconnectioninterface.h
+++ b/talk/app/webrtc/peerconnectioninterface.h
@@ -72,6 +72,7 @@
#include <vector>
#include "talk/app/webrtc/datachannelinterface.h"
+#include "talk/app/webrtc/dtlscertificate.h"
#include "talk/app/webrtc/dtlsidentitystore.h"
#include "talk/app/webrtc/dtmfsenderinterface.h"
#include "talk/app/webrtc/dtlsidentitystore.h"
@@ -503,6 +504,9 @@ class PeerConnectionFactoryInterface : public rtc::RefCountInterface {
virtual void SetOptions(const Options& options) = 0;
+ // If a |dtls_identity_store| is provided it will be used for
+ // SSLIdentity/DtlsCertificate generation, otherwise a default store will be
+ // used.
virtual rtc::scoped_refptr<PeerConnectionInterface>
CreatePeerConnection(
const PeerConnectionInterface::RTCConfiguration& configuration,
@@ -511,6 +515,17 @@ class PeerConnectionFactoryInterface : public rtc::RefCountInterface {
rtc::scoped_ptr<DtlsIdentityStoreInterface> dtls_identity_store,
PeerConnectionObserver* observer) = 0;
+ // With the |certificate| already generated, this version of
+ // CreatePeerConnection can skip the need to generate
+ // SSLIdentity/DtlsCertificate. |certificate| must not be a null reference.
+ virtual rtc::scoped_refptr<PeerConnectionInterface>
+ CreatePeerConnection(
+ const PeerConnectionInterface::RTCConfiguration& configuration,
+ const MediaConstraintsInterface* constraints,
+ PortAllocatorFactoryInterface* allocator_factory,
+ const rtc::scoped_refptr<DtlsCertificate>& certificate,
+ PeerConnectionObserver* observer) = 0;
+
// TODO(hbos): Remove below version after clients are updated to above method.
// In latest W3C WebRTC draft, PC constructor will take RTCConfiguration,
// and not IceServers. RTCConfiguration is made up of ice servers and

Powered by Google App Engine
This is Rietveld 408576698