Class BasicAuthorizationAuthenticator

java.lang.Object
fr.paris.lutece.util.signrequest.AbstractAuthenticator
fr.paris.lutece.util.signrequest.BasicAuthorizationAuthenticator
All Implemented Interfaces:
RequestAuthenticator

public class BasicAuthorizationAuthenticator extends AbstractAuthenticator
BasicAuthorizationAuthenticator.
This authenticator provides a basic username/password authentication.
The request should have a header named Authorization with a value that begins with "Basic" followed by the "username:password" encoded in base64.
  • Constructor Details

    • BasicAuthorizationAuthenticator

      public BasicAuthorizationAuthenticator(String strUsername, String strPassword)
      Constructor that define credentials
      Parameters:
      strUsername - The username
      strPassword - The password
  • Method Details

    • isRequestAuthenticated

      public boolean isRequestAuthenticated(javax.servlet.http.HttpServletRequest request)
      Check the Authentication of a request
      Parameters:
      request - The HTTP request
      Returns:
      true if authenticated, otherwise false
    • getSecurityInformations

      public AuthenticateRequestInformations getSecurityInformations(List<String> elements)
      return Security informations to put in the request headers and request parameters
      Parameters:
      elements - List of elements to include in the signature
      Returns:
      AuthenticateRequestInformations