altcha 3.0.0 → 3.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -4
- package/dist/external/altcha.js +1 -1
- package/dist/external/altcha.min.js +1 -1
- package/dist/external/altcha.umd.cjs +1 -1
- package/dist/external/altcha.umd.min.cjs +1 -1
- package/dist/lib/index.js +4 -2
- package/dist/lib/index.min.js +1 -1
- package/dist/lib/index.umd.cjs +4 -2
- package/dist/lib/index.umd.min.cjs +1 -1
- package/dist/main/altcha.i18n.js +9 -5
- package/dist/main/altcha.i18n.min.js +1 -1
- package/dist/main/altcha.i18n.umd.cjs +9 -5
- package/dist/main/altcha.i18n.umd.min.cjs +1 -1
- package/dist/main/altcha.js +9 -5
- package/dist/main/altcha.min.js +1 -1
- package/dist/main/altcha.umd.cjs +9 -5
- package/dist/main/altcha.umd.min.cjs +1 -1
- package/dist/plugins/obfuscation.plugin.js +4 -2
- package/dist/plugins/obfuscation.plugin.min.js +1 -1
- package/dist/plugins/obfuscation.plugin.umd.cjs +4 -2
- package/dist/plugins/obfuscation.plugin.umd.min.cjs +1 -1
- package/dist/workers/argon2id.js +4 -2
- package/dist/workers/pbkdf2.js +4 -2
- package/dist/workers/scrypt.js +4 -2
- package/dist/workers/sha.js +4 -2
- package/package.json +1 -1
|
@@ -6044,7 +6044,7 @@
|
|
|
6044
6044
|
}
|
|
6045
6045
|
});
|
|
6046
6046
|
onMount(() => {
|
|
6047
|
-
log("mounted", "3.0.
|
|
6047
|
+
log("mounted", "3.0.2");
|
|
6048
6048
|
if (instance) {
|
|
6049
6049
|
globalThis.$altcha.instances.add(instance);
|
|
6050
6050
|
}
|
|
@@ -7127,10 +7127,11 @@
|
|
|
7127
7127
|
const password = new PasswordBuffer(nonceBuf, counterMode);
|
|
7128
7128
|
const start = performance.now();
|
|
7129
7129
|
let counter = counterStart;
|
|
7130
|
+
let iterations = 0;
|
|
7130
7131
|
let derivedKeyHex = "";
|
|
7131
7132
|
let lastYield = start;
|
|
7132
7133
|
while (true) {
|
|
7133
|
-
if (controller?.signal.aborted || timeout &&
|
|
7134
|
+
if (controller?.signal.aborted || timeout && iterations % 10 === 0 && performance.now() - start > timeout) {
|
|
7134
7135
|
return null;
|
|
7135
7136
|
}
|
|
7136
7137
|
const { derivedKey } = await deriveKey2(
|
|
@@ -7138,7 +7139,7 @@
|
|
|
7138
7139
|
saltBuf,
|
|
7139
7140
|
password.setCounter(counter)
|
|
7140
7141
|
);
|
|
7141
|
-
if (
|
|
7142
|
+
if (iterations % 10 === 0 && performance.now() - lastYield > 200) {
|
|
7142
7143
|
await delay(0);
|
|
7143
7144
|
lastYield = performance.now();
|
|
7144
7145
|
}
|
|
@@ -7147,6 +7148,7 @@
|
|
|
7147
7148
|
break;
|
|
7148
7149
|
}
|
|
7149
7150
|
counter = counter + counterStep;
|
|
7151
|
+
iterations = iterations + 1;
|
|
7150
7152
|
}
|
|
7151
7153
|
return {
|
|
7152
7154
|
counter,
|
|
@@ -7327,10 +7329,11 @@
|
|
|
7327
7329
|
const password = new PasswordBuffer(nonceBuf, counterMode);
|
|
7328
7330
|
const start = performance.now();
|
|
7329
7331
|
let counter = counterStart;
|
|
7332
|
+
let iterations = 0;
|
|
7330
7333
|
let derivedKeyHex = "";
|
|
7331
7334
|
let lastYield = start;
|
|
7332
7335
|
while (true) {
|
|
7333
|
-
if (controller?.signal.aborted || timeout &&
|
|
7336
|
+
if (controller?.signal.aborted || timeout && iterations % 10 === 0 && performance.now() - start > timeout) {
|
|
7334
7337
|
return null;
|
|
7335
7338
|
}
|
|
7336
7339
|
const { derivedKey } = await deriveKey2(
|
|
@@ -7338,7 +7341,7 @@
|
|
|
7338
7341
|
saltBuf,
|
|
7339
7342
|
password.setCounter(counter)
|
|
7340
7343
|
);
|
|
7341
|
-
if (
|
|
7344
|
+
if (iterations % 10 === 0 && performance.now() - lastYield > 200) {
|
|
7342
7345
|
await delay(0);
|
|
7343
7346
|
lastYield = performance.now();
|
|
7344
7347
|
}
|
|
@@ -7347,6 +7350,7 @@
|
|
|
7347
7350
|
break;
|
|
7348
7351
|
}
|
|
7349
7352
|
counter = counter + counterStep;
|
|
7353
|
+
iterations = iterations + 1;
|
|
7350
7354
|
}
|
|
7351
7355
|
return {
|
|
7352
7356
|
counter,
|