Branch: refs/heads/master
Home: https://github.com/xwiki/xwiki-platform
Commit: 539f97b0d6f8f9e049abe2a0c5321e41a137ffa0
https://github.com/xwiki/xwiki-platform/commit/539f97b0d6f8f9e049abe2a0c532…
Author: Simon Urli <simon.urli(a)xwiki.com>
Date: 2023-11-14 (Tue, 14 Nov 2023)
Changed paths:
M xwiki-platform-core/xwiki-platform-administration/xwiki-platform-administration-test/xwiki-platform-administration-test-docker/src/test/it/org/xwiki/administration/test/ui/RegisterIT.java
M xwiki-platform-core/xwiki-platform-administration/xwiki-platform-administration-ui/src/main/resources/XWiki/Registration.xml
M xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/XWiki.java
M xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/web/RegisterAction.java
M xwiki-platform-core/xwiki-platform-oldcore/src/main/resources/ApplicationResources.properties
A xwiki-platform-core/xwiki-platform-security/xwiki-platform-security-authentication/xwiki-platform-security-authentication-api/src/main/java/org/xwiki/security/authentication/RegistrationConfiguration.java
M xwiki-platform-core/xwiki-platform-security/xwiki-platform-security-authentication/xwiki-platform-security-authentication-api/src/main/java/org/xwiki/security/authentication/ResetPasswordManager.java
A xwiki-platform-core/xwiki-platform-security/xwiki-platform-security-authentication/xwiki-platform-security-authentication-default/src/main/java/org/xwiki/security/authentication/internal/DefaultRegistrationConfiguration.java
M xwiki-platform-core/xwiki-platform-security/xwiki-platform-security-authentication/xwiki-platform-security-authentication-default/src/main/java/org/xwiki/security/authentication/internal/DefaultResetPasswordManager.java
A xwiki-platform-core/xwiki-platform-security/xwiki-platform-security-authentication/xwiki-platform-security-authentication-default/src/main/java/org/xwiki/security/authentication/internal/RegistrationConfigurationSource.java
M xwiki-platform-core/xwiki-platform-security/xwiki-platform-security-authentication/xwiki-platform-security-authentication-default/src/main/resources/ApplicationResources.properties
M xwiki-platform-core/xwiki-platform-security/xwiki-platform-security-authentication/xwiki-platform-security-authentication-default/src/main/resources/META-INF/components.txt
A xwiki-platform-core/xwiki-platform-security/xwiki-platform-security-authentication/xwiki-platform-security-authentication-default/src/test/java/org/xwiki/security/authentication/internal/DefaultRegistrationConfigurationTest.java
M xwiki-platform-core/xwiki-platform-security/xwiki-platform-security-authentication/xwiki-platform-security-authentication-default/src/test/java/org/xwiki/security/authentication/internal/DefaultResetPasswordManagerTest.java
A xwiki-platform-core/xwiki-platform-security/xwiki-platform-security-authentication/xwiki-platform-security-authentication-script/src/main/java/org/xwiki/security/authentication/script/RegistrationScriptService.java
M xwiki-platform-core/xwiki-platform-security/xwiki-platform-security-authentication/xwiki-platform-security-authentication-script/src/main/resources/META-INF/components.txt
A xwiki-platform-core/xwiki-platform-security/xwiki-platform-security-authentication/xwiki-platform-security-authentication-script/src/test/java/org/xwiki/security/authentication/script/RegistrationScriptServiceTest.java
M xwiki-platform-core/xwiki-platform-test/xwiki-platform-test-ui/src/main/java/org/xwiki/test/ui/po/AbstractRegistrationPage.java
M xwiki-platform-core/xwiki-platform-web/xwiki-platform-web-templates/src/main/resources/templates/passwd.vm
M xwiki-platform-core/xwiki-platform-web/xwiki-platform-web-templates/src/main/resources/templates/register_macros.vm
M xwiki-platform-core/xwiki-platform-web/xwiki-platform-web-templates/src/main/resources/templates/registerinline.vm
M xwiki-platform-core/xwiki-platform-web/xwiki-platform-web-templates/src/main/resources/templates/resetpasswordinline.vm
Log Message:
-----------
XWIKI-17510: The reset password functionality is not affected by password strength rules (#2488)
This work mainly provides new Java APIs to access information from RegistrationConfiguration. It also provides a new API to check that the policy for the passwords is respected, and use that new API for user creation. This fixes a bug when creating a new user in private wiki. Note that this PR doesn't provide an API for all information exposed in RegistrationConfiguration: specifically all configuration related to velocity scripts are not exposed.
This PR also improves the default template used for registration to enable live validation, and allows to see captcha, and fixes a few bug when using registration without a RegistrationConfig xobject.
Most of those scenario are now covered in the integration tests which is checking if the registration works in open/close wiki, with and without a RegistrationConfig page.
* Provide new APIs for accessing RegistrationConfiguration
* Define a script service to access this API from scripts
* Rewrite velocity macro #loadConfig to exploit this new API and to
remove unused arguments
* Use the new API also in oldcore where needed
* Provide new API in ResetPasswordManager to allow ensuring a password
is compliant with the registration rules on backend
* Fix bugs and perform improvments on templates
* Add a new integration test for checking password policy
* Get rid of the testing without livevalidation as we don't have that
option anymore
* Improve integration test to also test with and without the
RegistrationConfig page
---------
Co-authored-by: Manuel Leduc <manuel.leduc(a)xwiki.com>
Branch: refs/heads/XWIKI-17510
Home: https://github.com/xwiki/xwiki-platform
Commit: 5a5efafeb2b7512af5ede0110a6bc4082676f2dc
https://github.com/xwiki/xwiki-platform/commit/5a5efafeb2b7512af5ede0110a6b…
Author: Simon Urli <simon.urli(a)xwiki.com>
Date: 2023-11-14 (Tue, 14 Nov 2023)
Changed paths:
M xwiki-platform-core/xwiki-platform-administration/xwiki-platform-administration-test/xwiki-platform-administration-test-docker/src/test/it/org/xwiki/administration/test/ui/RegisterIT.java
Log Message:
-----------
XWIKI-17510: The reset password functionality is not affected by password strength rules
* Minor documentation improvment in test