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
NamingException
public static StartTlsResponse startTLS(LdapContext ldapContext, String authType, String bindDN, char[] bindCredential, SSLSocketFactory sslSocketFactory) throws NamingException
NamingException
public static Hashtable<Object,Object> getNonAuthConnectionProperties(LDAPConfig ldapConfig)
ldapConfig
- public void close()
close
in interface AutoCloseable
Copyright © 2021 JBoss by Red Hat. All rights reserved.