edu.vt.middleware.ldap.auth
public class ConstructDnResolver extends java.lang.Object implements DnResolver, java.io.Serializable
ConstructDnResolver creates an LDAP DN using known information
about the LDAP. Specifically it concatenates the first user field with the
base DN.| Modifier and Type | Field and Description |
|---|---|
protected AuthenticatorConfig |
config
Authentication configuration.
|
protected org.apache.commons.logging.Log |
logger
Log for this class.
|
| Constructor and Description |
|---|
ConstructDnResolver()
Default constructor.
|
ConstructDnResolver(AuthenticatorConfig authConfig)
This will create a new
ConstructDnResolver with the supplied
AuthenticatorConfig. |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
This will close any resources associated with this resolver.
|
AuthenticatorConfig |
getAuthenticatorConfig()
This returns the
AuthenticatorConfig of the
Authenticator. |
java.lang.String |
resolve(java.lang.String user)
Creates a LDAP DN by combining the userField and the base dn.
|
void |
setAuthenticatorConfig(AuthenticatorConfig authConfig)
This will set the config parameters of this
Authenticator. |
protected final org.apache.commons.logging.Log logger
protected AuthenticatorConfig config
public ConstructDnResolver()
public ConstructDnResolver(AuthenticatorConfig authConfig)
ConstructDnResolver with the supplied
AuthenticatorConfig.authConfig - AuthenticatorConfigpublic void setAuthenticatorConfig(AuthenticatorConfig authConfig)
Authenticator.setAuthenticatorConfig in interface DnResolverauthConfig - AuthenticatorConfigpublic AuthenticatorConfig getAuthenticatorConfig()
AuthenticatorConfig of the
Authenticator.getAuthenticatorConfig in interface DnResolverAuthenticatorConfigpublic java.lang.String resolve(java.lang.String user)
throws javax.naming.NamingException
resolve in interface DnResolveruser - String to find dn forString - user's dnjavax.naming.NamingException - if the LDAP search failspublic void close()
close in interface DnResolverCopyright © 2014. All Rights Reserved.