public final class LDAPContextManager extends Object implements AutoCloseable
| Constructor and Description |
|---|
LDAPContextManager(KeycloakSession session,
LDAPConfig connectionProperties) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
static LDAPContextManager |
create(KeycloakSession session,
LDAPConfig connectionProperties) |
LdapContext |
getLdapContext() |
static Hashtable<Object,Object> |
getNonAuthConnectionProperties(LDAPConfig ldapConfig)
This method is used for admin connection and user authentication.
|
static StartTlsResponse |
startTLS(LdapContext ldapContext,
String authType,
String bindDN,
char[] bindCredential,
SSLSocketFactory sslSocketFactory) |
public LDAPContextManager(KeycloakSession session, LDAPConfig connectionProperties)
public static LDAPContextManager create(KeycloakSession session, LDAPConfig connectionProperties)
public LdapContext getLdapContext() throws NamingException
NamingExceptionpublic static StartTlsResponse startTLS(LdapContext ldapContext, String authType, String bindDN, char[] bindCredential, SSLSocketFactory sslSocketFactory) throws NamingException
NamingExceptionpublic static Hashtable<Object,Object> getNonAuthConnectionProperties(LDAPConfig ldapConfig)
ldapConfig - public void close()
close in interface AutoCloseableCopyright © 2021 JBoss by Red Hat. All rights reserved.