org.keycloak.credential

## Interface CredentialInputValidator

- All Known Implementing Classes:
    KerberosFederationProvider, LDAPStorageProvider, OTPCredentialProvider, PasswordCredentialProvider, SSSDFederationProvider, WebAuthnCredentialProvider, WebAuthnPasswordlessCredentialProvider

      public interface CredentialInputValidator

  Implentations of this interface can validate CredentialInput, i.e. verify a password. UserStorageProviders and CredentialProviders can implement this interface.
  Version:
    $Revision: 1 $
  Author:
    Bill Burke

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `isConfiguredFor(RealmModel realm, UserModel user, String credentialType)`
    `boolean` | `isValid(RealmModel realm, UserModel user, CredentialInput credentialInput)` Tests whether a credential is valid
    `boolean` | `supportsCredentialType(String credentialType)`

- - ### Method Detail

    - #### supportsCredentialType

          boolean supportsCredentialType(String credentialType)

    - #### isConfiguredFor

          boolean isConfiguredFor(RealmModel realm,
                                  UserModel user,
                                  String credentialType)

    - #### isValid

          boolean isValid(RealmModel realm,
                          UserModel user,
                          CredentialInput credentialInput)

      Tests whether a credential is valid
      Parameters:
        `realm` - The realm in which to which the credential belongs to
        `user` - The user for which to test the credential
        `credentialInput` - the credential details to verify
      Returns:
        true if the passed secret is correct

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