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

Unified Diff: webrtc/base/opensslidentity.h

Issue 1189583002: Support generation of EC keys using P256 curve and support ECDSA certs. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: explicitly enable ECDSA for NSS; tolerate ECDSA and RSA certs in unittest Created 5 years, 6 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: webrtc/base/opensslidentity.h
diff --git a/webrtc/base/opensslidentity.h b/webrtc/base/opensslidentity.h
index ee7aabedd1080ddc01d436e91c6312c06cf1c9a6..4d63c4a9dbec55d4fad04179cfaf911178c824d0 100644
--- a/webrtc/base/opensslidentity.h
+++ b/webrtc/base/opensslidentity.h
@@ -32,7 +32,7 @@ class OpenSSLKeyPair {
ASSERT(pkey_ != NULL);
}
- static OpenSSLKeyPair* Generate();
+ static OpenSSLKeyPair* Generate(KeyType key_type);
virtual ~OpenSSLKeyPair();
@@ -99,8 +99,10 @@ class OpenSSLCertificate : public SSLCertificate {
// them consistently.
class OpenSSLIdentity : public SSLIdentity {
public:
- static OpenSSLIdentity* Generate(const std::string& common_name);
- static OpenSSLIdentity* GenerateForTest(const SSLIdentityParams& params);
+ static OpenSSLIdentity* Generate(const std::string& common_name,
+ KeyType key_type);
+ static OpenSSLIdentity* GenerateForTest(const SSLIdentityParams& params,
+ KeyType key_type);
static SSLIdentity* FromPEMStrings(const std::string& private_key,
const std::string& certificate);
~OpenSSLIdentity() override;
@@ -114,7 +116,8 @@ class OpenSSLIdentity : public SSLIdentity {
private:
OpenSSLIdentity(OpenSSLKeyPair* key_pair, OpenSSLCertificate* certificate);
- static OpenSSLIdentity* GenerateInternal(const SSLIdentityParams& params);
+ static OpenSSLIdentity* GenerateInternal(const SSLIdentityParams& params,
+ KeyType key_type);
scoped_ptr<OpenSSLKeyPair> key_pair_;
scoped_ptr<OpenSSLCertificate> certificate_;

Powered by Google App Engine
This is Rietveld 408576698