Datageddon,
Problem 1: This is a known bug in WFA3.0.X . This will be fixed in the next WFA major release. You inconvinience is regretted.
Problem 2: Your command has some problems. You need to declare a Parameter of type Password in your command code too.
[parameter(Mandatory=$false, HelpMessage="User Password")]
[Alias("Password_Password")]
[string]$Password,
Discover-Parameters will discover it of type "Password" in Parameter Definitions tab.
Now in the posh code too, you need to decrypt this password and obtain in in plaintext, before sending off into the cmdlet to Cluster for action.
if ($AuthMethod -eq 'password')
{
$SecurePassword= Get-WfaInputPassword -EncryptedPassword $Password
$textPass= ConvertFromSecureToPlain -SecurePassword $SecurePassword
$command += " -Password '$textPass'"
}
Read more about it in WFA developer's guide.
Attaching the command "Add User" code in .txt format with the fix.
sinhaa
If this post resolved your issue, help others by selecting ACCEPT AS SOLUTION or adding a KUDO.