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

Unified Diff: components/cronet/url_request_context_config.h

Issue 1407263010: [Cronet] Public key pinning for Java API (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Small javadoc fix Created 5 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
Index: components/cronet/url_request_context_config.h
diff --git a/components/cronet/url_request_context_config.h b/components/cronet/url_request_context_config.h
index c40a112c5b108d7638349ecb7d3080d2054981e2..9ebcf63bf568dfaed512b9124d123f09c64a95ff 100644
--- a/components/cronet/url_request_context_config.h
+++ b/components/cronet/url_request_context_config.h
@@ -41,6 +41,26 @@ struct URLRequestContextConfig {
DISALLOW_COPY_AND_ASSIGN(QuicHint);
};
+ // Public-Key-Pinning configuration structure.
+ struct Hpkp {
+ Hpkp(){};
+ ~Hpkp(){};
+
+ // Register |converter| for use in converter.Convert().
+ static void RegisterJSONConverter(
+ base::JSONValueConverter<Hpkp>* converter);
+
+ // Name of the pinned host.
mef 2015/11/02 17:56:56 nit: Host name.
kapishnikov 2015/11/02 22:45:49 Done.
+ std::string host;
+ // Pin hashes (currently SHA256 only).
+ ScopedVector<std::string> pin_hashes;
+ // Indicates whether the pinning should apply to the pinned host subdomains.
+ bool include_subdomains;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(Hpkp);
+ };
+
URLRequestContextConfig();
~URLRequestContextConfig();
@@ -82,6 +102,8 @@ struct URLRequestContextConfig {
std::string data_reduction_primary_proxy;
std::string data_reduction_fallback_proxy;
std::string data_reduction_secure_proxy_check_url;
+ // The list of host pinning-s
mef 2015/11/02 17:56:56 -s? End in period.
kapishnikov 2015/11/02 22:45:49 Done.
+ ScopedVector<Hpkp> hpkp_list;
// Certificate verifier for testing.
scoped_ptr<net::CertVerifier> mock_cert_verifier;

Powered by Google App Engine
This is Rietveld 408576698