| | |
| | | import org.opends.server.api.AttributeSyntax; |
| | | import org.opends.server.types.DirectoryException; |
| | | |
| | | |
| | | /** |
| | | * This class defines the auth password attribute syntax, which is defined in |
| | | * RFC 3112 and is used to hold authentication information. Only equality |
| | |
| | | super(); |
| | | } |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public Syntax getSDKSyntax(Schema schema) |
| | | { |
| | |
| | | * @throws DirectoryException If a problem is encountered while attempting |
| | | * to decode the value. |
| | | */ |
| | | public static StringBuilder[] decodeAuthPassword(String authPasswordValue) |
| | | throws DirectoryException |
| | | public static String[] decodeAuthPassword(String authPasswordValue) throws DirectoryException |
| | | { |
| | | // Create placeholders for the values to return. |
| | | StringBuilder scheme = new StringBuilder(); |
| | |
| | | |
| | | |
| | | // If we've gotten here, then everything must be OK. |
| | | return new StringBuilder[] |
| | | return new String[] |
| | | { |
| | | scheme, |
| | | authInfo, |
| | | authValue |
| | | scheme.toString(), |
| | | authInfo.toString(), |
| | | authValue.toString() |
| | | }; |
| | | } |
| | | |
| | |
| | | */ |
| | | public static boolean isEncoded(ByteSequence value) |
| | | { |
| | | // FIXME -- Make this more efficient, and don't use exceptions for flow |
| | | // control. |
| | | |
| | | |
| | | // FIXME -- Make this more efficient, and don't use exceptions for flow control. |
| | | try |
| | | { |
| | | decodeAuthPassword(value.toString()); |