mirror of
https://github.com/bitwarden/browser.git
synced 2024-11-22 11:45:59 +01:00
[PM-8858] include only 1 digit in passphrase (#9632)
This commit is contained in:
parent
4e19c3ef52
commit
95554af9e2
@ -20,8 +20,8 @@ export class CryptoServiceRandomizer implements Randomizer {
|
||||
}
|
||||
|
||||
if (options?.number ?? false) {
|
||||
const num = await this.crypto.randomNumber(1, 9999);
|
||||
word = word + this.zeroPad(num.toString(), 4);
|
||||
const num = await this.crypto.randomNumber(1, 9);
|
||||
word = word + num.toString();
|
||||
}
|
||||
|
||||
return word;
|
||||
|
@ -20,8 +20,8 @@ export class CryptoServiceRandomizer implements Randomizer {
|
||||
}
|
||||
|
||||
if (options?.number ?? false) {
|
||||
const num = await this.crypto.randomNumber(1, 9999);
|
||||
word = word + this.zeroPad(num.toString(), 4);
|
||||
const num = await this.crypto.randomNumber(1, 9);
|
||||
word = word + num.toString();
|
||||
}
|
||||
|
||||
return word;
|
||||
|
Loading…
Reference in New Issue
Block a user