com.ibm.passwordrules.standard
Class NotReversed

java.lang.Object
  |
  +--com.ibm.passwordrules.BehavioralRule
        |
        +--com.ibm.passwordrules.standard.NotReversed
All Implemented Interfaces:
java.lang.Cloneable, Rule, java.io.Serializable

public class NotReversed
extends BehavioralRule

This class implements built-in rule for restricting passwords to be different then previously used passwords present in a reversed history list.

See Also:
Serialized Form

Field Summary
static java.lang.String REUSED
          Constant representing a message key in a property file
 
Constructor Summary
NotReversed()
          Default constructor.
NotReversed(int historyLength)
          Constructor accepting int parameter specifying the length of the reversed password history.
 
Method Summary
 int getHistoryLength()
          Method obtains the length of revered password history.
 boolean join(Rule rule)
          Try to join the specified rule with this one.
 void setHistoryLength(int historyLength)
          Set the length of reveresed password history.
 boolean validate(java.lang.String password, ValidationInfo validationInfo)
          Validate the given password using the given validation info.
 
Methods inherited from class com.ibm.passwordrules.BehavioralRule
constrain, getParameter, setParameter, validateSafe
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

REUSED

public static final java.lang.String REUSED
Constant representing a message key in a property file

See Also:
Constant Field Values
Constructor Detail

NotReversed

public NotReversed()
Default constructor.


NotReversed

public NotReversed(int historyLength)
Constructor accepting int parameter specifying the length of the reversed password history.

Parameters:
historyLength - int value representing the number of consecutive historical passwords to be checked.
Method Detail

getHistoryLength

public int getHistoryLength()
Method obtains the length of revered password history.

Returns:
int value representing the password history length.

setHistoryLength

public void setHistoryLength(int historyLength)
Set the length of reveresed password history.

Parameters:
historyLength - int value representing the reveresed password history length.

validate

public boolean validate(java.lang.String password,
                        ValidationInfo validationInfo)
                 throws InvalidPasswordException
Validate the given password using the given validation info.

Specified by:
validate in interface Rule
Overrides:
validate in class BehavioralRule
Parameters:
validationInfo - contains contextual information about the password being validated.
password - Password to validate.
Returns:
always return true
Throws:
InvalidPasswordException - thrown when password is invalid.

join

public boolean join(Rule rule)
             throws IncompatibleRulesException
Try to join the specified rule with this one. The more restrictive rule takes precedence.

Specified by:
join in interface Rule
Overrides:
join in class BehavioralRule
Parameters:
rule - The rule to be joined with this one.
Returns:
True if the rule was successfully joined.
Throws:
IncompatibleRulesException - Thrown when given rule cannot be joined because it is not compatible.


IBM Tivoli Identity Manager 4.6
© Copyright International Business Machines Corporation 2005. All rights reserved. US Government Users Restricted Rights Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.