Bug 1295324 r=kmag a=al,ritu
authorAndrew Swan <aswan@mozilla.com>
Fri, 07 Oct 2016 11:20:12 -0700
changeset 350609 e6bc67cc7d76b0f040220663aac7a208cebedba5
parent 350608 9f5ef22fc76fcfe7cdd48ab0e6cf8733e4279f30
child 350610 7e1133eb4dbe8a4aebc2d5f648fb877494b01b83
push id1230
push userjlund@mozilla.com
push dateMon, 31 Oct 2016 18:13:35 +0000
treeherdermozilla-release@5e06e3766db2 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskmag, al, ritu
bugs1295324
milestone50.0
Bug 1295324 r=kmag a=al,ritu MozReview-Commit-ID: GN4Bc8RZQBn
toolkit/components/extensions/ExtensionContent.jsm
--- a/toolkit/components/extensions/ExtensionContent.jsm
+++ b/toolkit/components/extensions/ExtensionContent.jsm
@@ -183,16 +183,23 @@ Script.prototype = {
       urls.push(url);
     }
 
     return urls;
   },
 
   matches(window) {
     let uri = window.document.documentURIObject;
+
+    // If mozAddonManager is present on this page, don't allow
+    // content scripts.
+    if (window.navigator.mozAddonManager !== undefined) {
+      return false;
+    }
+
     if (!(this.matches_.matches(uri) || this.matches_host_.matchesIgnoringPath(uri))) {
       return false;
     }
 
     if (this.exclude_matches_.matches(uri)) {
       return false;
     }