feat(core): Check password strength on login (SQL Source). Closes #6025

This commit is contained in:
smizrahi
2024-12-02 10:59:51 +01:00
parent 5030922a7c
commit fe6836084e
9 changed files with 20 additions and 30 deletions
@@ -132,10 +132,3 @@ See <a href=\"http://www.sogo.nu/en/support/community.html\">this page</a> for v
"Password recovery email in error" = "Password recovery email in error";
"Password reset" = "Password reset";
"Hi %{0},\nThere was a request to change your password!\n\nIf you did not make this request then please ignore this email.\n\nOtherwise, please click this link to change your password: %{1}" = "Hi %{0},\nThere was a request to change your password!\n\nIf you did not make this request then please ignore this email.\n\nOtherwise, please click this link to change your password: %{1}";
/* Password */
"POLICY_MIN_LOWERCASE_LETTER" = "Minimum of %{0} lowercase letter";
"POLICY_MIN_UPPERCASE_LETTER" = "Minimum of %{0} uppercase letter";
"POLICY_MIN_DIGIT" = "Minimum of %{0} digit";
"POLICY_MIN_SPECIAL_SYMBOLS" = "Minimum of %{0} special symbols";
"POLICY_MIN_LENGTH" = "Minimum length of %{0} characters";
@@ -129,10 +129,3 @@
"Password recovery email in error" = "Erreur lors de l'envoi de l'email de récupération";
"Password reset" = "Réinitialisation de mot de passe";
"Hi %{0},\nThere was a request to change your password!\n\nIf you did not make this request then please ignore this email.\n\nOtherwise, please click this link to change your password: %{1}" = "Bonjour %{0},\nUne demande de changement de mot de passe a été initiée.\n\nSi vous n'êtes pas à l'origine de cet e-mail, n'en tenez pas compte.\n\nSi vous en êtes bien à l'origine, veuillez cliquer sur le lien ci-dessous pour modifier votre mot de passe: %{1}";
/* Password */
"POLICY_MIN_LOWERCASE_LETTER" = "Au moins %{0} lettre(s) minuscule(s)";
"POLICY_MIN_UPPERCASE_LETTER" = "Au moins %{0} lettre(s) majuscule(s)";
"POLICY_MIN_DIGIT" = "Au moins %{0} chiffre(s)";
"POLICY_MIN_SPECIAL_SYMBOLS" = "Au moins %{0} caractère(s) special(aux)";
"POLICY_MIN_LENGTH" = "Longueur d'au moins %{0} caractère(s)";
+1 -1
View File
@@ -219,7 +219,7 @@ static const NSString *kJwtKey = @"jwt";
if ([*additionalLoginInformations objectForKey:@"userPolicies"]) {
translations = [[NSMutableDictionary alloc] init];
for (policy in [*additionalLoginInformations objectForKey:@"userPolicies"]) {
[translations setObject:[self labelForKey: [policy objectForKey:@"label"]] forKey: [policy objectForKey:@"label"]];
[translations setObject:[self commonLabelForKey: [policy objectForKey:@"label"]] forKey: [policy objectForKey:@"label"]];
}
[*additionalLoginInformations setObject:[SOGoPasswordPolicy createPasswordPolicyLabels: [*additionalLoginInformations objectForKey:@"userPolicies"] withTranslations: translations]
forKey:@"userPolicies"];