|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectedu.vt.middleware.password.AbstractDictionaryRule
edu.vt.middleware.password.DictionarySubstringRule
public class DictionarySubstringRule
Rule for determining if a password matches a dictionary word, or if it contains a dictionary word of a given minimum length or greater. This rule will optionally also check for reversed words.
| Field Summary | |
|---|---|
static int |
DEFAULT_WORD_LENGTH
Default word length. |
| Fields inherited from class edu.vt.middleware.password.AbstractDictionaryRule |
|---|
dictionary, ERROR_CODE, ERROR_CODE_REVERSED, matchBackwards |
| Constructor Summary | |
|---|---|
DictionarySubstringRule()
Creates a new dictionary substring rule. |
|
DictionarySubstringRule(edu.vt.middleware.dictionary.Dictionary dict)
Creates a new dictionary substring rule. |
|
DictionarySubstringRule(edu.vt.middleware.dictionary.Dictionary dict,
int n)
Create a new dictionary substring rule. |
|
| Method Summary | |
|---|---|
protected String |
doWordSearch(String text)
Searches the dictionary with the supplied text. |
int |
getWordLength()
Returns the number of characters that constitute a word in a password. |
void |
setWordLength(int n)
Sets the minimum number of characters that constitute a word in a password. |
| Methods inherited from class edu.vt.middleware.password.AbstractDictionaryRule |
|---|
createRuleResultDetailParameters, getDictionary, isMatchBackwards, setDictionary, setMatchBackwards, toString, validate |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final int DEFAULT_WORD_LENGTH
| Constructor Detail |
|---|
public DictionarySubstringRule()
AbstractDictionaryRule.setDictionary(Dictionary) method.
public DictionarySubstringRule(edu.vt.middleware.dictionary.Dictionary dict)
dict - to use for searching
public DictionarySubstringRule(edu.vt.middleware.dictionary.Dictionary dict,
int n)
setWordLength(int).
dict - to use for searchingn - number of characters to check in each dictionary word| Method Detail |
|---|
public void setWordLength(int n)
n - minimum number of characters to check in each dictionary wordpublic int getWordLength()
protected String doWordSearch(String text)
doWordSearch in class AbstractDictionaryRuletext - to search dictionary with
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||