I’m facing an issue after upgrading Keycloak from version 18 to 26.
After the upgrade, users are unable to log in and receive “Invalid user credentials”.
Here is what I observed:
• Existing users in the database have passwords hashed with PBKDF2-SHA256.
• After upgrading to Keycloak 26, newly reset passwords are stored using Argon2.
• When I reset a user’s password, login works correctly.
• However, migrated users with PBKDF2 hashes cannot log in.
It seems like during authentication Keycloak is trying to verify the old PBKDF2 hashes using Argon2 instead of the original algorithm.
I cannot reset passwords for all users because there are many of them.
My questions:
- Should Keycloak 26 automatically support verifying existing PBKDF2 hashes after upgrade?
- Do I need to explicitly enable PBKDF2 as a password policy in the new version?
- Is there any recommended migration strategy for password hash algorithms when upgrading to Argon2?
I would really appreciate any guidance on how to properly handle this migration without forcing all users to reset their passwords.