-
Notifications
You must be signed in to change notification settings - Fork 7.7k
Description
Before reporting an issue
- I have read and understood the above terms for submitting issues, and I understand that my issue may be closed without action if I do not follow them.
Area
ldap
Describe the bug
Existing users that came from LDAP with uppercase letters in their usernames can't log in anymore using stored credentials like Passkeys or totp. Additionally downstream apps that honor casing on the oidc subject will not recognize the user anymore.
There might be more issues (SAML, others) but i have only encountered the described behavior.
This is most likely caused by the following issues/PRs:
- Make sure username and email attributes are lower cased when fetching their values from LDAP object #43254
- Lowercase username and email when fetching values from LDAP object #43261
Version
25.4.1
Regression
- The issue is a regression
Expected behavior
Users are still able to login as normal after a patch update. The user ID should stay stable and not change.
Actual behavior
The user ID changes uppercase letters to lowercase letters.
How to Reproduce?
- Set up a Keycloak with a version < 25.4.1
- Set up LDAP federation
- log in users that contain capital letters in their username
- Potentially register passkeys.
- Upgrade keycloak to 25.4.1 and notice the changed user ID.
- Try to log in the user with passekey
Anything else?
I understand the need to change the need to normalize usernames, however i think this should be rolled back and reintroduced as a breaking change, not a patch.
Of course there is also the discussion if case sensitivity should even be allowed: #32869