summaryrefslogtreecommitdiffstats
path: root/application/palemoon/base/content/content.js
diff options
context:
space:
mode:
Diffstat (limited to 'application/palemoon/base/content/content.js')
-rw-r--r--application/palemoon/base/content/content.js13
1 files changed, 8 insertions, 5 deletions
diff --git a/application/palemoon/base/content/content.js b/application/palemoon/base/content/content.js
index 3587bbeef..19c8b0682 100644
--- a/application/palemoon/base/content/content.js
+++ b/application/palemoon/base/content/content.js
@@ -3,9 +3,9 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
-let Cc = Components.classes;
-let Ci = Components.interfaces;
-let Cu = Components.utils;
+var Cc = Components.classes;
+var Ci = Components.interfaces;
+var Cu = Components.utils;
Cu.import("resource://gre/modules/XPCOMUtils.jsm");
@@ -13,6 +13,8 @@ XPCOMUtils.defineLazyModuleGetter(this, "BrowserUtils",
"resource://gre/modules/BrowserUtils.jsm");
XPCOMUtils.defineLazyModuleGetter(this, "LoginManagerContent",
"resource://gre/modules/LoginManagerContent.jsm");
+XPCOMUtils.defineLazyModuleGetter(this, "LoginFormFactory",
+ "resource://gre/modules/LoginManagerContent.jsm");
XPCOMUtils.defineLazyModuleGetter(this, "InsecurePasswordUtils",
"resource://gre/modules/InsecurePasswordUtils.jsm");
XPCOMUtils.defineLazyModuleGetter(this, "FormSubmitObserver",
@@ -47,8 +49,9 @@ addMessageListener("Browser:HideSessionRestoreButton", function (message) {
});
addEventListener("DOMFormHasPassword", function(event) {
- InsecurePasswordUtils.checkForInsecurePasswords(event.target);
- LoginManagerContent.onFormPassword(event);
+ LoginManagerContent.onDOMFormHasPassword(event, content);
+ let formLike = LoginFormFactory.createFromForm(event.target);
+ InsecurePasswordUtils.reportInsecurePasswords(formLike);
});
addEventListener("DOMAutoComplete", function(event) {
LoginManagerContent.onUsernameInput(event);