Class DictionaryRule

All Implemented Interfaces:
Rule

public class DictionaryRule extends AbstractDictionaryRule
Rule for determining if a password matches a dictionary word. This rule will optionally also check for reversed words.
  • Field Details

    • ERROR_CODE

      public static final String ERROR_CODE
      Error code for matching dictionary word.
      See Also:
    • ERROR_CODE_REVERSED

      public static final String ERROR_CODE_REVERSED
      Error code for matching reversed dictionary word.
      See Also:
  • Constructor Details

    • DictionaryRule

      public DictionaryRule(Dictionary dict)
      Creates a new dictionary rule. The dictionary should be ready to use when passed to this constructor.
      Parameters:
      dict - to use for searching
    • DictionaryRule

      public DictionaryRule(Dictionary dict, boolean matchBackwards)
      Creates a new dictionary rule. The dictionary should be ready to use when passed to this constructor.
      Parameters:
      dict - to use for searching
      matchBackwards - whether to match dictionary words backwards
  • Method Details