Class AbstractCarbonUIAuthenticator

java.lang.Object
org.wso2.carbon.ui.AbstractCarbonUIAuthenticator
All Implemented Interfaces:
CarbonUIAuthenticator
Direct Known Subclasses:
BasicAuthUIAuthenticator

public abstract class AbstractCarbonUIAuthenticator extends Object implements CarbonUIAuthenticator
An abstract implementation if CarbonUIAuthenticator.
  • Field Details

  • Constructor Details

    • AbstractCarbonUIAuthenticator

      public AbstractCarbonUIAuthenticator()
  • Method Details

    • isDisabled

      public boolean isDisabled()
      In default implementation this will read the authenticator configuration and will return true if authenticator is disabled in the configuration.
      Specified by:
      isDisabled in interface CarbonUIAuthenticator
      Returns:
      true if authenticator is disabled, else false.
    • getPriority

      public int getPriority()
      In default implementation this will read the priority from authenticator configuration.
      Specified by:
      getPriority in interface CarbonUIAuthenticator
      Returns:
      The priority value.
    • getSessionValidationSkippingUrls

      public List<String> getSessionValidationSkippingUrls()
      In default implementation this will return some SSO links to be skipped. TODO : check whether we can move this t SSO authenticators.
      Specified by:
      getSessionValidationSkippingUrls in interface CarbonUIAuthenticator
      Returns:
      A list with following urls.
    • getAuthenticationSkippingUrls

      public List<String> getAuthenticationSkippingUrls()
      In default implementation this will return an empty list.
      Specified by:
      getAuthenticationSkippingUrls in interface CarbonUIAuthenticator
      Returns:
      An empty list.
    • doAuthentication

      public abstract String doAuthentication(Object credentials, boolean isRememberMe, org.apache.axis2.client.ServiceClient client, javax.servlet.http.HttpServletRequest request) throws org.wso2.carbon.core.common.AuthenticationException
      Parameters:
      credentials -
      client -
      request -
      rememberMe -
      Throws:
      org.wso2.carbon.core.common.AuthenticationException
    • handleRememberMe

      public abstract void handleRememberMe(Map transportHeaders, javax.servlet.http.HttpServletRequest httpServletRequest) throws org.wso2.carbon.core.common.AuthenticationException
      Parameters:
      httpServletRequest -
      serviceClient -
      Throws:
      org.apache.axis2.AxisFault
      org.wso2.carbon.core.common.AuthenticationException
    • isAdminCookieSet

      protected boolean isAdminCookieSet()
    • handleSecurity

      public void handleSecurity(Object credentials, boolean rememberMe, javax.servlet.http.HttpServletRequest request) throws org.wso2.carbon.core.common.AuthenticationException
      Parameters:
      credentials -
      rememberMe -
      request -
      Throws:
      org.apache.axis2.AxisFault
      org.wso2.carbon.core.common.AuthenticationException
    • skipLoginPage

      public boolean skipLoginPage()
      Description copied from interface: CarbonUIAuthenticator
      If Authenticator does not need to have login page - set this to true.
      Specified by:
      skipLoginPage in interface CarbonUIAuthenticator
      Returns:
    • onSuccessAdminLogin

      public void onSuccessAdminLogin(javax.servlet.http.HttpServletRequest request, String userName) throws Exception
      Parameters:
      request -
      userName -
      Throws:
      Exception
    • setUserInformation

      protected void setUserInformation(String cookie, String backendServerURL, javax.servlet.http.HttpSession session) throws RemoteException
      Parameters:
      cookie -
      backendServerURL -
      session -
      Throws:
      RemoteException
    • getUserNameFromCookie

      protected static String getUserNameFromCookie(String cookieValue)
      Parameters:
      cookieValue -
      Returns:
    • setAdminCookie

      protected void setAdminCookie(javax.servlet.http.HttpSession session, org.apache.axis2.client.ServiceClient serviceClient, String rememberMeCookie) throws org.apache.axis2.AxisFault
      Parameters:
      session -
      serviceClient -
      rememberMeCookie -
      Throws:
      org.apache.axis2.AxisFault