summaryrefslogtreecommitdiff
path: root/www/keygenIE.js
diff options
context:
space:
mode:
Diffstat (limited to 'www/keygenIE.js')
-rw-r--r--www/keygenIE.js20
1 files changed, 14 insertions, 6 deletions
diff --git a/www/keygenIE.js b/www/keygenIE.js
index 50faf76..be2d184 100644
--- a/www/keygenIE.js
+++ b/www/keygenIE.js
@@ -167,6 +167,8 @@ var CAcert_keygen_IE = function () {
/// Fill the algorithm list
var getAlgorithmList = function () {
+ var i;
+
if (!providerList) {
return false;
}
@@ -182,7 +184,7 @@ var CAcert_keygen_IE = function () {
);
removeChildren(algorithm);
- for (var i = 0; i < cspStats.Count; i++) {
+ for (i = 0; i < cspStats.Count; i++) {
var alg = cspStats.ItemByIndex(i).CspAlgorithm;
algorithm.appendChild(option(alg.Name, i));
}
@@ -192,6 +194,8 @@ var CAcert_keygen_IE = function () {
/// Fill the crypto provider list
var getProviderList = function () {
+ var i;
+
var csps = factory.CreateObject("X509Enrollment.CCspInformations");
// Get provider information
@@ -199,7 +203,7 @@ var CAcert_keygen_IE = function () {
removeChildren(provider);
- for (var i = 0; i < csps.Count; i++) {
+ for (i = 0; i < csps.Count; i++) {
var csp = csps.ItemByIndex(i);
provider.appendChild(option(csp.Name, i));
}
@@ -473,12 +477,14 @@ var CAcert_keygen_IE = function () {
/// Fill the algorithm selection box
var getAlgorithmList = function () {
+ var i, j;
+
refreshProvider();
removeChildren(algorithm);
- for (var i = 0; i < algClasses.length; ++i) {
- for (var j = 0; true; ++j) {
+ for (i = 0; i < algClasses.length; ++i) {
+ for (j = 0; true; ++j) {
try {
var algId = cenroll.EnumAlgs(j, algClasses[i]);
var algName = cenroll.GetAlgName(algId);
@@ -494,13 +500,15 @@ var CAcert_keygen_IE = function () {
/// Fill the provider selection box
var getProviderList = function () {
+ var i, j;
+
removeChildren(provider);
- for (var i = 0; i < providerTypes.length; ++i) {
+ for (i = 0; i < providerTypes.length; ++i) {
cenroll.providerType = providerTypes[i];
var providerName = "invalid";
- for (var j = 0; true; ++j) {
+ for (j = 0; true; ++j) {
try {
providerName = cenroll.enumProviders(j, 0);
provider.appendChild(option(providerName, providerTypes[i]));