Class PasswordPolicy
- java.lang.Object
-
- com.amazonaws.services.identitymanagement.model.PasswordPolicy
-
- All Implemented Interfaces:
Serializable,Cloneable
public class PasswordPolicy extends Object implements Serializable, Cloneable
Contains information about the account password policy.
This data type is used as a response element in the GetAccountPasswordPolicy action.
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description PasswordPolicy()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PasswordPolicyclone()booleanequals(Object obj)BooleangetAllowUsersToChangePassword()Specifies whether IAM users are allowed to change their own password.BooleangetExpirePasswords()Indicates whether passwords in the account expire.BooleangetHardExpiry()Specifies whether IAM users are prevented from setting a new password after their password has expired.IntegergetMaxPasswordAge()The number of days that an IAM user password is valid.IntegergetMinimumPasswordLength()Minimum length to require for IAM user passwords.IntegergetPasswordReusePrevention()Specifies the number of previous passwords that IAM users are prevented from reusing.BooleangetRequireLowercaseCharacters()Specifies whether to require lowercase characters for IAM user passwords.BooleangetRequireNumbers()Specifies whether to require numbers for IAM user passwords.BooleangetRequireSymbols()Specifies whether to require symbols for IAM user passwords.BooleangetRequireUppercaseCharacters()Specifies whether to require uppercase characters for IAM user passwords.inthashCode()BooleanisAllowUsersToChangePassword()Specifies whether IAM users are allowed to change their own password.BooleanisExpirePasswords()Indicates whether passwords in the account expire.BooleanisHardExpiry()Specifies whether IAM users are prevented from setting a new password after their password has expired.BooleanisRequireLowercaseCharacters()Specifies whether to require lowercase characters for IAM user passwords.BooleanisRequireNumbers()Specifies whether to require numbers for IAM user passwords.BooleanisRequireSymbols()Specifies whether to require symbols for IAM user passwords.BooleanisRequireUppercaseCharacters()Specifies whether to require uppercase characters for IAM user passwords.voidsetAllowUsersToChangePassword(Boolean allowUsersToChangePassword)Specifies whether IAM users are allowed to change their own password.voidsetExpirePasswords(Boolean expirePasswords)Indicates whether passwords in the account expire.voidsetHardExpiry(Boolean hardExpiry)Specifies whether IAM users are prevented from setting a new password after their password has expired.voidsetMaxPasswordAge(Integer maxPasswordAge)The number of days that an IAM user password is valid.voidsetMinimumPasswordLength(Integer minimumPasswordLength)Minimum length to require for IAM user passwords.voidsetPasswordReusePrevention(Integer passwordReusePrevention)Specifies the number of previous passwords that IAM users are prevented from reusing.voidsetRequireLowercaseCharacters(Boolean requireLowercaseCharacters)Specifies whether to require lowercase characters for IAM user passwords.voidsetRequireNumbers(Boolean requireNumbers)Specifies whether to require numbers for IAM user passwords.voidsetRequireSymbols(Boolean requireSymbols)Specifies whether to require symbols for IAM user passwords.voidsetRequireUppercaseCharacters(Boolean requireUppercaseCharacters)Specifies whether to require uppercase characters for IAM user passwords.StringtoString()Returns a string representation of this object; useful for testing and debugging.PasswordPolicywithAllowUsersToChangePassword(Boolean allowUsersToChangePassword)Specifies whether IAM users are allowed to change their own password.PasswordPolicywithExpirePasswords(Boolean expirePasswords)Indicates whether passwords in the account expire.PasswordPolicywithHardExpiry(Boolean hardExpiry)Specifies whether IAM users are prevented from setting a new password after their password has expired.PasswordPolicywithMaxPasswordAge(Integer maxPasswordAge)The number of days that an IAM user password is valid.PasswordPolicywithMinimumPasswordLength(Integer minimumPasswordLength)Minimum length to require for IAM user passwords.PasswordPolicywithPasswordReusePrevention(Integer passwordReusePrevention)Specifies the number of previous passwords that IAM users are prevented from reusing.PasswordPolicywithRequireLowercaseCharacters(Boolean requireLowercaseCharacters)Specifies whether to require lowercase characters for IAM user passwords.PasswordPolicywithRequireNumbers(Boolean requireNumbers)Specifies whether to require numbers for IAM user passwords.PasswordPolicywithRequireSymbols(Boolean requireSymbols)Specifies whether to require symbols for IAM user passwords.PasswordPolicywithRequireUppercaseCharacters(Boolean requireUppercaseCharacters)Specifies whether to require uppercase characters for IAM user passwords.
-
-
-
Method Detail
-
setMinimumPasswordLength
public void setMinimumPasswordLength(Integer minimumPasswordLength)
Minimum length to require for IAM user passwords.
- Parameters:
minimumPasswordLength- Minimum length to require for IAM user passwords.
-
getMinimumPasswordLength
public Integer getMinimumPasswordLength()
Minimum length to require for IAM user passwords.
- Returns:
- Minimum length to require for IAM user passwords.
-
withMinimumPasswordLength
public PasswordPolicy withMinimumPasswordLength(Integer minimumPasswordLength)
Minimum length to require for IAM user passwords.
- Parameters:
minimumPasswordLength- Minimum length to require for IAM user passwords.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setRequireSymbols
public void setRequireSymbols(Boolean requireSymbols)
Specifies whether to require symbols for IAM user passwords.
- Parameters:
requireSymbols- Specifies whether to require symbols for IAM user passwords.
-
getRequireSymbols
public Boolean getRequireSymbols()
Specifies whether to require symbols for IAM user passwords.
- Returns:
- Specifies whether to require symbols for IAM user passwords.
-
withRequireSymbols
public PasswordPolicy withRequireSymbols(Boolean requireSymbols)
Specifies whether to require symbols for IAM user passwords.
- Parameters:
requireSymbols- Specifies whether to require symbols for IAM user passwords.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
isRequireSymbols
public Boolean isRequireSymbols()
Specifies whether to require symbols for IAM user passwords.
- Returns:
- Specifies whether to require symbols for IAM user passwords.
-
setRequireNumbers
public void setRequireNumbers(Boolean requireNumbers)
Specifies whether to require numbers for IAM user passwords.
- Parameters:
requireNumbers- Specifies whether to require numbers for IAM user passwords.
-
getRequireNumbers
public Boolean getRequireNumbers()
Specifies whether to require numbers for IAM user passwords.
- Returns:
- Specifies whether to require numbers for IAM user passwords.
-
withRequireNumbers
public PasswordPolicy withRequireNumbers(Boolean requireNumbers)
Specifies whether to require numbers for IAM user passwords.
- Parameters:
requireNumbers- Specifies whether to require numbers for IAM user passwords.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
isRequireNumbers
public Boolean isRequireNumbers()
Specifies whether to require numbers for IAM user passwords.
- Returns:
- Specifies whether to require numbers for IAM user passwords.
-
setRequireUppercaseCharacters
public void setRequireUppercaseCharacters(Boolean requireUppercaseCharacters)
Specifies whether to require uppercase characters for IAM user passwords.
- Parameters:
requireUppercaseCharacters- Specifies whether to require uppercase characters for IAM user passwords.
-
getRequireUppercaseCharacters
public Boolean getRequireUppercaseCharacters()
Specifies whether to require uppercase characters for IAM user passwords.
- Returns:
- Specifies whether to require uppercase characters for IAM user passwords.
-
withRequireUppercaseCharacters
public PasswordPolicy withRequireUppercaseCharacters(Boolean requireUppercaseCharacters)
Specifies whether to require uppercase characters for IAM user passwords.
- Parameters:
requireUppercaseCharacters- Specifies whether to require uppercase characters for IAM user passwords.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
isRequireUppercaseCharacters
public Boolean isRequireUppercaseCharacters()
Specifies whether to require uppercase characters for IAM user passwords.
- Returns:
- Specifies whether to require uppercase characters for IAM user passwords.
-
setRequireLowercaseCharacters
public void setRequireLowercaseCharacters(Boolean requireLowercaseCharacters)
Specifies whether to require lowercase characters for IAM user passwords.
- Parameters:
requireLowercaseCharacters- Specifies whether to require lowercase characters for IAM user passwords.
-
getRequireLowercaseCharacters
public Boolean getRequireLowercaseCharacters()
Specifies whether to require lowercase characters for IAM user passwords.
- Returns:
- Specifies whether to require lowercase characters for IAM user passwords.
-
withRequireLowercaseCharacters
public PasswordPolicy withRequireLowercaseCharacters(Boolean requireLowercaseCharacters)
Specifies whether to require lowercase characters for IAM user passwords.
- Parameters:
requireLowercaseCharacters- Specifies whether to require lowercase characters for IAM user passwords.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
isRequireLowercaseCharacters
public Boolean isRequireLowercaseCharacters()
Specifies whether to require lowercase characters for IAM user passwords.
- Returns:
- Specifies whether to require lowercase characters for IAM user passwords.
-
setAllowUsersToChangePassword
public void setAllowUsersToChangePassword(Boolean allowUsersToChangePassword)
Specifies whether IAM users are allowed to change their own password.
- Parameters:
allowUsersToChangePassword- Specifies whether IAM users are allowed to change their own password.
-
getAllowUsersToChangePassword
public Boolean getAllowUsersToChangePassword()
Specifies whether IAM users are allowed to change their own password.
- Returns:
- Specifies whether IAM users are allowed to change their own password.
-
withAllowUsersToChangePassword
public PasswordPolicy withAllowUsersToChangePassword(Boolean allowUsersToChangePassword)
Specifies whether IAM users are allowed to change their own password.
- Parameters:
allowUsersToChangePassword- Specifies whether IAM users are allowed to change their own password.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
isAllowUsersToChangePassword
public Boolean isAllowUsersToChangePassword()
Specifies whether IAM users are allowed to change their own password.
- Returns:
- Specifies whether IAM users are allowed to change their own password.
-
setExpirePasswords
public void setExpirePasswords(Boolean expirePasswords)
Indicates whether passwords in the account expire. Returns true if MaxPasswordAge is contains a value greater than 0. Returns false if MaxPasswordAge is 0 or not present.
- Parameters:
expirePasswords- Indicates whether passwords in the account expire. Returns true if MaxPasswordAge is contains a value greater than 0. Returns false if MaxPasswordAge is 0 or not present.
-
getExpirePasswords
public Boolean getExpirePasswords()
Indicates whether passwords in the account expire. Returns true if MaxPasswordAge is contains a value greater than 0. Returns false if MaxPasswordAge is 0 or not present.
- Returns:
- Indicates whether passwords in the account expire. Returns true if MaxPasswordAge is contains a value greater than 0. Returns false if MaxPasswordAge is 0 or not present.
-
withExpirePasswords
public PasswordPolicy withExpirePasswords(Boolean expirePasswords)
Indicates whether passwords in the account expire. Returns true if MaxPasswordAge is contains a value greater than 0. Returns false if MaxPasswordAge is 0 or not present.
- Parameters:
expirePasswords- Indicates whether passwords in the account expire. Returns true if MaxPasswordAge is contains a value greater than 0. Returns false if MaxPasswordAge is 0 or not present.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
isExpirePasswords
public Boolean isExpirePasswords()
Indicates whether passwords in the account expire. Returns true if MaxPasswordAge is contains a value greater than 0. Returns false if MaxPasswordAge is 0 or not present.
- Returns:
- Indicates whether passwords in the account expire. Returns true if MaxPasswordAge is contains a value greater than 0. Returns false if MaxPasswordAge is 0 or not present.
-
setMaxPasswordAge
public void setMaxPasswordAge(Integer maxPasswordAge)
The number of days that an IAM user password is valid.
- Parameters:
maxPasswordAge- The number of days that an IAM user password is valid.
-
getMaxPasswordAge
public Integer getMaxPasswordAge()
The number of days that an IAM user password is valid.
- Returns:
- The number of days that an IAM user password is valid.
-
withMaxPasswordAge
public PasswordPolicy withMaxPasswordAge(Integer maxPasswordAge)
The number of days that an IAM user password is valid.
- Parameters:
maxPasswordAge- The number of days that an IAM user password is valid.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setPasswordReusePrevention
public void setPasswordReusePrevention(Integer passwordReusePrevention)
Specifies the number of previous passwords that IAM users are prevented from reusing.
- Parameters:
passwordReusePrevention- Specifies the number of previous passwords that IAM users are prevented from reusing.
-
getPasswordReusePrevention
public Integer getPasswordReusePrevention()
Specifies the number of previous passwords that IAM users are prevented from reusing.
- Returns:
- Specifies the number of previous passwords that IAM users are prevented from reusing.
-
withPasswordReusePrevention
public PasswordPolicy withPasswordReusePrevention(Integer passwordReusePrevention)
Specifies the number of previous passwords that IAM users are prevented from reusing.
- Parameters:
passwordReusePrevention- Specifies the number of previous passwords that IAM users are prevented from reusing.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setHardExpiry
public void setHardExpiry(Boolean hardExpiry)
Specifies whether IAM users are prevented from setting a new password after their password has expired.
- Parameters:
hardExpiry- Specifies whether IAM users are prevented from setting a new password after their password has expired.
-
getHardExpiry
public Boolean getHardExpiry()
Specifies whether IAM users are prevented from setting a new password after their password has expired.
- Returns:
- Specifies whether IAM users are prevented from setting a new password after their password has expired.
-
withHardExpiry
public PasswordPolicy withHardExpiry(Boolean hardExpiry)
Specifies whether IAM users are prevented from setting a new password after their password has expired.
- Parameters:
hardExpiry- Specifies whether IAM users are prevented from setting a new password after their password has expired.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
isHardExpiry
public Boolean isHardExpiry()
Specifies whether IAM users are prevented from setting a new password after their password has expired.
- Returns:
- Specifies whether IAM users are prevented from setting a new password after their password has expired.
-
toString
public String toString()
Returns a string representation of this object; useful for testing and debugging.- Overrides:
toStringin classObject- Returns:
- A string representation of this object.
- See Also:
Object.toString()
-
clone
public PasswordPolicy clone()
-
-