edu.vt.middleware.password
Class SequenceRule

java.lang.Object
  extended by edu.vt.middleware.password.SequenceRule
All Implemented Interfaces:
Rule

public class SequenceRule
extends java.lang.Object
implements Rule

SequenceRule contains methods for determining if a password contains common keyboard sequences.

Version:
$Revision: 1724 $ $Date: 2010-10-29 13:47:59 -0400 (Fri, 29 Oct 2010) $
Author:
Middleware Services

Constructor Summary
SequenceRule()
          This creates a new SequenceRule.
SequenceRule(boolean mb, boolean ic)
          This will create a new SequenceRule with the supplied matchBackwards and ignoreCase settings.
 
Method Summary
 boolean isIgnoreCase()
          Get the value of the ignoreCase property.
 boolean isMatchBackwards()
          Get the value of the matchBackwards property.
 void setIgnoreCase(boolean b)
          This causes the verify method to ignore case when searching the for a sequence.
 void setMatchBackwards(boolean b)
          This causes the verify method to search the password for sequences spelled backwards as well as forwards.
 java.lang.String toString()
          This returns a string representation of this object.
 RuleResult validate(PasswordData passwordData)
          This returns whether or not the supplied password data meets the requirements of this rule.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SequenceRule

public SequenceRule()
This creates a new SequenceRule.


SequenceRule

public SequenceRule(boolean mb,
                    boolean ic)
This will create a new SequenceRule with the supplied matchBackwards and ignoreCase settings.

Parameters:
mb - boolean whether to match backwards
ic - boolean whether to ignore case
Method Detail

setIgnoreCase

public void setIgnoreCase(boolean b)
This causes the verify method to ignore case when searching the for a sequence.

Parameters:
b - boolean

isIgnoreCase

public boolean isIgnoreCase()
Get the value of the ignoreCase property.

Returns:
boolean

setMatchBackwards

public void setMatchBackwards(boolean b)
This causes the verify method to search the password for sequences spelled backwards as well as forwards.

Parameters:
b - boolean

isMatchBackwards

public boolean isMatchBackwards()
Get the value of the matchBackwards property.

Returns:
boolean

validate

public RuleResult validate(PasswordData passwordData)
This returns whether or not the supplied password data meets the requirements of this rule.

Specified by:
validate in interface Rule
Parameters:
passwordData - PasswordData to verify (not null).
Returns:
RuleResult - details on password verification

toString

public java.lang.String toString()
This returns a string representation of this object.

Overrides:
toString in class java.lang.Object
Returns:
String


Copyright © 2003-2010 Virginia Tech. All Rights Reserved.