Class RegistrationRecaptcha
java.lang.Object
org.keycloak.authentication.forms.RegistrationRecaptcha
- All Implemented Interfaces:
ConfigurableAuthenticatorFactory
,FormAction
,FormActionFactory
,ConfiguredProvider
,Provider
,ProviderFactory<FormAction>
public class RegistrationRecaptcha
extends Object
implements FormAction, FormActionFactory, ConfiguredProvider
- Version:
- $Revision: 1 $
- Author:
- Bill Burke
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
buildPage
(FormContext context, LoginFormsProvider form) void
close()
boolean
configuredFor
(KeycloakSession session, RealmModel realm, UserModel user) create
(KeycloakSession session) getId()
void
init
(Config.Scope config) boolean
boolean
void
postInit
(KeycloakSessionFactory factory) boolean
void
setRequiredActions
(KeycloakSession session, RealmModel realm, UserModel user) void
success
(FormContext context) void
validate
(ValidationContext context) protected boolean
validateRecaptcha
(ValidationContext context, boolean success, String captcha, String secret) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.keycloak.provider.ConfiguredProvider
getConfig
Methods inherited from interface org.keycloak.provider.ProviderFactory
getConfigMetadata, order
-
Field Details
-
G_RECAPTCHA_RESPONSE
- See Also:
-
RECAPTCHA_REFERENCE_CATEGORY
- See Also:
-
SITE_KEY
- See Also:
-
SITE_SECRET
- See Also:
-
USE_RECAPTCHA_NET
- See Also:
-
PROVIDER_ID
- See Also:
-
-
Constructor Details
-
RegistrationRecaptcha
public RegistrationRecaptcha()
-
-
Method Details
-
getDisplayType
- Specified by:
getDisplayType
in interfaceConfigurableAuthenticatorFactory
-
getReferenceCategory
- Specified by:
getReferenceCategory
in interfaceConfigurableAuthenticatorFactory
-
isConfigurable
public boolean isConfigurable()- Specified by:
isConfigurable
in interfaceConfigurableAuthenticatorFactory
-
getRequirementChoices
- Specified by:
getRequirementChoices
in interfaceConfigurableAuthenticatorFactory
-
buildPage
- Specified by:
buildPage
in interfaceFormAction
-
validate
- Specified by:
validate
in interfaceFormAction
-
validateRecaptcha
protected boolean validateRecaptcha(ValidationContext context, boolean success, String captcha, String secret) -
success
- Specified by:
success
in interfaceFormAction
-
requiresUser
public boolean requiresUser()- Specified by:
requiresUser
in interfaceFormAction
-
configuredFor
- Specified by:
configuredFor
in interfaceFormAction
-
setRequiredActions
- Specified by:
setRequiredActions
in interfaceFormAction
-
isUserSetupAllowed
public boolean isUserSetupAllowed()- Specified by:
isUserSetupAllowed
in interfaceConfigurableAuthenticatorFactory
-
close
public void close()- Specified by:
close
in interfaceProvider
- Specified by:
close
in interfaceProviderFactory<FormAction>
-
create
- Specified by:
create
in interfaceProviderFactory<FormAction>
-
init
- Specified by:
init
in interfaceProviderFactory<FormAction>
-
postInit
- Specified by:
postInit
in interfaceProviderFactory<FormAction>
-
getId
- Specified by:
getId
in interfaceProviderFactory<FormAction>
-
getHelpText
- Specified by:
getHelpText
in interfaceConfiguredProvider
-
getConfigProperties
- Specified by:
getConfigProperties
in interfaceConfiguredProvider
-