summaryrefslogtreecommitdiffstats
path: root/security/manager/pki/resources
diff options
context:
space:
mode:
Diffstat (limited to 'security/manager/pki/resources')
-rw-r--r--security/manager/pki/resources/content/clientauthask.js18
1 files changed, 13 insertions, 5 deletions
diff --git a/security/manager/pki/resources/content/clientauthask.js b/security/manager/pki/resources/content/clientauthask.js
index e9df667dbe..e8b746ab34 100644
--- a/security/manager/pki/resources/content/clientauthask.js
+++ b/security/manager/pki/resources/content/clientauthask.js
@@ -46,7 +46,7 @@ var certArray;
*
* @type {HTMLInputElement} Element checkbox, has to have |checked| property.
*/
-var rememberBox;
+var rememberBox, args;
async function onLoad() {
let rememberSetting = Services.prefs.getBoolPref(
@@ -55,12 +55,20 @@ async function onLoad() {
rememberBox = document.getElementById("rememberBox");
rememberBox.checked = rememberSetting;
- certArray = window.arguments[0].certArray;
+ let propBag = window.arguments[0]
+ .QueryInterface(Ci.nsIWritablePropertyBag2)
+ .QueryInterface(Ci.nsIWritablePropertyBag);
+ args = {};
+ for (let prop of propBag.enumerator) {
+ args[prop.name] = prop.value;
+ }
+
+ certArray = args.certArray;
document.l10n.setAttributes(
document.getElementById("clientAuthSiteIdentification"),
"client-auth-site-identification",
- { hostname: window.arguments[0].hostname }
+ { hostname: args.hostname }
);
let selectElement = document.getElementById("nicknames");
@@ -148,7 +156,7 @@ async function onCertSelected() {
}
function doOK() {
- let { retVals } = window.arguments[0];
+ let { retVals } = args;
let index = parseInt(document.getElementById("nicknames").value);
let cert = certArray[index];
retVals.cert = cert;
@@ -156,7 +164,7 @@ function doOK() {
}
function doCancel() {
- let { retVals } = window.arguments[0];
+ let { retVals } = args;
retVals.cert = null;
retVals.rememberDecision = rememberBox.checked;
}