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

Unified Diff: components/data_reduction_proxy/core/browser/data_reduction_proxy_config.h

Issue 1547273003: Set trusted SPDY proxy dynamically on per-profile basis (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Updated based on design doc discussion Created 4 years, 11 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/data_reduction_proxy/core/browser/data_reduction_proxy_config.h
diff --git a/components/data_reduction_proxy/core/browser/data_reduction_proxy_config.h b/components/data_reduction_proxy/core/browser/data_reduction_proxy_config.h
index df01795fcaf93e5281e71137da129764b055ba88..fbd826635e43ac50c0f162129678f63af0a9e8e4 100644
--- a/components/data_reduction_proxy/core/browser/data_reduction_proxy_config.h
+++ b/components/data_reduction_proxy/core/browser/data_reduction_proxy_config.h
@@ -29,6 +29,7 @@ namespace net {
class HostPortPair;
class NetLog;
class NetworkQualityEstimator;
+class ProxyServer;
class URLFetcher;
class URLRequest;
class URLRequestContextGetter;
@@ -190,6 +191,10 @@ class DataReductionProxyConfig
// the URLRequestContext.
bool ShouldEnableLoFiMode(const net::URLRequest& request);
+ // Returns true if |trusted_spdy_proxy| is a secure data reduction proxy, and
+ // should be allowed to push cross-origin resources.
bengr 2016/01/26 19:39:55 proxy, -> proxy Explain all of the criteria for b
tbansal1 2016/01/27 00:13:33 Done.
+ bool IsTrustedSpdyProxy(const net::ProxyServer& trusted_spdy_proxy) const;
+
protected:
// Virtualized for mocking. Records UMA containing the result of requesting
// the secure proxy check.
@@ -217,6 +222,7 @@ class DataReductionProxyConfig
AreProxiesBypassed);
FRIEND_TEST_ALL_PREFIXES(DataReductionProxyConfigTest,
AreProxiesBypassedRetryDelay);
+ FRIEND_TEST_ALL_PREFIXES(DataReductionProxyConfigTest, TrustedSpdyProxy);
FRIEND_TEST_ALL_PREFIXES(DataReductionProxyConfigTest, AutoLoFiParams);
FRIEND_TEST_ALL_PREFIXES(DataReductionProxyConfigTest,
AutoLoFiParamsSlowConnectionsFlag);

Powered by Google App Engine
This is Rietveld 408576698