I am trying to generate a 6 character password but I want each letter to match correct RegEx.
The RegEx being:
[a-z][A-Z][0-9][a-z][!@#$%^&*?+][A-Z]
I am currently here:
$passwd = @(1..6)
For ($i = 0; $i -lt $passwd.length; $i++){
Get-Random $passwd[$i]
}
But all this is doing is generating 6 random integers.
I want to use the Get-Random cmdlet