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

Unified Diff: components/data_reduction_proxy/core/common/data_reduction_proxy_params.cc

Issue 1547273003: Set trusted SPDY proxy dynamically on per-profile basis (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added net/base/test_proxy_delegate.{h,cc} 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/common/data_reduction_proxy_params.cc
diff --git a/components/data_reduction_proxy/core/common/data_reduction_proxy_params.cc b/components/data_reduction_proxy/core/common/data_reduction_proxy_params.cc
index fe62c2f4f29ba9349a546dc67a5805546750b56a..13157cbe6c6badc55341327f97992bbd860f4e96 100644
--- a/components/data_reduction_proxy/core/common/data_reduction_proxy_params.cc
+++ b/components/data_reduction_proxy/core/common/data_reduction_proxy_params.cc
@@ -50,6 +50,8 @@ const char kLoFiFlagFieldTrial[] = "DataCompressionProxyLoFiFlag";
const char kConfigServiceFieldTrial[] = "DataReductionProxyConfigService";
const char kConfigServiceURLParam[] = "url";
+const char kTrustedSpdyProxyFieldTrialName[] = "DataReductionTrustedSpdyProxy";
+
// Default URL for retrieving the Data Reduction Proxy configuration.
const char kClientConfigURL[] =
"https://datasaver.googleapis.com/v1/clientConfigs";
@@ -78,6 +80,15 @@ bool IsIncludedInAndroidOnePromoFieldTrial(const char* build_fingerprint) {
return (fingerprint.find(kAndroidOneIdentifier) != std::string::npos);
}
+std::string GetTrustedSpdyProxyFieldTrialName() {
+ return kTrustedSpdyProxyFieldTrialName;
+}
+
+bool IsIncludedInTrustedSpdyProxyFieldTrial() {
+ return base::FieldTrialList::FindFullName(GetTrustedSpdyProxyFieldTrialName())
+ .find(kEnabled) == 0;
+}
+
std::string GetLoFiFieldTrialName() {
return kLoFiFieldTrial;
}

Powered by Google App Engine
This is Rietveld 408576698