mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Nemanja Lukic
03.19.2011 355380570585a18ce313739f85a89224779c03a7
Follow-up to the OPENDJ-295 patch: fixed the checkstyle errors and added the missing properties file.
2 files modified
12 ■■■■■ changed files
opends/src/admin/messages/DictionaryPasswordValidatorCfgDefn.properties 4 ●●●● patch | view | raw | blame | history
opends/src/server/org/opends/server/extensions/DictionaryPasswordValidator.java 8 ●●●● patch | view | raw | blame | history
opends/src/admin/messages/DictionaryPasswordValidatorCfgDefn.properties
@@ -4,10 +4,14 @@
description=A large dictionary file is provided with the server, but the administrator can supply an alternate dictionary. In this case, then the dictionary must be a plain-text file with one word per line.
property.case-sensitive-validation.synopsis=Indicates whether this password validator is to treat password characters in a case-sensitive manner.
property.case-sensitive-validation.description=If it is set to true, then the validator rejects a password only if it appears in the dictionary with exactly the same capitalization as provided by the user.
property.check-substrings.synopsis=Indicates wheather this password validator is to match portions of the password string against dictionary words.
property.check-substrings.description=If "false" then only match the entire password against words otherwise ("true") check whether the password contains words.
property.dictionary-file.synopsis=Specifies the path to the file containing a list of words that cannot be used as passwords.
property.dictionary-file.description=It should be formatted with one word per line. The value can be an absolute path or a path that is relative to the OpenDJ instance root.
property.dictionary-file.syntax.string.pattern.synopsis=The path to any text file contained on the system that is readable by the server.
property.enabled.synopsis=Indicates whether the password validator is enabled for use.
property.java-class.synopsis=Specifies the fully-qualified name of the Java class that provides the password validator implementation.
property.min-substring-length.synopsis=Indicates the minimal length of the substring within the password in case substring checking is enabled.
property.min-substring-length.description=If "check-substrings" option is set to true, then this parameter defines the length of the smallest word which should be used for substring matching. Use with caution because values below 3 might disqualify valid passwords.
property.test-reversed-password.synopsis=Indicates whether this password validator is to test the reversed value of the provided password as well as the order in which it was given.
property.test-reversed-password.description=For example, if the user provides a new password of "password" and this configuration attribute is set to true, then the value "drowssap" is also tested against attribute values in the user's entry.
opends/src/server/org/opends/server/extensions/DictionaryPasswordValidator.java
@@ -125,7 +125,7 @@
  {
    // Get a handle to the current configuration.
    DictionaryPasswordValidatorCfg config = currentConfig;
    // Check to see if the provided password is in the dictionary in the order
    // that it was provided.
    String password = newPassword.toString();
@@ -148,7 +148,7 @@
        minSubstringLength = config.getMinSubstringLength();
      }
    }
    // Verify if the dictionary contains the word(s) in the password
    if (isDictionaryBased(password, minSubstringLength))
    {
@@ -156,7 +156,7 @@
        ERR_DICTIONARY_VALIDATOR_PASSWORD_IN_DICTIONARY.get());
      return false;
    }
    // If the reverse password checking is enabled, then verify if the
    // reverse value of the password is in the dictionary.
    if (config.isTestReversedPassword())
@@ -170,7 +170,7 @@
      }
    }
    // If we've gotten here, then the password is acceptable.
    return true;
  }