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

Unified Diff: net/base/origin_bound_cert_store.h

Issue 8662036: Support EC certs in OriginBoundCertService and OriginBoundCertStore. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 1 month 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: net/base/origin_bound_cert_store.h
diff --git a/net/base/origin_bound_cert_store.h b/net/base/origin_bound_cert_store.h
index 4cb11321779e9c29dad6e9a1fb111b20d7f13681..1e07bdcbf66f8ecfb876fc4b12dcd71d8973817f 100644
--- a/net/base/origin_bound_cert_store.h
+++ b/net/base/origin_bound_cert_store.h
@@ -10,6 +10,7 @@
#include <vector>
#include "net/base/net_export.h"
+#include "net/base/origin_bound_cert_type.h"
namespace net {
@@ -25,27 +26,31 @@ class NET_EXPORT OriginBoundCertStore {
// Used by GetAllOriginBoundCerts.
struct OriginBoundCertInfo {
std::string origin; // Origin, for instance "https://www.verisign.com:443".
+ OriginBoundCertType type;
Ryan Sleevi 2011/11/25 00:07:02 This may put you close to the clang style warning
mattm 2011/12/02 01:55:59 will do.
std::string private_key; // DER-encoded PrivateKeyInfo struct.
std::string cert; // DER-encoded certificate.
};
virtual ~OriginBoundCertStore() {}
- // TODO(rkn): Specify certificate type (RSA or DSA).
// TODO(rkn): File I/O may be required, so this should have an asynchronous
// interface.
// Returns true on success. |private_key_result| stores a DER-encoded
// PrivateKeyInfo struct and |cert_result| stores a DER-encoded
// certificate. Returns false if no origin bound cert exists for the
// specified origin.
- virtual bool GetOriginBoundCert(const std::string& origin,
- std::string* private_key_result,
- std::string* cert_result) = 0;
+ virtual bool GetOriginBoundCert(
+ const std::string& origin,
wtc 2011/11/30 23:23:40 IMPORTANT: I think we should also pass requested_t
mattm 2011/12/01 00:06:27 This is only storing one type of cert per origin.
+ OriginBoundCertType* type,
+ std::string* private_key_result,
+ std::string* cert_result) = 0;
// Adds an origin bound cert and the corresponding private key to the store.
- virtual void SetOriginBoundCert(const std::string& origin,
- const std::string& private_key,
- const std::string& cert) = 0;
+ virtual void SetOriginBoundCert(
+ const std::string& origin,
+ OriginBoundCertType type,
+ const std::string& private_key,
+ const std::string& cert) = 0;
// Removes an origin bound cert and the corresponding private key from the
// store.

Powered by Google App Engine
This is Rietveld 408576698