Class AbstractKbaStageConfig<C extends AbstractKbaStageConfig<C>>

java.lang.Object
org.forgerock.selfservice.stages.kba.AbstractKbaStageConfig<C>
Type Parameters:
C - the type of AbstractKbaStageConfig
All Implemented Interfaces:
StageConfig
Direct Known Subclasses:
SecurityAnswerDefinitionConfig, SecurityAnswerVerificationConfig

public abstract class AbstractKbaStageConfig<C extends AbstractKbaStageConfig<C>> extends Object implements StageConfig
Defines the common configurations for the KBA stages.
Since:
0.2.0
  • Constructor Details

    • AbstractKbaStageConfig

      public AbstractKbaStageConfig(KbaConfig config)
      Creates a new AbstractKbaStageConfig.
      Parameters:
      config - the kba configuration
  • Method Details

    • getQuestions

      public Map<String,Map<String,String>> getQuestions()
      Gets the kba questions in the following format.
      Map<id,Map<locale,question>>
      Returns:
      the kba security questions
    • getSecureHash

      public Map<String,Object> getSecureHash()
      Gets the kba secureHash.
      Returns:
      the hashing algorithm used for kba question answers
    • setQuestions

      public C setQuestions(Map<String,Map<String,String>> questions)
      Sets the kba questions.
      Parameters:
      questions - the kba question
      Returns:
      this config instance
    • setSecureHash

      public C setSecureHash(Map<String,Object> secureHash)
      Sets the kba secureHash.
      Parameters:
      secureHash - the kba secureHash
      Returns:
      this config instance
    • getKbaPropertyName

      public String getKbaPropertyName()
      Gets the property name in user json instance where kba details will be set.
      Returns:
      property name
    • setKbaPropertyName

      public C setKbaPropertyName(String kbaPropertyName)
      Sets the property name in user json instance where kba details will be set.
      Parameters:
      kbaPropertyName - the property name
      Returns:
      this config instance
    • self

      protected abstract C self()
      Returns this object, as its actual type.
      Returns:
      this object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object