Class AuthenticationPolicyCmdImpl

  • All Implemented Interfaces:, ECCommand, ECTargetableCommand, TaskCommand, AuthenticationPolicyCmd,,,,,,

    public class AuthenticationPolicyCmdImpl
    extends TaskCommandImpl
    implements AuthenticationPolicyCmd

    Use this task command to enforce policies such as minimum password length. This task command is called by every command that performs verification or update of user credentials.

    Before executing this task command, the methods listed below must be invoked.

    • setLogonId
    • setPassword
    See Also:
    Serialized Form
    • Field Detail


        public static final java.lang.String COPYRIGHT
        IBM Copyright statement
        See Also:
        Constant Field Values

        public static java.lang.String ERRTASK_NAME
        Error task name.
    • Constructor Detail

      • AuthenticationPolicyCmdImpl

        public AuthenticationPolicyCmdImpl()
    • Method Detail

      • isPasswordCompliant

        public boolean isPasswordCompliant()
        After this task is executed, this method returns whether the user had a password policy and if the supplied password complies with that policy. If the user had a password policy and there is non-compliance then an exception is thrown.
        Specified by:
        isPasswordCompliant in interface AuthenticationPolicyCmd
        True if password complies with the user's password policy.
      • performExecute

        public void performExecute()
                            throws ECException
        This command fetches the password policies and delegates to the validatePasswordCompliance() method to determine if the password specified satisfies the policies. It terminates normally if the password matches the criteria and throws an ECApplicationException if a policy violation is detected. This method requires the following parameters to be set.
        • Security/PasswordPolicy parameter to be set to true.
        • MemberSubSystem/AuthenticationMode to be set to DB in the instance.xml file and to use database authentication.
        Specified by:
        performExecute in interface ECCommand
        Specified by:
        performExecute in interface
        performExecute in class AbstractECTargetableCommand
        ECException - thrown if a password policy violation is detected.
      • setAccountPolicy

        public void setAccountPolicy(java.lang.String strDefinedAccountPolicy)
        This method sets the account policy used to check this password. This overrides the default account policy for the user.
        Specified by:
        setAccountPolicy in interface AuthenticationPolicyCmd
        strDefinedAccountPolicy - The account policy.
      • setErrorTask

        public void setErrorTask(java.lang.String strErrorTask)
        This function allows for the default error view task of the command to be overwritten.
        Specified by:
        setErrorTask in interface AuthenticationPolicyCmd
        strErrorTask - The name of the new error view task.
      • setLogonId

        public void setLogonId(java.lang.String strLogonId)
        This method sets the logon ID under which the current user wishes to logon.
        Specified by:
        setLogonId in interface AuthenticationPolicyCmd
        strLogonId - The login ID.
      • setPassword

        public void setPassword(java.lang.String strPassword)
        This method sets the password to use for authentication with the new logon ID.
        Specified by:
        setPassword in interface AuthenticationPolicyCmd
        strPassword - The password.