Class BasicAuthUIAuthenticator

    • Constructor Detail

      • BasicAuthUIAuthenticator

        public BasicAuthUIAuthenticator()
    • Method Detail

      • canHandle

        public boolean canHandle​(javax.servlet.http.HttpServletRequest request)
        Description copied from interface: CarbonUIAuthenticator
        This method will check whether given request can be handled by the authenticator. If authenticator is capable of handling given request this method will return true. Else this will return false.
        Returns:
        true if this authenticator can handle the request, else false.
      • authenticate

        public void authenticate​(javax.servlet.http.HttpServletRequest request)
                          throws org.wso2.carbon.core.common.AuthenticationException
        Description copied from interface: CarbonUIAuthenticator
        Authenticates 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: CarbonUIAuthenticator
        Handles 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:
        doAuthentication in class AbstractCarbonUIAuthenticator
        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:
        handleRememberMe in class AbstractCarbonUIAuthenticator
        Parameters:
        serviceClient -
        httpServletRequest -
        Throws:
        org.apache.axis2.AxisFault
        org.wso2.carbon.core.common.AuthenticationException
      • unauthenticate

        public void unauthenticate​(Object object)
                            throws Exception
        Description copied from interface: CarbonUIAuthenticator
        Invalidates 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

        public String getAuthenticatorName()
        Description copied from interface: CarbonUIAuthenticator
        Returns the name of the authenticator.
        Returns:
        The name of the authenticator.