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

Unified Diff: net/ssl/ssl_private_key.h

Issue 2391213002: Report curve types in ECDSA SSLPrivateKeys. (Closed)
Patch Set: rebase Created 4 years, 2 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 | « net/ssl/ssl_platform_key_win.cc ('k') | net/ssl/test_ssl_private_key.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/ssl/ssl_private_key.h
diff --git a/net/ssl/ssl_private_key.h b/net/ssl/ssl_private_key.h
index 2e382fbf3b2ee287eba3d9b12677b29f61476ed1..145cd5037c6555577c723c6f2bbba19590d5ba23 100644
--- a/net/ssl/ssl_private_key.h
+++ b/net/ssl/ssl_private_key.h
@@ -25,9 +25,17 @@ class SSLPrivateKey : public base::RefCountedThreadSafe<SSLPrivateKey> {
enum class Type {
RSA,
- ECDSA,
+ ECDSA_P256,
+ ECDSA_P384,
+ ECDSA_P521,
};
+ // Returns true if |type| is an ECDSA key type.
+ static bool IsECDSAType(Type type) {
+ return type == Type::ECDSA_P256 || type == Type::ECDSA_P384 ||
+ type == Type::ECDSA_P521;
+ }
+
enum class Hash {
MD5_SHA1,
SHA1,
« no previous file with comments | « net/ssl/ssl_platform_key_win.cc ('k') | net/ssl/test_ssl_private_key.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698