Bug 887044: Remove CsdTesting/Mozilla from User-Agent, set safebrowsing URLs to use the GOOGLE_API_KEY (r=dougt)

This commit is contained in:
Monica Chew 2013-11-01 15:43:28 -07:00
parent d3cb572483
commit fbd7f92937
2 changed files with 2 additions and 11 deletions

View File

@ -795,7 +795,7 @@ pref("browser.safebrowsing.enabled", true);
pref("browser.safebrowsing.malware.enabled", true);
pref("browser.safebrowsing.debug", false);
pref("browser.safebrowsing.updateURL", "http://safebrowsing.clients.google.com/safebrowsing/downloads?client=SAFEBROWSING_ID&appver=%VERSION%&pver=2.2");
pref("browser.safebrowsing.updateURL", "http://safebrowsing.clients.google.com/safebrowsing/downloads?client=SAFEBROWSING_ID&appver=%VERSION%&pver=2.2&apikey=%GOOGLE_API_KEY%");
pref("browser.safebrowsing.keyURL", "https://sb-ssl.google.com/safebrowsing/newkey?client=SAFEBROWSING_ID&appver=%VERSION%&pver=2.2");
pref("browser.safebrowsing.gethashURL", "http://safebrowsing.clients.google.com/safebrowsing/gethash?client=SAFEBROWSING_ID&appver=%VERSION%&pver=2.2");
pref("browser.safebrowsing.reportURL", "http://safebrowsing.clients.google.com/safebrowsing/report?");
@ -806,11 +806,8 @@ pref("browser.safebrowsing.reportMalwareURL", "http://%LOCALE%.malware-report.mo
pref("browser.safebrowsing.reportMalwareErrorURL", "http://%LOCALE%.malware-error.mozilla.com/?hl=%LOCALE%");
pref("browser.safebrowsing.malware.reportURL", "http://safebrowsing.clients.google.com/safebrowsing/diagnostic?client=%NAME%&hl=%LOCALE%&site=");
// Since the application reputation query isn't hooked in anywhere yet, this
// preference does not matter. To be extra safe, don't turn this preference on
// for official builds without whitelisting (bug 842828).
#ifndef MOZILLA_OFFICIAL
pref("browser.safebrowsing.appRepURL", "https://sb-ssl.google.com/safebrowsing/clientreport/download");
pref("browser.safebrowsing.appRepURL", "https://sb-ssl.google.com/safebrowsing/clientreport/download&apikey=%GOOGLE_API_KEY%");
#endif
#ifdef MOZILLA_OFFICIAL

View File

@ -199,12 +199,6 @@ PendingLookup::SendRemoteQuery() {
nsCOMPtr<nsIHttpChannel> httpChannel(do_QueryInterface(channel, &rv));
NS_ENSURE_SUCCESS(rv, rv);
// See bug 887044 for finalizing the user agent.
const nsCString userAgent = NS_LITERAL_CSTRING("CsdTesting/Mozilla");
rv = httpChannel->SetRequestHeader(
NS_LITERAL_CSTRING("User-Agent"), userAgent, false);
NS_ENSURE_SUCCESS(rv, rv);
// Upload the protobuf to the application reputation service.
nsCOMPtr<nsIUploadChannel2> uploadChannel = do_QueryInterface(channel, &rv);
NS_ENSURE_SUCCESS(rv, rv);