org.keycloak.services.resources

## Class LoginActionsServiceChecks.IsActionRequired

- java.lang.Object
- - org.keycloak.services.resources.LoginActionsServiceChecks.IsActionRequired

- All Implemented Interfaces:
    TokenVerifier.Predicate<JsonWebToken>
  Enclosing class:
    LoginActionsServiceChecks

      public static class LoginActionsServiceChecks.IsActionRequired
      extends Object
      implements TokenVerifier.Predicate<JsonWebToken>

  Verifies that if authentication session exists and any action is required according to it, then it is the expected one. If there is an action required in the session, furthermore it is not the expected one, and the required action is redirection to "required actions", it throws with response performing the redirect to required actions.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `IsActionRequired(ActionTokenContext<?> context, CommonClientSessionModel.Action expectedAction)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `test(JsonWebToken t)` Performs a single check on the given token verifier.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### IsActionRequired

          public IsActionRequired(ActionTokenContext<?> context,
                                  CommonClientSessionModel.Action expectedAction)

  - ### Method Detail

    - #### test

          public boolean test(JsonWebToken t)
                       throws VerificationException

      Description copied from interface: `TokenVerifier.Predicate`
      Performs a single check on the given token verifier.
      Specified by:
        `test` in interface `TokenVerifier.Predicate<JsonWebToken>`
      Parameters:
        `t` - Token, guaranteed to be non-null.
      Returns:
      Throws:
        `VerificationException`

Copyright © 2020 JBoss by Red Hat. All rights reserved.