New-Password
SYNOPSIS
SYNTAX
Simple (Default)
New-Password [-Count <Int32>] [-ReturnSecureStringObject] [-AllowInterchangableCharacters] [<CommonParameters>]
Custom
New-Password [-Length <Int32>] [-Signs <Int32>] [-Count <Int32>] [-Custom] [-ReturnSecureStringObject]
[-AllowInterchangableCharacters] [<CommonParameters>]
DESCRIPTION
Function that generates passwords
EXAMPLES
EXAMPLE 1
New-Password -Simple -Count 3
Wuba9710 Suve0945 Zigo1479
This example uses the method to create a password that is easy to remember but less secure.
EXAMPLE 2
New-Password -Length 10 -Signs 5
..&La:J%NF
This example creates a password of alphanumrerical characters including five signs/symbols.
EXAMPLE 3
New-Password -Length 20
J.rp318xVD?Twhah'K7b
This example creates a password of alpanumerical+signs characters
PARAMETERS
-Length
When the parameter set custom is used this parameter lets the user select how long the password should be. Defaults to 8.
Type: Int32
Parameter Sets: Custom
Aliases:
Required: False
Position: Named
Default value: 12
Accept pipeline input: False
Accept wildcard characters: False
-Signs
When the parameter set custom is used this parameter lets the user select how many signs/symbols that should be included in the password. Defaults to 3.
Type: Int32
Parameter Sets: Custom
Aliases:
Required: False
Position: Named
Default value: 3
Accept pipeline input: False
Accept wildcard characters: False
-Count
Defines the number of passwords to generate. This can be used to create batches of passwords. Defaults to 1.
Type: Int32
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: 1
Accept pipeline input: False
Accept wildcard characters: False
-Custom
Defines a custom rule for password selection
Type: SwitchParameter
Parameter Sets: Custom
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
-ReturnSecureStringObject
Return password as secure string
Type: SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
-AllowInterchangableCharacters
Defines that characters as i|I and l|L and 0|O can be used in the password, defaults to false
Type: SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.
INPUTS
OUTPUTS
NOTES
RELATED LINKS
EDIT THIS DOC
This page was auto-generated from the powershell command comment based help. To edit the content of this page, update the script file comment based help on github Github