@Generated(value="jsii-pacmak/1.71.0 (build f1f58ae)", date="2022-12-07T17:24:44.593Z") @Stability(value=Stable) public interface PasswordPolicy extends software.amazon.jsii.JsiiSerializable
Example:
UserPool.Builder.create(this, "myuserpool")
// ...
.passwordPolicy(PasswordPolicy.builder()
.minLength(12)
.requireLowercase(true)
.requireUppercase(true)
.requireDigits(true)
.requireSymbols(true)
.tempPasswordValidity(Duration.days(3))
.build())
.build();
| Modifier and Type | Interface and Description |
|---|---|
static class |
PasswordPolicy.Builder
A builder for
PasswordPolicy |
static class |
PasswordPolicy.Jsii$Proxy
An implementation for
PasswordPolicy |
| Modifier and Type | Method and Description |
|---|---|
static PasswordPolicy.Builder |
builder() |
default Number |
getMinLength()
Minimum length required for a user's password.
|
default Boolean |
getRequireDigits()
Whether the user is required to have digits in their password.
|
default Boolean |
getRequireLowercase()
Whether the user is required to have lowercase characters in their password.
|
default Boolean |
getRequireSymbols()
Whether the user is required to have symbols in their password.
|
default Boolean |
getRequireUppercase()
Whether the user is required to have uppercase characters in their password.
|
default Duration |
getTempPasswordValidity()
The length of time the temporary password generated by an admin is valid.
|
@Stability(value=Stable) @Nullable default Number getMinLength()
Default: 8
@Stability(value=Stable) @Nullable default Boolean getRequireDigits()
Default: true
@Stability(value=Stable) @Nullable default Boolean getRequireLowercase()
Default: true
@Stability(value=Stable) @Nullable default Boolean getRequireSymbols()
Default: true
@Stability(value=Stable) @Nullable default Boolean getRequireUppercase()
Default: true
@Stability(value=Stable) @Nullable default Duration getTempPasswordValidity()
This must be provided as whole days, like Duration.days(3) or Duration.hours(48). Fractional days, such as Duration.hours(20), will generate an error.
Default: Duration.days(7)
@Stability(value=Stable) static PasswordPolicy.Builder builder()
PasswordPolicy.Builder of PasswordPolicyCopyright © 2022. All rights reserved.