Interface AuthenticatedRequest.PrincipalExtractor

Enclosing class:
AuthenticatedRequest

public static interface AuthenticatedRequest.PrincipalExtractor
Determines the current user principal and how to interpret that principal to extract user identity and allowed accounts.
  • Method Details

    • principal

      default Object principal()
      Returns:
      the user principal in the current security scope.
    • getSpinnakerAccounts

      default Optional<String> getSpinnakerAccounts()
      Returns:
      The comma separated list of accounts for the current principal.
    • getSpinnakerAccounts

      default Optional<String> getSpinnakerAccounts(Object principal)
      Parameters:
      principal - the principal to inspect for accounts
      Returns:
      the comma separated list of accounts for the provided principal.
    • getSpinnakerUser

      default Optional<String> getSpinnakerUser()
      Returns:
      the user id of the current user
    • getSpinnakerUser

      default Optional<String> getSpinnakerUser(Object principal)
      Parameters:
      principal - the principal from which to extract the userid
      Returns:
      the user id of the provided principal