Class AuthenticatorExtractor

java.lang.Object
overit.geocall.basic.bl.auth.AuthenticatorExtractor

public class AuthenticatorExtractor extends Object
Class that allows you to extract an authenticator, among those registered, able to authenticate the request for generation of an access token
  • Constructor Details

    • AuthenticatorExtractor

      public AuthenticatorExtractor(HttpServletRequest httpRequest)
      Main class's construct. Create a new AuthenticatorExtractor able to extract an authenticator in order to authenticate the request for generation of an access token
      Parameters:
      httpRequest - the request from which the token will be generated after authentication.
  • Method Details

    • getAuthentications

      public Map<Class<? extends overit.geocall.rs.auth.Authenticator>,overit.geocall.rs.auth.Authentication> getAuthentications()
      Returns:
      returns the list of the authenticators able to authenticate the token generation request, or the empty list if there is none
    • getFirstValidAuthentication

      public overit.geocall.rs.auth.Authentication getFirstValidAuthentication()
      Returns:
      returns the first authenticator who was able to authenticate the token generation request, or the null value in case there is none
    • getFirstValidAuthentication

      public overit.geocall.rs.auth.Authentication getFirstValidAuthentication(Collection<String> features)
      Parameters:
      features - collection of features that the service requires for authenticator selection Null means that no particular feature a required.
      Returns:
      returns the first authenticator who was able to authenticate the token generation request, or the null value in case there is none