PasswordPolicy

class aws_cdk.aws_cognito.PasswordPolicy(*, min_length=None, require_digits=None, require_lowercase=None, require_symbols=None, require_uppercase=None, temp_password_validity=None)

Bases: object

(experimental) Password policy for User Pools.

Parameters
  • min_length (Union[int, float, None]) – (experimental) Minimum length required for a user’s password. Default: 8

  • require_digits (Optional[bool]) – (experimental) Whether the user is required to have digits in their password. Default: true

  • require_lowercase (Optional[bool]) – (experimental) Whether the user is required to have lowercase characters in their password. Default: true

  • require_symbols (Optional[bool]) – (experimental) Whether the user is required to have symbols in their password. Default: true

  • require_uppercase (Optional[bool]) – (experimental) Whether the user is required to have uppercase characters in their password. Default: true

  • temp_password_validity (Optional[Duration]) – (experimental) The length of time the temporary password generated by an admin is valid. 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

experimental

Attributes

min_length

(experimental) Minimum length required for a user’s password.

Default

8

Stability

experimental

Return type

Union[int, float, None]

require_digits

(experimental) Whether the user is required to have digits in their password.

Default

true

Stability

experimental

Return type

Optional[bool]

require_lowercase

(experimental) Whether the user is required to have lowercase characters in their password.

Default

true

Stability

experimental

Return type

Optional[bool]

require_symbols

(experimental) Whether the user is required to have symbols in their password.

Default

true

Stability

experimental

Return type

Optional[bool]

require_uppercase

(experimental) Whether the user is required to have uppercase characters in their password.

Default

true

Stability

experimental

Return type

Optional[bool]

temp_password_validity

(experimental) The length of time the temporary password generated by an admin is valid.

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

experimental

Return type

Optional[Duration]