public abstract class AbstractLdapAuthenticator extends java.lang.Object implements LdapAuthenticator, org.springframework.beans.factory.InitializingBean, org.springframework.context.MessageSourceAware
| Modifier and Type | Field and Description |
|---|---|
protected org.springframework.context.support.MessageSourceAccessor |
messages |
| Constructor and Description |
|---|
AbstractLdapAuthenticator(org.springframework.ldap.core.ContextSource contextSource)
Create an initialized instance with the
ContextSource provided. |
| Modifier and Type | Method and Description |
|---|---|
void |
afterPropertiesSet() |
protected org.springframework.ldap.core.ContextSource |
getContextSource() |
java.lang.String[] |
getUserAttributes() |
protected java.util.List<java.lang.String> |
getUserDns(java.lang.String username)
Builds list of possible DNs for the user, worked out from the
userDnPatterns property.
|
protected LdapUserSearch |
getUserSearch() |
void |
setMessageSource(org.springframework.context.MessageSource messageSource) |
void |
setUserAttributes(java.lang.String[] userAttributes)
Sets the user attributes which will be retrieved from the directory.
|
void |
setUserDnPatterns(java.lang.String[] dnPattern)
Sets the pattern which will be used to supply a DN for the user.
|
void |
setUserSearch(LdapUserSearch userSearch) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitauthenticatepublic AbstractLdapAuthenticator(org.springframework.ldap.core.ContextSource contextSource)
ContextSource provided.contextSource - public void afterPropertiesSet()
throws java.lang.Exception
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBeanjava.lang.Exceptionprotected org.springframework.ldap.core.ContextSource getContextSource()
public java.lang.String[] getUserAttributes()
protected java.util.List<java.lang.String> getUserDns(java.lang.String username)
username - the user's login nameprotected LdapUserSearch getUserSearch()
public void setMessageSource(org.springframework.context.MessageSource messageSource)
setMessageSource in interface org.springframework.context.MessageSourceAwarepublic void setUserAttributes(java.lang.String[] userAttributes)
userAttributes - public void setUserDnPatterns(java.lang.String[] dnPattern)
dnPattern - the array of patterns which will be tried when converting a
username to a DN.public void setUserSearch(LdapUserSearch userSearch)