org.keycloak.authentication.requiredactions

## Class WebAuthnRegister

- java.lang.Object
- - org.keycloak.authentication.requiredactions.WebAuthnRegister

- All Implemented Interfaces:
    CredentialRegistrator, RequiredActionProvider, Provider
  Direct Known Subclasses:
    WebAuthnPasswordlessRegister

      public class WebAuthnRegister
      extends Object
      implements RequiredActionProvider, CredentialRegistrator

  Required action for register WebAuthn 2-factor credential for the user

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `WebAuthnRegister(KeycloakSession session, com.webauthn4j.validator.attestation.trustworthiness.certpath.CertPathTrustworthinessValidator certPathtrustValidator)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `close()`
    `void` | `evaluateTriggers(RequiredActionContext context)` Called every time a user authenticates.
    `protected String` | `getCredentialProviderId()`
    `protected String` | `getCredentialType()`
    `protected WebAuthnPolicy` | `getWebAuthnPolicy(RequiredActionContext context)`
    `InitiatedActionSupport` | `initiatedActionSupport()` Determines what type of support is provided for application-initiated actions.
    `void` | `processAction(RequiredActionContext context)` Called when a required action has form input you want to process.
    `void` | `requiredActionChallenge(RequiredActionContext context)` If the user has a required action set, this method will be the initial call to obtain what to display to the user's browser.

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

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

    - ### Methods inherited from interface org.keycloak.authentication.RequiredActionProvider

      `getMaxAuthAge, initiatedActionCanceled`

- - ### Constructor Detail

    - #### WebAuthnRegister

          public WebAuthnRegister(KeycloakSession session,
                                  com.webauthn4j.validator.attestation.trustworthiness.certpath.CertPathTrustworthinessValidator certPathtrustValidator)

  - ### Method Detail

    - #### initiatedActionSupport

          public InitiatedActionSupport initiatedActionSupport()

      Description copied from interface: `RequiredActionProvider`
      Determines what type of support is provided for application-initiated actions.
      Specified by:
        `initiatedActionSupport` in interface `RequiredActionProvider`
      Returns:
        InititatedActionsSupport

    - #### requiredActionChallenge

          public void requiredActionChallenge(RequiredActionContext context)

      Description copied from interface: `RequiredActionProvider`
      If the user has a required action set, this method will be the initial call to obtain what to display to the user's browser. Return null if no action should be done.
      Specified by:
        `requiredActionChallenge` in interface `RequiredActionProvider`

    - #### getWebAuthnPolicy

          protected WebAuthnPolicy getWebAuthnPolicy(RequiredActionContext context)

    - #### getCredentialType

          protected String getCredentialType()

    - #### getCredentialProviderId

          protected String getCredentialProviderId()

    - #### processAction

          public void processAction(RequiredActionContext context)

      Description copied from interface: `RequiredActionProvider`
      Called when a required action has form input you want to process.
      Specified by:
        `processAction` in interface `RequiredActionProvider`

    - #### close

          public void close()

      Specified by:
        `close` in interface `Provider`

    - #### evaluateTriggers

          public void evaluateTriggers(RequiredActionContext context)

      Description copied from interface: `RequiredActionProvider`
      Called every time a user authenticates. This checks to see if this required action should be triggered. The implementation of this method is responsible for setting the required action on the UserModel. For example, the UpdatePassword required actions checks the password policies to see if the password has expired.
      Specified by:
        `evaluateTriggers` in interface `RequiredActionProvider`

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