Package org.wso2.carbon.ui
Class BasicAuthUIAuthenticator
java.lang.Object
org.wso2.carbon.ui.AbstractCarbonUIAuthenticator
org.wso2.carbon.ui.BasicAuthUIAuthenticator
- All Implemented Interfaces:
CarbonUIAuthenticator
- Direct Known Subclasses:
DefaultCarbonAuthenticator
-
Field Summary
Fields inherited from class org.wso2.carbon.ui.AbstractCarbonUIAuthenticator
log, PASSWORD, REMEMBER_ME, USERNAME -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidauthenticate(javax.servlet.http.HttpServletRequest request) Authenticates the given request.voidauthenticateWithCookie(javax.servlet.http.HttpServletRequest request) Handles authentication during a session expiration.booleancanHandle(javax.servlet.http.HttpServletRequest request) This method will check whether given request can be handled by the authenticator.doAuthentication(Object credentials, boolean isRememberMe, org.apache.axis2.client.ServiceClient client, javax.servlet.http.HttpServletRequest request) protected org.wso2.carbon.authenticator.proxy.AuthenticationAdminClientgetAuthenticationAdminCient(javax.servlet.http.HttpServletRequest request) Returns the name of the authenticator.voidhandleRememberMe(Map transportHeaders, javax.servlet.http.HttpServletRequest httpServletRequest) voidunauthenticate(Object object) Invalidates the authentication session.Methods inherited from class org.wso2.carbon.ui.AbstractCarbonUIAuthenticator
getAuthenticationSkippingUrls, getPriority, getSessionValidationSkippingUrls, getUserNameFromCookie, handleSecurity, isAdminCookieSet, isDisabled, onSuccessAdminLogin, setAdminCookie, setUserInformation, skipLoginPage
-
Constructor Details
-
BasicAuthUIAuthenticator
public BasicAuthUIAuthenticator()
-
-
Method Details
-
canHandle
public boolean canHandle(javax.servlet.http.HttpServletRequest request) Description copied from interface:CarbonUIAuthenticatorThis method will check whether given request can be handled by the authenticator. If authenticator is capable of handling given request this method will returntrue. Else this will returnfalse.- Returns:
trueif this authenticator can handle the request, elsefalse.
-
authenticate
public void authenticate(javax.servlet.http.HttpServletRequest request) throws org.wso2.carbon.core.common.AuthenticationException Description copied from interface:CarbonUIAuthenticatorAuthenticates the given request.- Throws:
org.wso2.carbon.core.common.AuthenticationException- If an error occurred during authentication process.
-
authenticateWithCookie
public void authenticateWithCookie(javax.servlet.http.HttpServletRequest request) throws org.wso2.carbon.core.common.AuthenticationException Description copied from interface:CarbonUIAuthenticatorHandles authentication during a session expiration. Usually the request is a cookie.- Throws:
org.wso2.carbon.core.common.AuthenticationException- If an error occurred during authentication process.
-
doAuthentication
public String doAuthentication(Object credentials, boolean isRememberMe, org.apache.axis2.client.ServiceClient client, javax.servlet.http.HttpServletRequest request) throws org.wso2.carbon.core.common.AuthenticationException - Specified by:
doAuthenticationin classAbstractCarbonUIAuthenticator- Parameters:
credentials-client-request-- Throws:
org.wso2.carbon.core.common.AuthenticationException
-
handleRememberMe
public void handleRememberMe(Map transportHeaders, javax.servlet.http.HttpServletRequest httpServletRequest) throws org.wso2.carbon.core.common.AuthenticationException - Specified by:
handleRememberMein classAbstractCarbonUIAuthenticator- Parameters:
httpServletRequest-serviceClient-- Throws:
org.apache.axis2.AxisFaultorg.wso2.carbon.core.common.AuthenticationException
-
unauthenticate
Description copied from interface:CarbonUIAuthenticatorInvalidates the authentication session. TODO why we need this ? An authenticator should not maintain a session- Parameters:
object- The request to invalidate TODO (?)- Throws:
Exception- If an error occurred during authentication process.
-
getAuthenticationAdminCient
protected org.wso2.carbon.authenticator.proxy.AuthenticationAdminClient getAuthenticationAdminCient(javax.servlet.http.HttpServletRequest request) throws org.apache.axis2.AxisFault - Throws:
org.apache.axis2.AxisFault
-
getAuthenticatorName
Description copied from interface:CarbonUIAuthenticatorReturns the name of the authenticator.- Returns:
- The name of the authenticator.
-