Copyright | (c) 2013-2023 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Generates a random password. We recommend that you specify the maximum length and include every character type that the system you are generating a password for can support.
Secrets Manager generates a CloudTrail log entry when you call this action. Do not include sensitive information in request parameters because it might be logged. For more information, see Logging Secrets Manager events with CloudTrail.
Required permissions: secretsmanager:GetRandomPassword
. For more
information, see
IAM policy actions for Secrets Manager
and
Authentication and access control in Secrets Manager.
Synopsis
- data GetRandomPassword = GetRandomPassword' {}
- newGetRandomPassword :: GetRandomPassword
- getRandomPassword_excludeCharacters :: Lens' GetRandomPassword (Maybe Text)
- getRandomPassword_excludeLowercase :: Lens' GetRandomPassword (Maybe Bool)
- getRandomPassword_excludeNumbers :: Lens' GetRandomPassword (Maybe Bool)
- getRandomPassword_excludePunctuation :: Lens' GetRandomPassword (Maybe Bool)
- getRandomPassword_excludeUppercase :: Lens' GetRandomPassword (Maybe Bool)
- getRandomPassword_includeSpace :: Lens' GetRandomPassword (Maybe Bool)
- getRandomPassword_passwordLength :: Lens' GetRandomPassword (Maybe Natural)
- getRandomPassword_requireEachIncludedType :: Lens' GetRandomPassword (Maybe Bool)
- data GetRandomPasswordResponse = GetRandomPasswordResponse' {
- randomPassword :: Maybe (Sensitive Text)
- httpStatus :: Int
- newGetRandomPasswordResponse :: Int -> GetRandomPasswordResponse
- getRandomPasswordResponse_randomPassword :: Lens' GetRandomPasswordResponse (Maybe Text)
- getRandomPasswordResponse_httpStatus :: Lens' GetRandomPasswordResponse Int
Creating a Request
data GetRandomPassword Source #
See: newGetRandomPassword
smart constructor.
GetRandomPassword' | |
|
Instances
newGetRandomPassword :: GetRandomPassword Source #
Create a value of GetRandomPassword
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:excludeCharacters:GetRandomPassword'
, getRandomPassword_excludeCharacters
- A string of the characters that you don't want in the password.
$sel:excludeLowercase:GetRandomPassword'
, getRandomPassword_excludeLowercase
- Specifies whether to exclude lowercase letters from the password. If you
don't include this switch, the password can contain lowercase letters.
$sel:excludeNumbers:GetRandomPassword'
, getRandomPassword_excludeNumbers
- Specifies whether to exclude numbers from the password. If you don't
include this switch, the password can contain numbers.
$sel:excludePunctuation:GetRandomPassword'
, getRandomPassword_excludePunctuation
- Specifies whether to exclude the following punctuation characters from
the password:
! " # $ % & ' ( ) * + , - . / : ; < = > ? @ [ \ ] ^ _ ` { | } ~
.
If you don't include this switch, the password can contain punctuation.
$sel:excludeUppercase:GetRandomPassword'
, getRandomPassword_excludeUppercase
- Specifies whether to exclude uppercase letters from the password. If you
don't include this switch, the password can contain uppercase letters.
$sel:includeSpace:GetRandomPassword'
, getRandomPassword_includeSpace
- Specifies whether to include the space character. If you include this
switch, the password can contain space characters.
$sel:passwordLength:GetRandomPassword'
, getRandomPassword_passwordLength
- The length of the password. If you don't include this parameter, the
default length is 32 characters.
$sel:requireEachIncludedType:GetRandomPassword'
, getRandomPassword_requireEachIncludedType
- Specifies whether to include at least one upper and lowercase letter,
one number, and one punctuation. If you don't include this switch, the
password contains at least one of every character type.
Request Lenses
getRandomPassword_excludeCharacters :: Lens' GetRandomPassword (Maybe Text) Source #
A string of the characters that you don't want in the password.
getRandomPassword_excludeLowercase :: Lens' GetRandomPassword (Maybe Bool) Source #
Specifies whether to exclude lowercase letters from the password. If you don't include this switch, the password can contain lowercase letters.
getRandomPassword_excludeNumbers :: Lens' GetRandomPassword (Maybe Bool) Source #
Specifies whether to exclude numbers from the password. If you don't include this switch, the password can contain numbers.
getRandomPassword_excludePunctuation :: Lens' GetRandomPassword (Maybe Bool) Source #
Specifies whether to exclude the following punctuation characters from
the password:
! " # $ % & ' ( ) * + , - . / : ; < = > ? @ [ \ ] ^ _ ` { | } ~
.
If you don't include this switch, the password can contain punctuation.
getRandomPassword_excludeUppercase :: Lens' GetRandomPassword (Maybe Bool) Source #
Specifies whether to exclude uppercase letters from the password. If you don't include this switch, the password can contain uppercase letters.
getRandomPassword_includeSpace :: Lens' GetRandomPassword (Maybe Bool) Source #
Specifies whether to include the space character. If you include this switch, the password can contain space characters.
getRandomPassword_passwordLength :: Lens' GetRandomPassword (Maybe Natural) Source #
The length of the password. If you don't include this parameter, the default length is 32 characters.
getRandomPassword_requireEachIncludedType :: Lens' GetRandomPassword (Maybe Bool) Source #
Specifies whether to include at least one upper and lowercase letter, one number, and one punctuation. If you don't include this switch, the password contains at least one of every character type.
Destructuring the Response
data GetRandomPasswordResponse Source #
See: newGetRandomPasswordResponse
smart constructor.
GetRandomPasswordResponse' | |
|
Instances
newGetRandomPasswordResponse Source #
Create a value of GetRandomPasswordResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:randomPassword:GetRandomPasswordResponse'
, getRandomPasswordResponse_randomPassword
- A string with the password.
$sel:httpStatus:GetRandomPasswordResponse'
, getRandomPasswordResponse_httpStatus
- The response's http status code.
Response Lenses
getRandomPasswordResponse_randomPassword :: Lens' GetRandomPasswordResponse (Maybe Text) Source #
A string with the password.
getRandomPasswordResponse_httpStatus :: Lens' GetRandomPasswordResponse Int Source #
The response's http status code.