I am working on a PasswordPolicyProvider SPI intended to implement a minimum-password-lifetime. My issue is that I don’t want “admin” users to be restricted by this SPI when resetting a user’s password. Is there a way to extract some info about the user triggering the password reset from the KeycloakSession object? I was also thinking that if I could restrict the enforcement of this SPI by checking whether the password is intended to be temporary, which only an “admin” would be able to set, but I can’t seem to get find that flag either.
Related topics
| Topic | Replies | Views | Activity | |
|---|---|---|---|---|
| Is there any way to retrieve the password in keycloak | 2 | 423 | March 3, 2023 | |
| Fetch User Password Expiry Date | 2 | 1108 | July 28, 2021 | |
| Keycloak API Rest - check if password is correct | 6 | 2084 | February 22, 2024 | |
| Usersessionmodel (current session) always null | 1 | 512 | October 5, 2020 | |
| Get user password in getUserByUsername method of User Storage SPI | 0 | 378 | February 13, 2023 |