aboutsummaryrefslogtreecommitdiffstats
path: root/apps/twofactor_backupcodes/lib
diff options
context:
space:
mode:
authorRoeland Jago Douma <roeland@famdouma.nl>2019-10-21 21:51:17 +0200
committerRoeland Jago Douma <roeland@famdouma.nl>2019-10-22 12:25:39 +0200
commitd878130fb292d8e38d0cd86089bf6aa1524e034a (patch)
treeb53256c2dbddae6d34926c44ceb68f44c3e46745 /apps/twofactor_backupcodes/lib
parent923735021b35d08aadf00cb30e3e9eda42f50a50 (diff)
downloadnextcloud-server-d878130fb292d8e38d0cd86089bf6aa1524e034a.tar.gz
nextcloud-server-d878130fb292d8e38d0cd86089bf6aa1524e034a.zip
Only human readbale backup chars
Fixes #14811 Only use humand readable chars (so no I and 1 etc) Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'apps/twofactor_backupcodes/lib')
-rw-r--r--apps/twofactor_backupcodes/lib/Service/BackupCodeStorage.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/twofactor_backupcodes/lib/Service/BackupCodeStorage.php b/apps/twofactor_backupcodes/lib/Service/BackupCodeStorage.php
index 88117c37ec0..7842dd610be 100644
--- a/apps/twofactor_backupcodes/lib/Service/BackupCodeStorage.php
+++ b/apps/twofactor_backupcodes/lib/Service/BackupCodeStorage.php
@@ -72,7 +72,7 @@ class BackupCodeStorage {
$uid = $user->getUID();
foreach (range(1, min([$number, 20])) as $i) {
- $code = $this->random->generate(self::$CODE_LENGTH, ISecureRandom::CHAR_UPPER . ISecureRandom::CHAR_DIGITS);
+ $code = $this->random->generate(self::$CODE_LENGTH, ISecureRandom::CHAR_HUMAN_READABLE);
$dbCode = new BackupCode();
$dbCode->setUserId($uid);