github.com/chnsz/golangsdk@v0.0.0-20240506093406-85a3fbfa605b/openstack/identity/v3.0/security/results.go (about)

     1  package security
     2  
     3  type PasswordPolicy struct {
     4  	// Minimum number of character types that a password must contain. Value range: 2–4.
     5  	MinCharCombination int `json:"password_char_combination"`
     6  	// Minimum number of characters that a password must contain. Value range: 6–32.
     7  	MinPasswordLength int `json:"minimum_password_length"`
     8  	// Maximum number of characters that a password can contain.
     9  	MaxPasswordLength int `json:"maximum_password_length"`
    10  	// Maximum number of times that a character is allowed to consecutively present in a password.
    11  	MaxConsecutiveIdenticalChars int `json:"maximum_consecutive_identical_chars"`
    12  	// Number of previously used passwords that are not allowed. Value range: 0–10.
    13  	RecentPasswordsDisallowedCount int `json:"number_of_recent_passwords_disallowed"`
    14  	// Password validity period (days). Value range: 0–180. Value 0 indicates that this requirement does not apply.
    15  	PasswordValidityPeriod int `json:"password_validity_period"`
    16  	// Minimum period (minutes) after which users are allowed to make a password change.
    17  	MinPasswordAge int `json:"minimum_password_age"`
    18  	// Indicates whether the password can be the username or the username spelled backwards.
    19  	PasswordNotUsernameOrInvert bool `json:"password_not_username_or_invert"`
    20  	// Characters that a password must contain.
    21  	PasswordRequirements string `json:"password_requirements"`
    22  }
    23  
    24  type PasswordPolicyResp struct {
    25  	Body PasswordPolicy `json:"password_policy"`
    26  }
    27  
    28  type ProtectPolicy struct {
    29  	// Indicates whether to enable operation protection.
    30  	Protection bool `json:"operation_protection"`
    31  	// the attributes IAM users can modify.
    32  	AllowUser AllowUserBody `json:"allow_user"`
    33  	// Indicates whether to designate a person for verification.
    34  	AdminCheck string `json:"admin_check"`
    35  	// the verification method. The optional values are mobile and email.
    36  	Scene string `json:"scene"`
    37  	// the mobile number used for verification. Example: 0086-123456789
    38  	Mobile string `json:"mobile"`
    39  	// the email address used for verification. An example value is example@email.com.
    40  	Email string `json:"email"`
    41  }
    42  
    43  type AllowUserBody struct {
    44  	// Indicates whether to allow IAM users to manage access keys by themselves.
    45  	ManageAccesskey bool `json:"manage_accesskey"`
    46  	// Indicates whether to allow IAM users to change their email addresses.
    47  	ManageEmail bool `json:"manage_email"`
    48  	// Indicates whether to allow IAM users to change their mobile numbers.
    49  	ManageMobile bool `json:"manage_mobile"`
    50  	// Indicates whether to allow IAM users to change their passwords.
    51  	ManagePassword bool `json:"manage_password"`
    52  }
    53  
    54  type ProtectPolicyResp struct {
    55  	Body ProtectPolicy `json:"protect_policy"`
    56  }