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

Unified Diff: net/base/default_origin_bound_cert_store.cc

Issue 8890073: Handle Origin Bound Certificate expiration. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years 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/default_origin_bound_cert_store.cc
diff --git a/net/base/default_origin_bound_cert_store.cc b/net/base/default_origin_bound_cert_store.cc
index 8104658f7b58896327f8a448de70bc87cd3ae015..5884c69ce12d212db67bb4f383381e4bf0985278 100644
--- a/net/base/default_origin_bound_cert_store.cc
+++ b/net/base/default_origin_bound_cert_store.cc
@@ -30,6 +30,7 @@ void DefaultOriginBoundCertStore::FlushStore(
bool DefaultOriginBoundCertStore::GetOriginBoundCert(
const std::string& origin,
SSLClientCertType* type,
+ base::Time* not_valid_after,
std::string* private_key_result,
std::string* cert_result) {
base::AutoLock autolock(lock_);
@@ -42,6 +43,7 @@ bool DefaultOriginBoundCertStore::GetOriginBoundCert(
OriginBoundCert* cert = it->second;
*type = cert->type();
+ *not_valid_after = cert->not_valid_after();
*private_key_result = cert->private_key();
*cert_result = cert->cert();
@@ -51,6 +53,7 @@ bool DefaultOriginBoundCertStore::GetOriginBoundCert(
void DefaultOriginBoundCertStore::SetOriginBoundCert(
const std::string& origin,
SSLClientCertType type,
+ base::Time not_valid_after,
const std::string& private_key,
const std::string& cert) {
base::AutoLock autolock(lock_);
@@ -58,7 +61,8 @@ void DefaultOriginBoundCertStore::SetOriginBoundCert(
InternalDeleteOriginBoundCert(origin);
InternalInsertOriginBoundCert(
- origin, new OriginBoundCert(origin, type, private_key, cert));
+ origin,
+ new OriginBoundCert(origin, type, not_valid_after, private_key, cert));
}
void DefaultOriginBoundCertStore::DeleteOriginBoundCert(

Powered by Google App Engine
This is Rietveld 408576698