Create a new random password
New-RDMRandomPassword [-ForcePromptAnswer <DialogResult[]>] [<CommonParameters>]
New-RDMRandomPassword [[-Session] <PSConnection>] [-ForcePromptAnswer <DialogResult[]>]
[<CommonParameters>]
New-RDMRandomPassword -Mode <PasswordGeneratorMode> [-ForcePromptAnswer <DialogResult[]>]
[<CommonParameters>]
New-RDMRandomPassword [[-TemplateName] <string>] [-ForcePromptAnswer <DialogResult[]>]
[<CommonParameters>]
Create a new random password
PS C:\> $randomPassword = New-RDMRandomPassword
Generate a random password with the default settings
PS C:\> $randomPassword = New-RDMRandomPassword -TemplateName $templateName
Generate a random password with the template settings
PS C:\> $session = Get-RDMSession -Name MySession; $randomPassword = New-RDMRandomPassword -Session $session
Generate a random password with the password complexity of the session
PS C:\> $pwd = New-RandomPassword -Mode Default -MinimumDigit 10 -MinimumLength 1
Generate a random password composed of 10 digits.
PS C:\> $pwd = New-RandomPassword -Mode SpecifiedSettings -Digit 1 -Bracket 0 -Underline 1 -Lowercase 0 -Special 0 -Uppercase 0
Generate a random password composed of at least 1 digit and 1 underline. The other characters are either a digit, a lowercase, an uppercase, a special symbol, a bracket , or an underline. High ANSI, minus and space characters are not present in the password. There is not guarantuee the password is XML Compliant.
PS C:\> $pwd = New-RandomPassword -Mode Passphrase -AppendNumber LastWord -CapitalizeFirstLetter FirstWord -PassphraseLength 10 -WordSeparator ""
Generate a random password composed of 10 unspaced english words. Its first letter is the only one capitalized, and it ends with the only digit.
Switch to use with caution. It will automatically answer prompt asking yes/no, yes/no/cancel, or ok/cancel questions. In case of multiple prompts, multiple values can be passed to this parameter. Here are the accepted values:
Yes: Accept the prompt. Cover the OK and Automatic value.
No: Refuse the yes/no/cancel prompt. Cancel is the fallback option if there is not an option No.
Cancel: Cancel the yes/no/cancel prompt. No is the fallback option if there is not an option Cancel.
Type: System.Windows.Forms.DialogResult[]
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
Position: Named
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
Type: System.Nullable`1[Devolutions.RemoteDesktopManager.PasswordGeneratorMode]
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: Mode
Position: Named
IsRequired: true
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
Generate a random password with the password complexity of that session
Type: RemoteDesktopManager.PowerShellModule.PSOutputObject.PSConnection
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: Session
Position: 0
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
Generate a random password with the template settings.
Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: Template
Position: 0
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.
For more information, type "Get-Help New-RDMRandomPassword -detailed". For technical information, type "Get-Help New-RDMRandomPassword -full".