Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Step:15-SP4
MozillaFirefox.11697
mozilla-bmo1464766.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File mozilla-bmo1464766.patch of Package MozillaFirefox.11697
# HG changeset patch # User Mike Hommey <mh+mozilla@glandium.org> # Date 1527491713 -32400 # Mon May 28 16:15:13 2018 +0900 # Node ID 3fb6869c1c24ab89e346b6fb6bdce3790811f073 # Parent 265d398a56999417270ccc938e0f2fc2ac91cbcb Bug 1464766 - Allow to relax the addon signature requirements. r?rhelmer diff -r 265d398a5699 -r 3fb6869c1c24 modules/libpref/init/all.js --- a/modules/libpref/init/all.js Tue May 21 08:45:19 2019 +0200 +++ b/modules/libpref/init/all.js Mon May 28 16:15:13 2018 +0900 @@ -1259,6 +1259,9 @@ // in a document. pref("extensions.spellcheck.inline.max-misspellings", 500); +// Add-on manager scoped allowing unsigned addons. None by default. +pref("extensions.unsignedScopes", 12, locked); + // Prefs used by libeditor. Prefs specific to seamonkey composer // belong in comm-central/editor/ui/composer.js diff -r 265d398a5699 -r 3fb6869c1c24 toolkit/mozapps/extensions/content/extensions.js --- a/toolkit/mozapps/extensions/content/extensions.js Tue May 21 08:45:19 2019 +0200 +++ b/toolkit/mozapps/extensions/content/extensions.js Mon May 28 16:15:13 2018 +0900 @@ -52,6 +52,7 @@ const PREF_UI_LASTCATEGORY = "extensions.ui.lastCategory"; const PREF_LEGACY_EXCEPTIONS = "extensions.legacy.exceptions"; const PREF_LEGACY_ENABLED = "extensions.legacy.enabled"; +const PREF_UNSIGNED_SCOPES = "extensions.unsignedScopes"; const LOADING_MSG_DELAY = 100; @@ -234,9 +235,11 @@ } function isDisabledUnsigned(addon) { - let signingRequired = (addon.type == "locale") ? - AddonSettings.LANGPACKS_REQUIRE_SIGNING : - AddonSettings.REQUIRE_SIGNING; + let unsignedScopes = Services.prefs.getIntPref(PREF_UNSIGNED_SCOPES, 0); + let signingRequired = !(addon.scope & unsignedScopes) && + ((addon.type == "locale") ? + AddonSettings.LANGPACKS_REQUIRE_SIGNING : + AddonSettings.REQUIRE_SIGNING); return signingRequired && !isCorrectlySigned(addon); } diff -r 265d398a5699 -r 3fb6869c1c24 toolkit/mozapps/extensions/internal/XPIProvider.jsm --- a/toolkit/mozapps/extensions/internal/XPIProvider.jsm Tue May 21 08:45:19 2019 +0200 +++ b/toolkit/mozapps/extensions/internal/XPIProvider.jsm Mon May 28 16:15:13 2018 +0900 @@ -72,6 +72,7 @@ const PREF_GENERAL_SKINS_SELECTEDSKIN = "general.skins.selectedSkin"; const PREF_EM_EXTENSION_FORMAT = "extensions."; const PREF_EM_ENABLED_SCOPES = "extensions.enabledScopes"; +const PREF_EM_UNSIGNED_SCOPES = "extensions.unsignedScopes"; const PREF_EM_STARTUP_SCAN_SCOPES = "extensions.startupScanScopes"; const PREF_EM_SHOW_MISMATCH_UI = "extensions.showMismatchUI"; const PREF_XPI_ENABLED = "xpinstall.enabled"; @@ -808,7 +809,9 @@ if (aAddon.type == "theme" && aAddon.internalName == XPIProvider.defaultSkin) return true; - if (mustSign(aAddon.type) && !aAddon.isCorrectlySigned) { + let unsignedScopes = Services.prefs.getIntPref(PREF_EM_UNSIGNED_SCOPES, 0); + if (!(aAddon._installLocation.scope & unsignedScopes) && + mustSign(aAddon.type) && !aAddon.isCorrectlySigned) { logger.warn(`Add-on ${aAddon.id} is not correctly signed.`); if (Services.prefs.getBoolPref(PREF_XPI_SIGNATURES_DEV_ROOT, false)) { logger.warn(`Preference ${PREF_XPI_SIGNATURES_DEV_ROOT} is set.`); diff -r 265d398a5699 -r 3fb6869c1c24 toolkit/mozapps/extensions/internal/XPIProviderUtils.js --- a/toolkit/mozapps/extensions/internal/XPIProviderUtils.js Tue May 21 08:45:19 2019 +0200 +++ b/toolkit/mozapps/extensions/internal/XPIProviderUtils.js Mon May 28 16:15:13 2018 +0900 @@ -44,6 +44,7 @@ const PREF_DB_SCHEMA = "extensions.databaseSchema"; const PREF_PENDING_OPERATIONS = "extensions.pendingOperations"; const PREF_EM_AUTO_DISABLED_SCOPES = "extensions.autoDisableScopes"; +const PREF_EM_UNSIGNED_SCOPES = "extensions.unsignedScopes"; const KEY_APP_SYSTEM_ADDONS = "app-system-addons"; const KEY_APP_SYSTEM_DEFAULTS = "app-system-defaults";
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor