8000 Restore LDAP connection URL failover for user authentication by tkyjovsk · Pull Request #55817 · keycloak/keycloak · GitHub
[go: up one dir, main page]

Skip to content

Restore LDAP connection URL failover for user authentication - #55817

Open
tkyjovsk wants to merge 1 commit into
keycloak:release/26.8from
tkyjovsk:release/26.8-55322
Open

tkyjovsk wants to merge 1 commit into
keycloak:release/26.8from
tkyjovsk:release/26.8-55322

Conversation

@tkyjovsk
@tkyjovsk tkyjovsk commented Dec 4, 2026
Copy link
Copy Markdown
Contributor

Closes #55322

  • Since the forced password change support for LDAP users, LDAPOperationManager.authenticate() created the LDAP context without credentials and bound later via reconnect(). JNDI only iterates over multiple space-separated connection URLs during context creation, so a primary server accepting TCP but failing or hanging on bind no longer failed over to the next URL. When StartTLS is not used, bind during context creation again, passing the password policy request control as connection control.

  • Change server socket address to use '127.0.0.1'

  • Add LDAP and LDAPS bind failover integration tests

Closes keycloak#55322

* Since the forced password change support for LDAP users, LDAPOperationManager.authenticate() created the LDAP context without credentials and bound later via reconnect(). JNDI only iterates over multiple space-separated connection URLs during context creation, so a primary server accepting TCP but failing or hanging on bind no longer failed over to the next URL. When StartTLS is not used, bind during context creation again, passing the password policy request control as connection control.

* Change server socket address to use '127.0.0.1'

* Add LDAP and LDAPS bind failover integration tests

Signed-off-by: Peter Heiles <72147026+pheiles@users.noreply.github.com>
Signed-off-by: NedimPopovac <nedim.popovac@dedalus.com>
Signed-off-by: NedimPopovac <115164896+NedimPopovac@users.noreply.github.com>
Signed-off-by: Tomas Kyjovsky <tkyjovsk@ibm.com>
Co-authored-by: Peter Heiles <72147026+pheiles@users.noreply.github.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Co-authored-by: NedimPopovac <115164896+NedimPopovac@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@keycloak-github-bot keycloak-github-bot Bot linked an issue Dec 4, 2026 that may be closed by this pull request
2 tasks done
@tkyjovsk
tkyjovsk marked this pull request as ready for review December 4, 2026 16:18
@tkyjovsk
tkyjovsk requested a review from a team as a code owner December 4, 2026 16:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

LDAP failover regression since 26.6.0

1 participant

0