Disable users by default
This commit is contained in:
parent
62af6e393c
commit
c631882854
1 changed files with 1 additions and 1 deletions
|
@ -97,7 +97,7 @@ $null = New-Module {
|
||||||
$userArguments.fullName = $displayName;
|
$userArguments.fullName = $displayName;
|
||||||
}
|
}
|
||||||
|
|
||||||
New-LocalUser -NoPassword @userArguments;
|
New-LocalUser -Disabled -NoPassword @userArguments;
|
||||||
Set-LocalUser $name -PasswordNeverExpires $true;
|
Set-LocalUser $name -PasswordNeverExpires $true;
|
||||||
Set-LocalUser $name -PasswordNeverExpires $false;
|
Set-LocalUser $name -PasswordNeverExpires $false;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue