Class AbstractAuthenticator

java.lang.Object
fr.paris.lutece.util.signrequest.AbstractAuthenticator
All Implemented Interfaces:
RequestAuthenticator
Direct Known Subclasses:
AbstractJWTAuthenticator, AbstractPrivateKeyAuthenticator, BasicAuthorizationAuthenticator, ClientHeaderHashAuthenticator

public abstract class AbstractAuthenticator extends Object implements RequestAuthenticator
AbstractAuthenticator
  • Constructor Details

    • AbstractAuthenticator

      public AbstractAuthenticator()
  • Method Details

    • setSignatureElements

      public void setSignatureElements(List<String> list)
      Sets the list of signature elements
      Parameters:
      list - The list
    • setHashService

      public void setHashService(HashService service)
      Sets the Hash service
      Parameters:
      service - The Hash service
    • setValidityTimePeriod

      public void setValidityTimePeriod(long lPeriod)
      Sets validity time period (in seconds) between the timestamp in the request and the server timestamp
      Parameters:
      lPeriod - The validity time period
    • getValidityTimePeriod

      public long getValidityTimePeriod()
      Get validity time period (in seconds) between the timestamp in the request and the server timestamp
      Returns:
      the validity time period
    • buildSignature

      public String buildSignature(List<String> listElements, String strTimestamp, String strSecret)
      Create a signature
      Parameters:
      listElements - The list of elements that part of the hash
      strTimestamp - The timestamp
      strSecret - The secret
      Returns:
      A signature as an Hexadecimal Hash