Created
October 3, 2017 08:26
-
-
Save gravcat/e1c0bc3ebbfc9301a48968476a58f706 to your computer and use it in GitHub Desktop.
This file contains 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 New-RandomComplexPassword ($length=12) | |
{ | |
$Assembly = Add-Type -AssemblyName System.Web | |
$password = [System.Web.Security.Membership]::GeneratePassword($length,2) | |
return $password | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment