Enum Class LoginType

java.lang.Object
java.lang.Enum<LoginType>
net.datenwerke.oidc.shared.LoginType
All Implemented Interfaces:
Serializable, Comparable<LoginType>, Constable

public enum LoginType extends Enum<LoginType>
Represents the type of login mechanism a user has used to authenticate with RS.

This enum is stored in the RS HTTP session after a successful login and is later used to determine how requests should be validated.

Storing the login type allows RS to distinguish between legacy and OIDC-based sessions in hybrid deployments and enforce the correct request handling rules.

  • Enum Constant Details

    • LEGACY

      public static final LoginType LEGACY
      Authentication via the traditional/legacy ReportServer login mechanism (e.g. username and password form login). In this mode, no Authorization header with a bearer token should be present in subsequent requests.
    • OIDC

      public static final LoginType OIDC
      Authentication via an OIDC provider (e.g. Keycloak). In this mode, each request must carry a valid Authorization: Bearer <token> header. The token is validated through the OIDC introspection endpoint, and its claims are compared with the RS user data.
  • Method Details

    • values

      public static LoginType[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static LoginType valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null