summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
Diffstat (limited to 'chrome')
-rw-r--r--chrome/service/cloud_print/cloud_print_consts.cc3
-rw-r--r--chrome/service/cloud_print/cloud_print_consts.h2
-rw-r--r--chrome/service/cloud_print/cloud_print_helpers.cc2
3 files changed, 6 insertions, 1 deletions
diff --git a/chrome/service/cloud_print/cloud_print_consts.cc b/chrome/service/cloud_print/cloud_print_consts.cc
index c86e5ee..0974205 100644
--- a/chrome/service/cloud_print/cloud_print_consts.cc
+++ b/chrome/service/cloud_print/cloud_print_consts.cc
@@ -37,4 +37,7 @@ const char kGaiaUrl[] = "https://www.google.com/accounts/ClientLogin";
const char kCloudPrintGaiaServiceId[] = "cloudprint";
const char kSyncGaiaServiceId[] = "chromiumsync";
const char kCloudPrintPushNotificationsSource[] = "cloudprint.google.com";
+// The cloud print server expects the X-Google-CloudPrint-Proxy header for
+// certain requests.
+const char kChromeCloudPrintProxyHeader[] = "X-Google-CloudPrint-Proxy: Chrome";
diff --git a/chrome/service/cloud_print/cloud_print_consts.h b/chrome/service/cloud_print/cloud_print_consts.h
index 1211571..0e98b94 100644
--- a/chrome/service/cloud_print/cloud_print_consts.h
+++ b/chrome/service/cloud_print/cloud_print_consts.h
@@ -37,7 +37,7 @@ extern const char kGaiaUrl[];
extern const char kCloudPrintGaiaServiceId[];
extern const char kSyncGaiaServiceId[];
extern const char kCloudPrintPushNotificationsSource[];
-
+extern const char kChromeCloudPrintProxyHeader[];
// Max interval between retrying connection to the server
const int64 kMaxRetryInterval = 5*60*1000; // 5 minutes in millseconds
const int64 kBaseRetryInterval = 5*1000; // 5 seconds
diff --git a/chrome/service/cloud_print/cloud_print_helpers.cc b/chrome/service/cloud_print/cloud_print_helpers.cc
index d101f0e..fc132672 100644
--- a/chrome/service/cloud_print/cloud_print_helpers.cc
+++ b/chrome/service/cloud_print/cloud_print_helpers.cc
@@ -161,6 +161,8 @@ void CloudPrintHelpers::PrepCloudPrintRequest(URLFetcher* request,
request->set_request_context(new ServiceURLRequestContextGetter());
std::string headers = "Authorization: GoogleLogin auth=";
headers += auth_token;
+ headers += "\r\n";
+ headers += kChromeCloudPrintProxyHeader;
request->set_extra_request_headers(headers);
}