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

Unified Diff: webrtc/base/sslidentity.cc

Issue 1701953002: Move SSLIdentity Generate() implementations from .h to .cc file. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Annotate static functions Created 4 years, 10 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
« no previous file with comments | « webrtc/base/sslidentity.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/base/sslidentity.cc
diff --git a/webrtc/base/sslidentity.cc b/webrtc/base/sslidentity.cc
index 536e3aa7dc46726273cc16d598296a6ec8172d74..3673d74febe458d0cc6fd3881ae411e1f667377b 100644
--- a/webrtc/base/sslidentity.cc
+++ b/webrtc/base/sslidentity.cc
@@ -154,10 +154,12 @@ SSLCertChain::~SSLCertChain() {
#if SSL_USE_OPENSSL
+// static
SSLCertificate* SSLCertificate::FromPEMString(const std::string& pem_string) {
return OpenSSLCertificate::FromPEMString(pem_string);
}
+// static
SSLIdentity* SSLIdentity::Generate(const std::string& common_name,
const KeyParams& key_params,
time_t certificate_lifetime) {
@@ -165,10 +167,25 @@ SSLIdentity* SSLIdentity::Generate(const std::string& common_name,
certificate_lifetime);
}
+// static
+SSLIdentity* SSLIdentity::Generate(const std::string& common_name,
+ const KeyParams& key_params) {
+ return OpenSSLIdentity::Generate(common_name, key_params,
+ kDefaultCertificateLifetime);
+}
+
+// static
+SSLIdentity* SSLIdentity::Generate(const std::string& common_name,
+ KeyType key_type) {
+ return OpenSSLIdentity::Generate(common_name, KeyParams(key_type),
+ kDefaultCertificateLifetime);
+}
+
SSLIdentity* SSLIdentity::GenerateForTest(const SSLIdentityParams& params) {
return OpenSSLIdentity::GenerateForTest(params);
}
+// static
SSLIdentity* SSLIdentity::FromPEMStrings(const std::string& private_key,
const std::string& certificate) {
return OpenSSLIdentity::FromPEMStrings(private_key, certificate);
« no previous file with comments | « webrtc/base/sslidentity.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698