Class UserPasswordSyntax


  • public class UserPasswordSyntax
    extends Object
    This class defines an attribute syntax used for storing values that have been encoded using a password storage scheme. The format for attribute values with this syntax is the concatenation of the following elements in the given order:
    • An opening curly brace ("{ private static final LocalizedLogger logger = LocalizedLogger.getLoggerForThisClass(); ") character.
    • The name of the storage scheme used to encode the value.
    • A closing curly brace ("}") character.
    • The encoded value.
    • Constructor Detail

      • UserPasswordSyntax

        public UserPasswordSyntax()
    • Method Detail

      • decodeUserPassword

        public static String[] decodeUserPassword​(String userPasswordValue)
                                           throws DirectoryException
        Decodes the provided user password value into its component parts.
        Parameters:
        userPasswordValue - The user password value to be decoded.
        Returns:
        A two-element string array whose elements are the storage scheme name (in all lowercase characters) and the encoded value, in that order.
        Throws:
        DirectoryException - If a problem is encountered while attempting to decode the value.
      • isEncoded

        public static boolean isEncoded​(ByteSequence value)
        Indicates whether the provided value is encoded using the user password syntax.
        Parameters:
        value - The value for which to make the determination.
        Returns:
        true if the value appears to be encoded using the user password syntax, or false if not.