Skip to content

Commit c643873

Browse files
authored
feat(RED-DA): new password strength policy (#5848)
* feat(RED-DA): new password strength policy * test: use correct password according to new rules * style: fix copyright header
1 parent 98d2062 commit c643873

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

kura/org.eclipse.kura.core.identity/src/main/java/org/eclipse/kura/core/identity/PasswordStrengthVerificationServiceOptions.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,19 +26,19 @@
2626
@AttributeDefinition(name = "Minimum password length", //
2727
min = "0", //
2828
description = "The minimum length to be enforced for new passwords. Set to 0 to disable.")
29-
public int new_password_min_length() default 8;
29+
public int new_password_min_length() default 12;
3030

3131
@AttributeDefinition(name = "Require digits in new password", //
3232
description = "If set to true, new passwords will be accepted only if containing at least one digit.")
33-
public boolean new_password_require_digits() default false;
33+
public boolean new_password_require_digits() default true;
3434

3535
@AttributeDefinition(name = "Require special characters in new password", //
3636
description = "If set to true, new passwords will be accepted only if containing at least one non alphanumeric character.")
37-
public boolean new_password_require_special_characters() default false;
37+
public boolean new_password_require_special_characters() default true;
3838

3939
@AttributeDefinition(name = "Require uppercase and lowercase characters in new passwords", //
4040
description = "If set to true, new passwords will be accepted only if containing both"
4141
+ " uppercase and lowercase alphanumeric characters.")
42-
public boolean new_password_require_both_cases() default false;
42+
public boolean new_password_require_both_cases() default true;
4343

4444
}

kura/test/org.eclipse.kura.rest.identity.provider.test/src/main/java/org/eclipse/kura/internal/rest/identity/provider/test/IdentityV2EndpointsTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*******************************************************************************
2-
* Copyright (c) 2024 Eurotech and/or its affiliates and others
2+
* Copyright (c) 2024, 2025 Eurotech and/or its affiliates and others
33
*
44
* This program and the accompanying materials are made
55
* available under the terms of the Eclipse Public License 2.0
@@ -145,7 +145,7 @@ public void shouldUpdateIdentityWithConfiguration() throws KuraException {
145145
givenMockIdentityConfigurationExtension("test2.extension");
146146

147147
givenPermissionConfiguration(this.testPermissionName);
148-
givenPasswordConfiguration("abcdef1234567", true, false);
148+
givenPasswordConfiguration("Abcdef1234567@", true, false);
149149
givenAdditionalConfigurations(TestComponentConfiguration.forPid("test.extension"),
150150
TestComponentConfiguration.forPid("test2.extension"));
151151

0 commit comments

Comments
 (0)