public final class AuthenticationManager
extends java.lang.Object
AuthenticationHandler
.Modifier and Type | Field and Description |
---|---|
static java.lang.String |
REVISION |
Modifier and Type | Method and Description |
---|---|
void |
addAuthenticationHandler(AuthenticationHandler authHdlr)
Add the specified AuthenticationHandler to the handlers collection
already managed by the AuthenticationManager.
|
java.util.SortedSet<AuthenticationHandler> |
getAuthenticationHandlerSet()
Retrieve the internal set of
AuthenticationHandler
managed by the AuthenticationManager. |
boolean |
getDefaultPersistentValue()
Defined by value of property
auth-mgr.persistent.default-value . |
static AuthenticationManager |
getInstance() |
java.lang.String |
getLoginParameter()
Retrieve the parameter name used for the user's login.
|
java.lang.String |
getOpLoginParameter()
Retrieve the parameter name used to indicate a login action is requested (login form submitted).
|
java.lang.String |
getPasswordParameter()
Retrieve the parameter name used for the user's password.
|
java.lang.String |
getPersistentParameter()
Retrieve the parameter name used for the user's persistent login preference.
|
void |
init()
Initialize the AuthenticationManager.
|
boolean |
isAuthenticationRequired()
Returns true if the authentication is required in this site.
|
boolean |
isLoginAccentSensitive()
Returns true if login should be treated as accent sensitive (mylogin !
|
boolean |
isLoginCaseSensitive()
Returns true if login should be treated as case sensitive (myLogin !
|
boolean |
isShowingPersistentOption()
Defined by value of property
auth-mgr.persistent.show-option . |
LoginResult |
login(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
java.util.Locale userLocale)
Authenticate a member for each request.
|
LoginResult |
login(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
java.lang.String userLang)
Deprecated.
|
Member |
login(java.lang.String login,
java.lang.String password)
Retrieve a member from a login/password pair.
|
void |
logout(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
java.util.Locale userLocale,
Member loggedMember)
Logout the current loggedMember from this session.
|
void |
logout(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
java.lang.String userLang,
Member loggedMember)
Deprecated.
|
void |
readOrdersFromProperties()
Read Authentication Handlers order from properties.
|
void |
removeAuthenticationHandler(AuthenticationHandler authHdlr)
Remove the specified AuthenticationHandler from the handlers
managed by the AuthenticationManager.
|
public static final java.lang.String REVISION
public static final AuthenticationManager getInstance()
public void init()
public void readOrdersFromProperties()
public void addAuthenticationHandler(AuthenticationHandler authHdlr)
authHdlr
- the AuthenticationHandler to be addedpublic void removeAuthenticationHandler(AuthenticationHandler authHdlr)
authHdlr
- the AuthenticationHandler to be removedpublic java.util.SortedSet<AuthenticationHandler> getAuthenticationHandlerSet()
AuthenticationHandler
managed by the AuthenticationManager.AuthenticationHandler
public boolean isAuthenticationRequired()
channel.is-authentication-required
.public boolean isLoginCaseSensitive()
channel.login-casesensitive
.public boolean isLoginAccentSensitive()
channel.login-accentsensitive
.public boolean isShowingPersistentOption()
auth-mgr.persistent.show-option
.public boolean getDefaultPersistentValue()
auth-mgr.persistent.default-value
.public java.lang.String getLoginParameter()
auth-mgr.login-param.login
.public java.lang.String getPasswordParameter()
auth-mgr.login-param.password
.public java.lang.String getPersistentParameter()
auth-mgr.login-param.persistent
.public java.lang.String getOpLoginParameter()
auth-mgr.login-param.op-login
.public Member login(java.lang.String login, java.lang.String password) throws java.io.IOException
login
- the user loginpassword
- the user's clear text passwordMember
, (or null on error)java.io.IOException
- if the login operation could not be performed due to IO problem (HTTP headers in response, cookie error, ...)public LoginResult login(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, java.lang.String userLang) throws java.io.IOException
login(HttpServletRequest, HttpServletResponse, Locale)
request
- the current HttpServletRequest being processedresponse
- the HttpServletResponse bound to current requestuserLang
- the current language guessed from browser preference or sessionMember
java.io.IOException
- if the login operation could not be performed due to IO problem (HTTP headers in response, cookie error, ...)public LoginResult login(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, java.util.Locale userLocale) throws java.io.IOException
request
- the current HttpServletRequest being processedresponse
- the HttpServletResponse bound to current requestuserLocale
- the current Locale guessed from browser preference or sessionMember
java.io.IOException
- if the login operation could not be performed due to IO problem (HTTP headers in response, cookie error, ...)public void logout(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, java.lang.String userLang, Member loggedMember) throws java.io.IOException
logout(HttpServletRequest, HttpServletResponse, Locale, Member)
request
- the current HttpServletRequest being processedresponse
- the HttpServletResponse bound to current requestuserLang
- the current language guessed from browser preference or sessionloggedMember
- the member currently logged injava.io.IOException
- if the logout operation could not be performed due to IO problem (HTTP headers in response, cookie error, ...)public void logout(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, java.util.Locale userLocale, Member loggedMember) throws java.io.IOException
request
- the current HttpServletRequest being processedresponse
- the HttpServletResponse bound to current requestuserLocale
- the current Locale guessed from browser preference or sessionloggedMember
- the member currently logged injava.io.IOException
- if the logout operation could not be performed due to IO problem (HTTP headers in response, cookie error, ...)Copyright © 2001-2010 Jalios SA. All Rights Reserved.