@NotMutable @ThreadSafety(level=COMPLETELY_THREADSAFE) public final class PasswordQualityRequirement extends java.lang.Object implements java.io.Serializable
NOTE: This class, and other classes within the
com.unboundid.ldap.sdk.unboundidds
package structure, are only
supported for use against Ping Identity, UnboundID, and
Nokia/Alcatel-Lucent 8661 server products. These classes provide support
for proprietary functionality or for external specifications that are not
considered stable or mature enough to be guaranteed to work in an
interoperable way with other types of LDAP servers.
PasswordQualityRequirement ::= SEQUENCE { description OCTET STRING, clientSideValidationInfo [0] SEQUENCE { validationType OCTET STRING, properties [0] SET OF SEQUENCE { name OCTET STRING, value OCTET STRING } OPTIONAL } OPTIONAL }
Constructor and Description |
---|
PasswordQualityRequirement(java.lang.String description)
Creates a new password quality requirement object without any support for
client-side validation.
|
PasswordQualityRequirement(java.lang.String description,
java.lang.String clientSideValidationType,
java.util.Map<java.lang.String,java.lang.String> clientSideValidationProperties)
Creates a new password quality requirement object with optional support for
client-side validation.
|
Modifier and Type | Method and Description |
---|---|
static PasswordQualityRequirement |
decode(ASN1Element element)
Decodes the provided ASN.1 element as a password quality requirement.
|
ASN1Element |
encode()
Encodes this password quality requirement to an ASN.1 element that may be
included in LDAP protocol elements that may need to include it (e.g., a
get password quality requirements extended response or a password
validation details response control).
|
java.util.Map<java.lang.String,java.lang.String> |
getClientSideValidationProperties()
Retrieves a set of properties that may be used in the course of performing
client-side validation for a proposed password.
|
java.lang.String |
getClientSideValidationType()
Retrieves a string that identifies the type of client-side validation that
may be performed by applications in order to identify potential problems
with a proposed password before sending it to the server.
|
java.lang.String |
getDescription()
Retrieves a user-friendly description of the constraints that a proposed
password must satisfy in order to meet this requirement and be accepted
by the server.
|
java.lang.String |
toString()
Retrieves a string representation of this password quality requirement.
|
void |
toString(java.lang.StringBuilder buffer)
Appends a string representation of this password quality requirement to the
provided buffer.
|
public PasswordQualityRequirement(@NotNull java.lang.String description)
description
- A user-friendly description of the constraints that a
proposed password must satisfy in order to meet this
requirement and be accepted by the server. This must
not be null
.public PasswordQualityRequirement(@NotNull java.lang.String description, @Nullable java.lang.String clientSideValidationType, @Nullable java.util.Map<java.lang.String,java.lang.String> clientSideValidationProperties)
description
- A user-friendly description of the
constraints that a proposed
password must satisfy in order to
meet this requirement and be
accepted by the server. This must
not be null
.clientSideValidationType
- An optional string that identifies
the type of validation associated
with this requirement.
Applications that support
client-side validation and
recognize this validation type can
attempt to use their own logic in
attempt to determine whether a
proposed password may be rejected
by the server because it does not
satisfy this requirement. This may
be null
if no client-side
validation is available for this
requirement.clientSideValidationProperties
- An optional map of property names
and values that may provide
additional information that can be
used for client-side validation.
The properties that may be included
depend on the validation type.
This must be empty or null
if the provided validation type is
null
. It may also be empty
or null
if no additional
properties are required for the
associated type of client-side
validation.@NotNull public java.lang.String getDescription()
@Nullable public java.lang.String getClientSideValidationType()
null
if client-side validation is not
supported for this password quality requirement.@NotNull public java.util.Map<java.lang.String,java.lang.String> getClientSideValidationProperties()
@NotNull public ASN1Element encode()
@NotNull public static PasswordQualityRequirement decode(@NotNull ASN1Element element) throws LDAPException
element
- The ASN.1 element to decode as a password quality
requirement. It must not be null
.LDAPException
- If a problem was encountered while attempting to
decode the provided ASN.1 element as a password
quality requirement.@NotNull public java.lang.String toString()
toString
in class java.lang.Object