Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var wm = Components.classes["@mozilla.org/appshell/window-mediator;1"]
- .getService(Components.interfaces.nsIWindowMediator);
- var recentWindow = wm.getMostRecentWindow("navigator:browser");
- var domWin = recentWindow.content.document.defaultView.top;
- var location = domWin.document.baseURIObject.asciiSpec;
- if(location.substr(0, 15) == "about:certerror"){
- //recentWindow.alert("Rule broken. From: " + document.getElementById("urlbar").value + " To: " + domWin.location);
- var alist = HTTPSRules.potentiallyApplicableRulesets(document.getElementById("urlbar").value);
- https_everywhere = CC["@eff.org/https-everywhere;1"].getService(Components.interfaces.nsISupports).wrappedJSObject;
- o_httpsprefs = https_everywhere.get_prefs();
- for (var i = 0 ; i < alist.length ; i++){
- //recentWindow.alert(alist[i].name + " " + alist[i].id);
- //this.active_rule(alist[i]);
- if(o_httpsprefs.getBoolPref(alist[i].name))
- this.active_rule(alist[i]);
- else
- this.inactive_rule(alist[i]);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement