mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-25 22:01:30 +00:00
Bug 1612380 - don't verify content signatures for Thunderbird. r=leplatrem
Differential Revision: https://phabricator.services.mozilla.com/D88541
This commit is contained in:
parent
f29561d8af
commit
f8c4782742
@ -12,6 +12,7 @@ const { XPCOMUtils } = ChromeUtils.import(
|
||||
const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
|
||||
|
||||
XPCOMUtils.defineLazyModuleGetters(this, {
|
||||
AppConstants: "resource://gre/modules/AppConstants.jsm",
|
||||
ClientEnvironmentBase:
|
||||
"resource://gre/modules/components-utils/ClientEnvironment.jsm",
|
||||
Database: "resource://services-settings/Database.jsm",
|
||||
@ -261,7 +262,7 @@ class RemoteSettingsClient extends EventEmitter {
|
||||
|
||||
// This attribute allows signature verification to be disabled, when running tests
|
||||
// or when pulling data from a dev server.
|
||||
this.verifySignature = true;
|
||||
this.verifySignature = AppConstants.REMOTE_SETTINGS_VERIFY_SIGNATURE;
|
||||
|
||||
// The bucket preference value can be changed (eg. `main` to `main-preview`) in order
|
||||
// to preview the changes to be approved in a real client.
|
||||
|
@ -45,7 +45,7 @@ async function clear_state() {
|
||||
|
||||
await clientWithDump.db.clear();
|
||||
|
||||
Services.prefs.clearUserPref("services.settings.default_bucket");
|
||||
Services.prefs.setCharPref("services.settings.default_bucket", "main");
|
||||
|
||||
// Clear events snapshot.
|
||||
TelemetryTestUtils.assertEvents([], {}, { process: "dummy" });
|
||||
@ -89,6 +89,7 @@ function run_test() {
|
||||
run_next_test();
|
||||
|
||||
registerCleanupFunction(function() {
|
||||
Services.prefs.clearUserPref("services.settings.default_bucket");
|
||||
server.stop(() => {});
|
||||
});
|
||||
}
|
||||
|
@ -134,11 +134,6 @@ add_task(async function test_support_of_preferences_filters() {
|
||||
filter_expression:
|
||||
'"services.settings.default_bucket"|preferenceExists == true',
|
||||
},
|
||||
{
|
||||
willMatch: true,
|
||||
filter_expression:
|
||||
'"services.settings.default_bucket"|preferenceIsUserSet == false',
|
||||
},
|
||||
{
|
||||
willMatch: true,
|
||||
filter_expression:
|
||||
@ -150,7 +145,7 @@ add_task(async function test_support_of_preferences_filters() {
|
||||
Services.prefs.setIntPref("services.settings.last_etag", 42);
|
||||
|
||||
const list = await client.get();
|
||||
equal(list.length, 4);
|
||||
equal(list.length, 3);
|
||||
ok(list.every(e => e.willMatch));
|
||||
});
|
||||
|
||||
|
@ -1,4 +1,7 @@
|
||||
[DEFAULT]
|
||||
prefs =
|
||||
services.settings.default_bucket=main
|
||||
|
||||
head = ../../../common/tests/unit/head_global.js ../../../common/tests/unit/head_helpers.js
|
||||
firefox-appdir = browser
|
||||
tags = remote-settings
|
||||
@ -12,4 +15,5 @@ support-files = test_attachments_downloader/**
|
||||
[test_remote_settings_worker.js]
|
||||
[test_remote_settings_jexl_filters.js]
|
||||
[test_remote_settings_signatures.js]
|
||||
skip-if = appname == "thunderbird" # Thunderbird doesn't use content signatures.
|
||||
[test_shutdown_handling.js]
|
||||
|
@ -419,4 +419,11 @@ this.AppConstants = Object.freeze({
|
||||
#else
|
||||
false,
|
||||
#endif
|
||||
|
||||
REMOTE_SETTINGS_VERIFY_SIGNATURE:
|
||||
#ifdef MOZ_THUNDERBIRD
|
||||
false,
|
||||
#else
|
||||
true,
|
||||
#endif
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user