diff --git a/lib/Db/SSOMapper.php b/lib/Db/SSOMapper.php index 3c04b982c936f762a661da7db15436e032c5ecfc..89f4af886efdb0ac651800dc334ec34f6cda1eed 100644 --- a/lib/Db/SSOMapper.php +++ b/lib/Db/SSOMapper.php @@ -58,7 +58,7 @@ class SSOMapper { $qb->delete(self::CREDENTIAL_TABLE) ->where('USER_ID = :username') ->andWhere('TYPE = "otp"') - ->andWhere('CREDENTIAL_DATA LIKE "%\"subType\":\"nextcloud_totp\"%" OR CREDENTIAL_DATA LIKE "%\"subType\":\"totp\"%"') + ->andWhere('CREDENTIAL_DATA LIKE "%\"subType\":\"totp\"%"') ->setParameter('username', $userId) ->execute(); } @@ -112,10 +112,11 @@ class SSOMapper { 'value' => $secret ]), 'CREDENTIAL_DATA' => json_encode([ - 'subType' => 'nextcloud_totp', + 'subType' => 'totp', 'period' => 30, 'digits' => 6, 'algorithm' => 'HmacSHA1', + 'secretEncoding' => 'BASE32', ]), ];