From 3315f2a277df355c009b21805b080ba8746f1349 Mon Sep 17 00:00:00 2001 From: Wil Clouser Date: Tue, 9 Aug 2016 15:15:01 -0700 Subject: [PATCH] Bug 1288178 - add Test Pilot to mozAddonManager allow list r=rhelmer MozReview-Commit-ID: Klx75vFhKUI --HG-- extra : rebase_source : d488675eea0504b4af4fd1cb9278a44bb9564fbe --- toolkit/mozapps/extensions/AddonManager.jsm | 3 ++- toolkit/mozapps/extensions/AddonManagerWebAPI.cpp | 5 ++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/toolkit/mozapps/extensions/AddonManager.jsm b/toolkit/mozapps/extensions/AddonManager.jsm index 932685e1fc78..1210d72ec56c 100644 --- a/toolkit/mozapps/extensions/AddonManager.jsm +++ b/toolkit/mozapps/extensions/AddonManager.jsm @@ -67,10 +67,11 @@ const TOOLKIT_ID = "toolkit@mozilla.org"; const VALID_TYPES_REGEXP = /^[\w\-]+$/; -const WEBAPI_INSTALL_HOSTS = ["addons.mozilla.org", "addons.cdn.mozilla.net"]; +const WEBAPI_INSTALL_HOSTS = ["addons.mozilla.org", "addons.cdn.mozilla.net", "testpilot.firefox.com"]; const WEBAPI_TEST_INSTALL_HOSTS = [ "addons.allizom.org", "addons-stage-cdn.allizom.org", "addons-dev.allizom.org", "addons-dev-cdn-allizom.org", + "testpilot.stage.mozaws.net", "testpilot.dev.mozaws.net", "example.com", ]; diff --git a/toolkit/mozapps/extensions/AddonManagerWebAPI.cpp b/toolkit/mozapps/extensions/AddonManagerWebAPI.cpp index 2c507b71f722..e51f5bf112a2 100644 --- a/toolkit/mozapps/extensions/AddonManagerWebAPI.cpp +++ b/toolkit/mozapps/extensions/AddonManagerWebAPI.cpp @@ -40,7 +40,8 @@ AddonManagerWebAPI::IsValidSite(nsIURI* uri) } if (host.Equals("addons.mozilla.org") || - host.Equals("discovery.addons.mozilla.org")) { + host.Equals("discovery.addons.mozilla.org") || + host.Equals("testpilot.firefox.com")) { return true; } @@ -50,6 +51,8 @@ AddonManagerWebAPI::IsValidSite(nsIURI* uri) host.Equals("discovery.addons.allizom.org") || host.Equals("addons-dev.allizom.org") || host.Equals("discovery.addons-dev.allizom.org") || + host.Equals("testpilot.stage.mozaws.net") || + host.Equals("testpilot.dev.mozaws.net") || host.Equals("example.com")) { return true; }