Last active
August 26, 2018 07:16
-
-
Save damienpontifex/2dd36c2b21fc97b358802c3a5ba15d35 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Function Get-RandomPassword | |
{ | |
Param( | |
[Int] | |
$PasswordLength = 32 | |
) | |
$allChars = [char[]](33..126) | |
$password = (Get-Random -InputObject $allChars -Count $PasswordLength) -join '' | |
return $password | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment