Package io.undertow.security.api
Enum AuthenticationMode
- All Implemented Interfaces:
Serializable
,Comparable<AuthenticationMode>
,java.lang.constant.Constable
Enumeration to indicate the authentication mode in use.
- Author:
- Darran Lofthouse
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionWhen running in constraint driven mode the authentication mechanisms are only executed where the constraint that mandates authentication is triggered, for all other requests no authentication occurs unless requested by the internal APIs which may be exposed using the Servlet APIs.Where the authentication mode is set to pro-active each request on arrival will be passed to the defined authentication mechanisms to eagerly perform authentication if there is sufficient information available in order to do so. -
Method Summary
Modifier and TypeMethodDescriptionstatic AuthenticationMode
Returns the enum constant of this type with the specified name.static AuthenticationMode[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
PRO_ACTIVE
Where the authentication mode is set to pro-active each request on arrival will be passed to the defined authentication mechanisms to eagerly perform authentication if there is sufficient information available in order to do so. A pro-active authentication could be possible for a number of reasons such as already having a SSL connection established, an identity being cached against the current session or even a browser sending in authentication headers. Running in pro-active mode the sending of the challenge to the client is still driven by the constraints defined so this is not the same as mandating security for all paths. For some mechanisms such as Digest this is a recommended mode as without it there is a risk that clients are sending in headers with unique nonce counts that go unverified risking that a malicious client could make use of them. This is also useful for applications that wish to make use of the current authenticated user if one exists without mandating that authentication occurs. -
CONSTRAINT_DRIVEN
When running in constraint driven mode the authentication mechanisms are only executed where the constraint that mandates authentication is triggered, for all other requests no authentication occurs unless requested by the internal APIs which may be exposed using the Servlet APIs.
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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 type has no constant with the specified nameNullPointerException
- if the argument is null
-