|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jasig.cas.authentication.handler.support.AbstractPreAndPostProcessingAuthenticationHandler
org.jasig.cas.authentication.handler.support.AbstractUsernamePasswordAuthenticationHandler
public abstract class AbstractUsernamePasswordAuthenticationHandler
Abstract class to override supports so that we don't need to duplicate the check for UsernamePasswordCredentials.
This is a published and supported CAS Server 3 API.
| Field Summary |
|---|
| Fields inherited from class org.jasig.cas.authentication.handler.support.AbstractPreAndPostProcessingAuthenticationHandler |
|---|
log |
| Constructor Summary | |
|---|---|
AbstractUsernamePasswordAuthenticationHandler()
|
|
| Method Summary | |
|---|---|
protected abstract boolean |
authenticateUsernamePasswordInternal(UsernamePasswordCredentials credentials)
Abstract convenience method that assumes the credentials passed in are a subclass of UsernamePasswordCredentials. |
protected boolean |
doAuthentication(Credentials credentials)
Method automatically handles conversion to UsernamePasswordCredentials and delegates to abstract authenticateUsernamePasswordInternal so subclasses do not need to cast. |
protected PasswordEncoder |
getPasswordEncoder()
Method to return the PasswordEncoder to be used to encode passwords. |
protected PrincipalNameTransformer |
getPrincipalNameTransformer()
|
void |
setClassToSupport(java.lang.Class<?> classToSupport)
Method to set the class to support. |
void |
setPasswordEncoder(PasswordEncoder passwordEncoder)
Sets the PasswordEncoder to be used with this class. |
void |
setPrincipalNameTransformer(PrincipalNameTransformer principalNameTransformer)
|
void |
setSupportSubClasses(boolean supportSubClasses)
Method to set whether this handler will support subclasses of the supported class. |
boolean |
supports(Credentials credentials)
Method to check if the handler knows how to handle the credentials provided. |
| Methods inherited from class org.jasig.cas.authentication.handler.support.AbstractPreAndPostProcessingAuthenticationHandler |
|---|
authenticate, getName, postAuthenticate, preAuthenticate, setName |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AbstractUsernamePasswordAuthenticationHandler()
| Method Detail |
|---|
protected final boolean doAuthentication(Credentials credentials)
throws AuthenticationException
doAuthentication in class AbstractPreAndPostProcessingAuthenticationHandlerAuthenticationException
protected abstract boolean authenticateUsernamePasswordInternal(UsernamePasswordCredentials credentials)
throws AuthenticationException
credentials - the credentials representing the Username and Password
presented to CAS
AuthenticationException - if authenticity cannot be determined.protected final PasswordEncoder getPasswordEncoder()
protected final PrincipalNameTransformer getPrincipalNameTransformer()
public final void setClassToSupport(java.lang.Class<?> classToSupport)
classToSupport - the class we want this handler to support
explicitly.public final void setSupportSubClasses(boolean supportSubClasses)
supportSubClasses - boolean of whether to support subclasses or not.public final void setPasswordEncoder(PasswordEncoder passwordEncoder)
passwordEncoder - the PasswordEncoder to use when encoding
passwords.public final void setPrincipalNameTransformer(PrincipalNameTransformer principalNameTransformer)
public final boolean supports(Credentials credentials)
AuthenticationHandler
credentials - The credentials to check.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||