From 7239458847fe628f32ed6b19c3187be7ed5e404b Mon Sep 17 00:00:00 2001 From: Bobby Holley Date: Thu, 17 Jul 2014 21:34:48 -0700 Subject: [PATCH] Bug 1038844 - Flip the scary automation pref for crashtests and marionette. r=jgriffin --- layout/tools/reftest/runreftest.py | 2 ++ testing/marionette/marionette-server.js | 3 +++ 2 files changed, 5 insertions(+) diff --git a/layout/tools/reftest/runreftest.py b/layout/tools/reftest/runreftest.py index f325e2452c5..07aa54339b1 100644 --- a/layout/tools/reftest/runreftest.py +++ b/layout/tools/reftest/runreftest.py @@ -197,6 +197,8 @@ class RefTest(object): # release engineering and landing on multiple branches at once. if special_powers and (manifest.endswith('crashtests.list') or manifest.endswith('jstests.list')): addons.append(os.path.join(SCRIPT_DIRECTORY, 'specialpowers')) + # SpecialPowers requires insecure automation-only features that we put behind a pref. + prefs['security.turn_off_all_security_so_that_viruses_can_take_over_this_computer'] = True # Install distributed extensions, if application has any. distExtDir = os.path.join(options.app[ : options.app.rfind(os.sep)], "distribution", "extensions") diff --git a/testing/marionette/marionette-server.js b/testing/marionette/marionette-server.js index 2dc4b6cefd6..0b0ff278da1 100644 --- a/testing/marionette/marionette-server.js +++ b/testing/marionette/marionette-server.js @@ -23,6 +23,9 @@ loader.loadSubScript("chrome://marionette/content/EventUtils.js", utils); loader.loadSubScript("chrome://marionette/content/ChromeUtils.js", utils); loader.loadSubScript("chrome://marionette/content/atoms.js", utils); +// SpecialPowers requires insecure automation-only features that we put behind a pref. +Services.prefs.setBoolPref('security.turn_off_all_security_so_that_viruses_can_take_over_this_computer', + true); let specialpowers = {}; loader.loadSubScript("chrome://specialpowers/content/SpecialPowersObserver.js", specialpowers);