java.lang.Object
overit.geocallapp.wfm.orchestrator.planning.utilities.rest.authentication.strategies.BasicAuthentication
All Implemented Interfaces:
AuthenticationStrategy

public class BasicAuthentication extends Object implements AuthenticationStrategy
Authentication strategy that uses username and password for authentication. This strategy supports two modes: 1. JWT token mode: obtains a JWT token using username/password and uses it for subsequent requests 2. Basic Auth mode: uses HTTP Basic Authentication for each request
  • Field Details

  • Constructor Details

    • BasicAuthentication

      public BasicAuthentication(String authUrl, String username, String password)
      Creates a new username/password authentication with the specified parameters using JWT token mode.
      Parameters:
      authUrl - The URL to use for authentication
      username - The username to use for authentication
      password - The password to use for authentication
    • BasicAuthentication

      public BasicAuthentication(String authUrl, String username, String password, boolean useBasicAuth)
      Creates a new username/password authentication with the specified parameters.
      Parameters:
      authUrl - The URL to use for authentication (can be null if useBasicAuth is true)
      username - The username to use for authentication
      password - The password to use for authentication
      useBasicAuth - If true, uses HTTP Basic Authentication for each request instead of JWT token
  • Method Details